$ sysctl kern.sugid_coredump=1
kern.sugid_coredump: 0 -> 1
$ sysctl kern.corefile="/var/coredumps/%N/%P.core"
kern.corefile: /var/coredumps/%N/%P.core -> /var/coredumps/%N/%P.core
$ mkdir /var/coredumps/[process name]
$ chown [process owner] /var/coredumps/[process name]
%N = process name
%P = process id
from core