• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

Enable core file dumps when an application crashes or segmentation faults

Scheduled Pinned Locked Moved General pfSense Questions
37 Posts 2 Posters 2.4k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J
    JonathanLee @stephenw10
    last edited by Jun 12, 2024, 5:21 PM

    @stephenw10 that swap file it creates is not readable it’s compiled information also. Just a side note

    Make sure to upvote

    1 Reply Last reply Reply Quote 0
    • S
      stephenw10 Netgate Administrator
      last edited by Jun 12, 2024, 5:28 PM

      If a process aborts and creates a core file you should see something like:

      Mar 19 23:14:22 	kernel 		pid 76582 (php-fpm), jid 0, uid 0: exited on signal 11 (core dumped) 
      
      May  7 15:15:47 fw1 kernel: pid 65129 (pftop), jid 0, uid 0: exited on signal 6 (core dumped)
      
      J 1 Reply Last reply Jun 12, 2024, 5:30 PM Reply Quote 1
      • J
        JonathanLee @stephenw10
        last edited by JonathanLee Jun 12, 2024, 5:40 PM Jun 12, 2024, 5:30 PM

        @stephenw10 do you know how or what commands are used to manually trigger it for squid?

        Make sure to upvote

        1 Reply Last reply Reply Quote 0
        • S
          stephenw10 Netgate Administrator
          last edited by Jun 12, 2024, 5:49 PM

          Nope not something I've ever tried. Did you try the command they gave you?

          J 1 Reply Last reply Jun 12, 2024, 5:55 PM Reply Quote 0
          • S
            stephenw10 Netgate Administrator
            last edited by Jun 12, 2024, 5:54 PM

            @JonathanLee said in Enable core file dumps when an application crashes or segmentation faults:

            coredump_dir /root

            Where did you set that?

            J 1 Reply Last reply Jun 12, 2024, 5:55 PM Reply Quote 0
            • J
              JonathanLee @stephenw10
              last edited by JonathanLee Jun 12, 2024, 6:01 PM Jun 12, 2024, 5:55 PM

              @stephenw10 yes it showed blank from command input in GUI it killed the process but no core file it didn’t generate one when I used that command

              I am going to try this one recommend by a freeBSD forum user

              
              killall -11 squid worked for me (as root)
              
              

              Make sure to upvote

              1 Reply Last reply Reply Quote 0
              • J
                JonathanLee @stephenw10
                last edited by JonathanLee Jun 12, 2024, 5:58 PM Jun 12, 2024, 5:55 PM

                @stephenw10 advanced options on squid configure gui area, it takes when I run squid -k parse also

                Make sure to upvote

                1 Reply Last reply Reply Quote 0
                • S
                  stephenw10 Netgate Administrator
                  last edited by Jun 12, 2024, 6:14 PM

                  It tries to dump the core for both the main and child squid processes here but fails with:

                  Jun 12 19:02:08 	kernel 		pid 80887 (squid), jid 0, uid 0: exited on signal 6 (no core dump - bad address)
                  Jun 12 19:01:48 	kernel 		pid 33418 (squid), jid 0, uid 100: exited on signal 6 (no core dump - bad address) 
                  
                  J 2 Replies Last reply Jun 12, 2024, 6:16 PM Reply Quote 1
                  • J
                    JonathanLee @stephenw10
                    last edited by JonathanLee Jun 12, 2024, 6:16 PM Jun 12, 2024, 6:16 PM

                    @stephenw10 that looks like a permissions issue with Squid I wonder if we set it to squid logs location if that would work? Bad address? Does it mean path?

                    Make sure to upvote

                    1 Reply Last reply Reply Quote 0
                    • S
                      stephenw10 Netgate Administrator
                      last edited by Jun 12, 2024, 6:28 PM

                      Yes I assume it's trying to dump somewhere it can't or has nothing configured.

                      I don't expect to set that value in the Squid config. It shows the same for other processes. Seems like a FreeBSD env value missing.

                      J 2 Replies Last reply Jun 12, 2024, 6:45 PM Reply Quote 1
                      • J
                        JonathanLee @stephenw10
                        last edited by Jun 12, 2024, 6:45 PM

                        @stephenw10 I bet it is like field of dreams for code, if you code it developers will come…

                        Make sure to upvote

                        1 Reply Last reply Reply Quote 0
                        • J
                          JonathanLee @stephenw10
                          last edited by Jun 12, 2024, 7:12 PM

                          @stephenw10

                          killall -11 squid

                          mine shows no information on core anything...

                          Jun 12 12:11:40 kernel pid 84728 (squid), jid 0, uid 100: exited on signal 6
                          Jun 12 12:11:40 kernel pid 84677 (squid), jid 0, uid 0: exited on signal 11

                          Make sure to upvote

                          S 1 Reply Last reply Jun 12, 2024, 8:23 PM Reply Quote 0
                          • J
                            JonathanLee @stephenw10
                            last edited by Jun 12, 2024, 7:13 PM

                            @stephenw10 try to put it in quotes like this

                            coredump_dir "/var/squid/logs"

                            Make sure to upvote

                            1 Reply Last reply Reply Quote 0
                            • J
                              JonathanLee
                              last edited by JonathanLee Jun 12, 2024, 7:26 PM Jun 12, 2024, 7:24 PM

                              Screenshot 2024-06-12 at 12.24.15.png

                              could this be my issue with it not even trying?

                              Screenshot 2024-06-12 at 12.25.52.png

                              Make sure to upvote

                              1 Reply Last reply Reply Quote 0
                              • S
                                stephenw10 Netgate Administrator @JonathanLee
                                last edited by Jun 12, 2024, 8:23 PM

                                @JonathanLee said in Enable core file dumps when an application crashes or segmentation faults:

                                killall -11 squid

                                mine shows no information on core anything...

                                Try using kill -6 or kill -11 against the PID rather than all 'squid' processes.

                                J 1 Reply Last reply Jun 12, 2024, 8:41 PM Reply Quote 1
                                • J
                                  JonathanLee @stephenw10
                                  last edited by Jun 12, 2024, 8:41 PM

                                  @stephenw10

                                  
                                  Jun 12 13:40:58	kernel		pid 88818 (squid), jid 0, uid 100: exited on signal 6
                                  Jun 12 13:40:58	(squid-1)	88818	FATAL: Received Segment Violation...dying. listening port: 192.168.1.1:3128
                                  Jun 12 13:39:43	kernel		pid 51752 (squid), jid 0, uid 100: exited on signal 6
                                  Jun 12 13:39:43	(squid-1)	51752	FATAL: Received Segment Violation...dying.
                                  Jun 12 13:39:11	kernel		pid 17654 (squid), jid 0, uid 100: exited on signal 6
                                  Jun 12 13:38:05	check_reload_status	480	Reloading filter
                                  

                                  Make sure to upvote

                                  1 Reply Last reply Reply Quote 0
                                  • S
                                    stephenw10 Netgate Administrator
                                    last edited by Jun 12, 2024, 9:03 PM

                                    Hmm, are you testing this on your 2100? In 23.09.1?

                                    J 2 Replies Last reply Jun 12, 2024, 9:31 PM Reply Quote 0
                                    • J
                                      JonathanLee @stephenw10
                                      last edited by Jun 12, 2024, 9:31 PM

                                      @stephenw10 No that version disabled my crypt chip I am still on 23.05.01 it is the only version that works for everything I need

                                      Make sure to upvote

                                      1 Reply Last reply Reply Quote 0
                                      • J
                                        JonathanLee @stephenw10
                                        last edited by Jun 13, 2024, 1:38 AM

                                        @stephenw10 squids uid is squid and we are running commands as root does that matter?

                                        Make sure to upvote

                                        1 Reply Last reply Reply Quote 0
                                        • S
                                          stephenw10 Netgate Administrator
                                          last edited by Jun 13, 2024, 12:31 PM

                                          Nope that should be fine. This isn't a Squid specific issue, applies to any process I've tested this with. So far.

                                          1 Reply Last reply Reply Quote 0
                                          31 out of 37
                                          • First post
                                            31/37
                                            Last post
                                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                                            This community forum collects and processes your personal information.
                                            consent.not_received