netdata core dumps to /usr/local/etc
if netdata crashes and creates a core dump file, it creates the core files in /usr/local/etc/netdata/
On TrueNAS HA systems, /usr/local/etc/ partition is tmpfs and is only 34M in size. This cause the file system to fill up entirely, which prevents things like iscsi/afp/smb to generate a config properly because the partition is out of space.
The location in which netdata core dumps it's stack needs to be changed.
Correctly set kern.corefile
This commit fixes an issue where we could fill up /etc directory with application's core dumps. It also corrects the permissions for cores system dataset so that processes owned by user other then root can also dump their cores there.