squid v5 crashes with SIGABRT when ipv6 is disabled at kernel level but it is asked to connect to an ipv6 address by a client

Solution Verified - Updated -

Issue

  • Disabling IPV6 causes squid to crash dump and restart

    1. Disable ipv6 using sysctl
     # vi /etc/sysctl.d/disable_v6.conf
         net.ipv6.conf.all.disable_ipv6=1
         net.ipv6.conf.default.disable_ipv6=1
    
    2. Restart server with squid enabled
    3. Wait for an IPV6 resource request

  • In /var/log/messages log

    $ cat messages | grep systemd-coredump | sed s'/#012/\n/g'
    systemd-coredump[XXXXX]: Process XXXXX (squid) of user 23 dumped core.
    Stack trace of thread 238044:
    #0 0x00007f28d68a154c __pthread_kill_implementation (libc.so.6 + 0xa154c)
    #1 0x00007f28d6854d06 raise (libc.so.6 + 0x54d06)
    #2 0x00007f28d68287f3 abort (libc.so.6 + 0x287f3)
    #3 0x00007f28d682871b __assert_fail_base.cold (libc.so.6 + 0x2871b)
    #4 0x00007f28d684dca6 __assert_fail (libc.so.6 + 0x4dca6)
    #5 0x0000558ab96650b9 _ZNK2Ip7Address11getAddrInfoERP8addrinfoi (squid + 0x3cf0b9)
    #6 0x0000558ab966225a _ZL11comm_openexiiRN2Ip7AddressEiPKc.lto_priv.0 (squid + 0x3cc25a)
    #7 0x0000558ab96ae9a1 _ZN4Comm10ConnOpener8createFdEv (squid + 0x4189a1)
    #8 0x0000558ab96afed8 _ZN4Comm10ConnOpener5startEv (squid + 0x419ed8)
    #9 0x0000558ab9655eae _ZN9JobDialerI8AsyncJobE4dialER9AsyncCall (squid + 0x3bfeae)
    #10 0x0000558ab96545db _ZN14AsyncCallQueue8fireNextEv (squid + 0x3be5db)
    #11 0x0000558ab965496a _ZN14AsyncCallQueue4fireEv (squid + 0x3be96a)
    #12 0x0000558ab943b961 _ZN9EventLoop7runOnceEv (squid + 0x1a5961)
    #13 0x0000558ab953da08 _Z9SquidMainiPPc (squid + 0x2a7a08)
    #14 0x0000558ab93e0656 main (squid + 0x14a656)
    #15 0x00007f28d683feb0 __libc_start_call_main (libc.so.6 + 0x3feb0)
    #16 0x00007f28d683ff60 __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x3ff60)
    #17 0x0000558ab93ead05 _start (squid + 0x154d05)
    ELF object binary architecture: AMD x86-64
    

Environment

  • Red Hat Enterprise Linux 9
  • squid

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content