Ah, so this is a pfsense machine!.. who knows how they've set it up. Sorry, pfsense is not something I know about. Covacat sounds like he knows what he's talking about 

0 18984 424 0 34 0 13444 2792 wait I - 0:00.01 /bin/sh /root/sanityOK, let's have a little sanity check.
Write this script.
$ cat try.sh
#!/bin/sh
echo "PID $$ sleeping..."
sleep 1000
Make it executable then run it.
Then "kill -11 <pid>" where <pid> is the number the script printed.
Example
$ ./try.sh
PID 148152 sleeping...
$ kill -11 148152
Segmentation fault (core dumped)
$ ls -l core*
-rw------- 1 me me 450560 Jun 12 21:50 core
Hence, check if you can get any user process to dump a core file.
If it doesn't dump core, check your ulimit -c again.
Let's prove that your system can actually write a corefile for a process that segfaults.
It should of course write the core file to the current directory.
Jun 12 14:02:20 | kernel | pid 18984 (sh), jid 0, uid 0: exited on signal 11 (core dumped) |
Shell Output - ls -l /root/sh.core
-rw------- 1 root wheel 11280384 Jun 12 14:02 /root/sh.core
I found it its where the script is located in root so sh.core reflects the sanity fileYet.. you said ulimit -a showed 'unlimited' for -c. It must be writing the core somewhere else, it's printed the message 'core dumped' so it's written it somewhere.
Did you try doing this? It sounds like they intend corefiles to be written to /var/log/squid.you don't need to create a new filesystem for dumps (if you have enough space on your root fs)
just set the dir to /var/log/squid and thats it
Ah fine, so it's just called it sh.core.I found it its where the script is located in root so sh.core reflects the sanity file
Shell Output - ls -l /root/sh.core
-rw------- 1 root wheel 11280384 Jun 12 14:02 /root/sh.core
Yeah, you're rightshould be $(basename $SHELL).core
That is done It never says (core dump) it skips that part for some weird reasonAh fine, so it's just called it sh.core.
OK, that all seems to be working fine then. Coredumps are working as expected.
Can I suggest you now try covacat's suggestion for how to configure the squid coredump_dir setting? Set it to '/var/log/squid'.
Jun 12 14:29:41 kernel pid 33305 (squid), jid 0, uid 100: exited on signal 6
Jun 12 14:29:41 kernel pid 32626 (squid), jid 0, uid 0: exited on signal 11
Jun 12 14:29:41 (squid-1) 33305 FATAL: Received Segment Violation...dying.
What does
$ ls -l /var/log/squid/*core*
say?
Shell Output - ls -l /var/log/squid/*core*
ls: /var/log/squid/*core*: No such file or directory
Let me check system is rebootingOh... what does 'df /var/log/squid' say? Is there enough space to write a core file? Is /var/log/squid mounted on a tiny partition or something? Just guessing now.
Oh... what does 'df /var/log/squid' say? Is there enough space to write a core file? Is /var/log/squid mounted on a tiny partition or something? Just guessing now.
Shell Output - df /var/log/squid
Filesystem 512-blocks Used Avail Capacity Mounted on
pfSense/var/log 172252720 30632 172222088 0% /var/log
Shell Output - ls -ld /var/log/squid
drwxr-x--- 2 squid squid 2 Jul 5 2023 /var/log/squid
yes the uid is squid not root others think that is the issue on squid email systemPermissions look ok then.. assuming it's uid 'squid' that runs squid.
What userid did you try to run the script as, and why is it's owner root?Code:Shell Output - ls -l /var/log/squid/try.sh -rwxrwxrwx 1 root squid 46 Jun 12 17:55 /var/log/squid/try.sh Shell Output - /var/log/squid/try.sh sh: /var/log/squid/try.sh: Permission denied