sendmail Segmentation fault after upgrade from 12.3 to 13.1

Code:
Starting sendmail_submit.
pid 1542 (sendmail), jid 0, uid 0: exited on signal 11
Segmentation fault
/etc/rc: WARNING: failed to start sendmail_submit
Starting sendmail_msp_queue.
pid 1547 (sendmail), jid 0, uid 0: exited on signal 11
Segmentation fault
/etc/rc: WARNING: failed to start sendmail_msp_queue

The error message is displayed after I upgrade my server from 12.3 to 13.1, I don't know how to fix it.
 
sha256 /usr/libexec/sendmail/sendmail
should be
37bdf7b8e208bc9e047e1fdad89f8701a9291558def3ea22ed319af5df0b4026 (on amd64)
 
SHA256 (/usr/libexec/sendmail/sendmail) = 37bdf7b8e208bc9e047e1fdad89f8701a9291558def3ea22ed319af5df0b4026
The hash of the file is same with file's on another 13.1 system.

I has no idea how to deal with this problem.😞😞
 
I think sendmail is in base userland so that would be upgraded by the second freebsd-update.

Could try freebsd-update steps again? But without the version upgrade part - just freebsd-update fetch and then freebsd-update install.

And have you rebooted, just to see if that makes any difference?

Check the logs e.g. /var/logs/messages.
 
Code:
~$ldd /usr/libexec/sendmail/sendmail |cut -w -f 4|tr -d :|xargs sha256
SHA256 (/usr/libexec/sendmail/sendmail) = 37bdf7b8e208bc9e047e1fdad89f8701a9291558def3ea22ed319af5df0b4026
SHA256 (/lib/libutil.so.9) = fa054b1e5c5b0560ed8d15315cc1b4a5d3ba81ead40371a6c1b4e071956eebc9
SHA256 (/usr/lib/libssl.so.111) = 5a8ab33bd511ecc42bfa1db1d058e6114554a908f0dcb14811c5d3c9191f1995
SHA256 (/lib/libcrypto.so.111) = b7d0247e1e1828adc3cb549f2ad337cf28de59e62c3ccea238d28d444e313095
SHA256 (/usr/lib/libwrap.so.6) = 7388bf65ba41684439c3a832b17da8210d6c2f5c77e7696705445f8dfc74fa12
SHA256 (/lib/libc.so.7) = 2f5fc6891e50a3715c9562f9732b8bba53deab5a0b366bb78084413cfcbddd5b
SHA256 (/lib/libthr.so.3) = 21ef5ada62ccd287aa74ac9d3e73d4a8b64a0a351093a8a4cba3d8d4ca1fb0d8
 
frank@SR510:~ % ldd /usr/libexec/sendmail/sendmail |cut -w -f 4|tr -d :|xargs sha256
SHA256 (/usr/libexec/sendmail/sendmail) = 37bdf7b8e208bc9e047e1fdad89f8701a9291558def3ea22ed319af5df0b4026
SHA256 (/lib/libutil.so.9) = fa054b1e5c5b0560ed8d15315cc1b4a5d3ba81ead40371a6c1b4e071956eebc9
SHA256 (/usr/lib/libssl.so.111) = 5a8ab33bd511ecc42bfa1db1d058e6114554a908f0dcb14811c5d3c9191f1995
SHA256 (/lib/libcrypto.so.111) = b7d0247e1e1828adc3cb549f2ad337cf28de59e62c3ccea238d28d444e313095
SHA256 (/usr/lib/libwrap.so.6) = 7388bf65ba41684439c3a832b17da8210d6c2f5c77e7696705445f8dfc74fa12
SHA256 (/lib/libc.so.7) = 2f5fc6891e50a3715c9562f9732b8bba53deab5a0b366bb78084413cfcbddd5b
SHA256 (/lib/libthr.so.3) = 21ef5ada62ccd287aa74ac9d3e73d4a8b64a0a351093a8a4cba3d8d4ca1fb0d8

I used gdb to debug sendmail, the output is following

frank@SR510:~ % gdb sendmail
GNU gdb (GDB) 12.1 [GDB v12.1 for FreeBSD]
Copyright (C) 2022 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-portbld-freebsd13.1".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from sendmail...
(No debugging symbols found in sendmail)
(gdb) run
Starting program: /usr/sbin/sendmail
process 62892 is executing new program: /usr/libexec/sendmail/sendmail

Program received signal SIGSEGV, Segmentation fault.
Invalid permissions for mapped object.
0x0000000801952a49 in ?? () from /usr/local/lib/nss_wins.so.1
(gdb) backtrace
#0 0x0000000801952a49 in ?? () from /usr/local/lib/nss_wins.so.1
#1 0x0000000801952b6a in ?? () from /usr/local/lib/nss_wins.so.1
#2 0x00000008015bee8d in nsdispatch () from /lib/libc.so.7
#3 0x00000008015b30ad in ?? () from /lib/libc.so.7
#4 0x00000008015b3b74 in gethostbyname2 () from /lib/libc.so.7
#5 0x00000008015bca67 in getipnodebyname () from /lib/libc.so.7
#6 0x0000000001057b3e in ?? ()
#7 0x000000000105e87e in ?? ()
#8 0x000000000107752e in ?? ()
#9 0x00000000010502dd in ?? ()
#10 0x0000000000000000 in ?? ()
(gdb)
 
looks like a problem with samba / wins
did you rebuild / reinstall samba (or whichever package is the provider of nss_wins.so) ?
 
I just upgrade samba413 to samba416, and the error is same. The nss_wins.so is provided by samba416.
 
Do you have samba from ports or did you use pkg?
In that gdb session, can you do:
Code:
f 0
disass $pc-0x30, $pc+0x30
i r
If the samba416 is from pkg can you share cksum /usr/local/lib/nss_wins.so.1 ?
 
Good day.
A similar error occurred after the update from 12.2 to 13.3.
Performed similar actions:

service sendmail start

Starting sendmail.
Segmentation fault

/etc/rc.d/sendmail: WARNING: failed to start sendmail
Starting sendmail_msp_queue.
Segmentation fault
/etc/rc.d/sendmail: WARNING: failed to start sendmail_msp_queue


# gdb sendmail
GNU gdb (GDB) 14.1 [GDB v14.1 for FreeBSD]
Copyright (C) 2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-portbld-freebsd13.2".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".

Type "apropos word" to search for commands related to "word"...
Reading symbols from sendmail...
(No debugging symbols found in sendmail)

(gdb) run

Starting program: /usr/sbin/sendmail
warning: Could not load shared library symbols for [vdso].
Do you need "set solib-search-path" or "set sysroot"?
process 13956 is executing new program: /usr/libexec/sendmail/sendmail
warning: Could not load shared library symbols for [vdso].
Do you need "set solib-search-path" or "set sysroot"?

Program received signal SIGSEGV, Segmentation fault.

Address not mapped to object.

0x00000008016b7570 in strcasecmp_l () from /lib/libc.so.7

(gdb)
backtrace

#0 0x00000008016b7570 in strcasecmp_l () from /lib/libc.so.7
#1 0x00000008015df288 in ?? () from /lib/libc.so.7
#2 0x00000008015def1d in nsdispatch () from /lib/libc.so.7
#3 0x00000008015d32c0 in ?? () from /lib/libc.so.7
#4 0x00000008015d3da2 in gethostbyname2 () from /lib/libc.so.7
#5 0x00000008015dcbfb in getipnodebyname () from /lib/libc.so.7
#6 0x0000000001059f80 in sm_gethostbyname (name=name@entry=0x7fffffffdf80 "myserver.com", family=family@entry=2) at /usr/src/contrib/sendmail/src/conf.c:4424
#7 0x0000000001060c78 in myhostname (hostbuf=hostbuf@entry=0x7fffffffdf80 "myserver.com", size=size@entry=256) at /usr/src/contrib/sendmail/src/daemon.c:3449
#8 0x000000000107a2df in main (argc=1, argv=0x7fffffffea00, envp=<optimized out>) at /usr/src/contrib/sendmail/src/main.c:745


In the previous discussion the solution was somehow not indicated.
 
Back
Top