LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Slackware64 saslauthd segfault (https://www.linuxquestions.org/questions/slackware-14/slackware64-saslauthd-segfault-900010/)

rpedrica 08-29-2011 03:43 AM

Slackware64 saslauthd segfault
 
From time to time I have 2 machines that have a segfault in the saslauthd process and of course no further email can be sent.

Running

/etc/rc.d/rcsaslauthd stop
/etc/rc.d/rcsaslauthd start

solves the issue for the next few days or weeks. One machine is 13.1 and the other is 13.0.

Here is an example of the issue:

Aug 27 20:30:56 mail kernel: saslauthd[3248]: segfault at ffffffffe7aee1a0 ip 00007fade73af790 sp 00007ffffcf8def8 error 4 in libc-2.9.so[7fade732f000+167000]
Aug 27 20:31:03 mail kernel: saslauthd[3249]: segfault at ffffffffe7aee1a0 ip 00007fade73af790 sp 00007ffffcf8def8 error 4 in libc-2.9.so[7fade732f000+167000]
Aug 27 20:31:11 mail kernel: saslauthd[3250]: segfault at ffffffffe7aee1a0 ip 00007fade73af790 sp 00007ffffcf8def8 error 4 in libc-2.9.so[7fade732f000+167000]
Aug 27 20:31:19 mail kernel: saslauthd[3247]: segfault at ffffffffe7aee1a0 ip 00007fade73af790 sp 00007ffffcf8def8 error 4 in libc-2.9.so[7fade732f000+167000]
Aug 27 20:31:26 mail kernel: saslauthd[3251]: segfault at ffffffffe7aee1a0 ip 00007fade73af790 sp 00007ffffcf8def8 error 4 in libc-2.9.so[7fade732f000+167000]

One machine has all patches applied while the other does not have the latest kernel update.

Any ideas welcome.

rpedrica 01-03-2012 09:08 AM

The problem appears to be quite regular now - I have 2 x 13.37 machines doing the same thing. While I can use monit to monitor and restart, I'd like to find the underlying cause. Any help appreciated.

robel 10-26-2012 02:51 AM

saslauthd 2.1.25 works!
 
I had the same problem in Slackware64 14.0.

saslauthd[6689]: segfault at ffffffffbee8d1e0 ip 00007f4dbe7042e1 sp 00007fff56639de8 error 4 in libc-2.15.so[7f4dbe67c000+1b5000]

This is saslauthd 2.1.23 which comes with Slackware64 14.1

After downloading and compiling saslauthd 2.1.25 the problem was solved.

rpedrica 10-26-2012 08:59 AM

Yes I have the issue across all versions from 12.0 to 13.37 - I've resorted to using monit to auto-restart the service.

robel 10-26-2012 11:33 AM

Quote:

Originally Posted by rpedrica (Post 4815476)
Yes I have the issue across all versions from 12.0 to 13.37 - I've resorted to using monit to auto-restart the service.

saslauthd 2.1.25 has worked for several days on my server. I downloaded cyrus-sasl-2.1.25.tar.gz and compiled it (configure and make). Then I just replaced the binary file saslauthd (located in the saslauthd directory).

Oh, it's probably not the way to do it... The ideal solution would be the Slackware team upgraded saslauthd.

Anyway... You could download the cyrus-sasl-2.1.23-x86_64-4 (in case you're running Slackware64 14.0) source code from slackware.com and check the build script. It's pretty easy to understand. Then build cyrus-sasl-2.1.25 the same way.

vorel 02-19-2014 02:19 AM

Hi, I have the same problem. I'm runing Slackware64 14.1, cyrus-sasl-2.1.26 (compiled from source) and glibc 2.17. I have the same issue runing cyrus-sasl-2.1.24 (from Slackware current repositories) so I rebuild to the new version, bud the problem still remains:

saslauthd[27046]: segfault at 0 ip 00007fc6eea3c341 sp 00007fff19491ee8 error 4 in libc-2.17.so[7fc6ee9b3000+1bf000]

After few segfaults saslauth crashes (but /var/state/saslauthd/saslauthd.pid still remains.

Does anyone please solved this issue? Thank you for any suggestions.

Alien Bob 02-19-2014 05:21 AM

Quote:

Originally Posted by vorel (Post 5120661)
Hi, I have the same problem. I'm runing Slackware64 14.1, cyrus-sasl-2.1.26 (compiled from source) and glibc 2.17. I have the same issue runing cyrus-sasl-2.1.24 (from Slackware current repositories) so I rebuild to the new version, bud the problem still remains:

saslauthd[27046]: segfault at 0 ip 00007fc6eea3c341 sp 00007fff19491ee8 error 4 in libc-2.17.so[7fc6ee9b3000+1bf000]

After few segfaults saslauth crashes (but /var/state/saslauthd/saslauthd.pid still remains.

Does anyone please solved this issue? Thank you for any suggestions.

Vorel, Slackware 14.1 and -current apply a patch to cyrus-sasl to fix these segfaults. Did you apply cyrus-sasl-2.1.23-glibc217-crypt.diff.gz when you built your package? It is the same patch which is used in Ubuntu, the patch was written by our forum member mancha: http://bazaar.launchpad.net/~ubuntu-...013-4122.patch

Eric

vorel 02-20-2014 11:09 AM

Hi Eric, thank you very much for your help. Of course I didn't! I recompiled the cyrus-sasl with patch, everything went ok, I installed package and saslauthd is running fine:
testsaslauthd -u ... -p ...
0: OK "Success."

But from installing patched cyrius-sasl.2.1.25 I cannot STARTSSL verification, my maillog says:

"did not issue MAIL/EXPN/VRFY/ETRN during connection to MSA"

I recompiled sendmail:

Compiled with: DNSMAP LOG MAP_REGEX MATCHGECOS MILTER MIME7TO8 MIME8TO7
NAMED_BIND NETINET NETUNIX NEWDB NIS PIPELINING SASLv2 SCANF
STARTTLS TCPWRAPPERS USERDB XDEBUG

I have /etc/sasl2/Sendmail.conf, and smtp connection without SSL is working fine, but I want only checked users to send emails :-( Is there something else I forgot? Previously it worked fine with cyrus-sasl 2.1.23 and 2.1.26 (instead of these segfaults).

vorel 02-21-2014 03:04 AM

Recompiled cyrius-sasl2.1.23 with your patch with Slackbuild and I can send emails via SSL, but in some cases I got these:

saslauthd[7057]: segfault at ffffffffb9df6220 ip 00007f27b9711057 sp 00007fff14f65f18 error 5 in libc-2.17.so[7f27b95db000+1bf000]

I would try more, but it would be great if someone advice me for having funcional saslauth with sendmail. Maybe I'm compiling sendmail with bad options (in ../devtools/Site) which is ok fo 2.1.23 but not for 2.1.25 or Sendmail.conf should be located somewhere else for 2.1.25. Thank to everyone for any hint ;-)

kenw232 02-24-2014 01:02 AM

Try running saslauthd with -n 0 I think it is. If its the same problem I had it should stop running in prefork mode and stop crashing. I forget what I did to fix the underlying problem though.

Maybe its because hack attempts are trying to login with users that don't have real passwords defined. It might be crashing on user logins with a password of something like * or x in the shadow file. Its a bug. I might be off base though, I just had a problem with salsauthd too and this is what it was.

rpedrica 02-24-2014 01:06 AM

I found the issue disappears when using 2.1.25 on all the boxes I've used so far - mostly sw 12.0 - 13.37

vorel 02-25-2014 06:36 AM

Thanks kenw232 and rpedrica for your answers.

I tried saslauthd with -n 0, but this doesn't help, and I run out of saslatuhd forks very early.

I recompiled cyrus-sasl 2.1.25 with path from Alien Bob, I recompiled Sendmail but wiht same config options SSL authentification does not work (localy yes, but not for connected users). My devtools/Site/site.config.m4 looks like:

APPENDDEF(`confENVDEF', `-DBROKEN_PTHREAD_SLEEP -DSASL=2')
APPENDDEF(`confENVDEF', `-DNEWDB')
APPENDDEF(`confLIBS', `-ldb')
APPENDDEF(`confLIBS', `-lsasl2')
APPENDDEF(`confLIBS', `-lresolv')
APPENDDEF(`conf_sendmail_ENVDEF', `-DMILTER -DSASL=2')
APPENDDEF(`conf_sendmail_LIBS', `-lsasl2')
APPENDDEF(`conf_sendmail_ENVDEF', `-DSTARTTLS')
APPENDDEF(`conf_sendmail_ENVDEF', `-D_FFR_SMTP_SSL')
APPENDDEF(`conf_sendmail_LIBS', `-lssl -lcrypto')

Did I forget something?

And I builded cyrus-sasl the same way as 2.1.23 (with Slackbuild and with patch), and have Sendmail.conf in /etc/, I tried to have it in other directories (/etc/mail, /usr/lib, /lib64, but nothing helps. Are there some changes with version 2.1.25 that I forgot about?

vorel 08-15-2014 04:57 AM

Hi to everyone. I would like to say thank to every of you who, who contributed to this topic. I finaly solved it. So, to everyone who is facing the same issue. I finaly rebuilded cyrus-sasl 2.1.26 with changes for Slackware. Then I have to create directory /etc/sasl2/ where I have to put configuration file Sendmail.conf (without it sendamil does not operate with SALS). And it works like a charm! And without segfaults. I tested it a lot and no segfault came on again. Now I'm using it quite a while in production now, without problems. I don't know why, but with everything the same, cyrus-sasl 2.1.25 wont work for me.

So, many thanks to all of you. If is someone interested in more informations, or want installation pack, please let me know, I would gladly to redistribute it.

dgrames 05-19-2015 09:00 PM

how can I get a copy of this version of saslauthd

This is the same issue, and I cannot get a good recompile of it.

Don

rpedrica 05-20-2015 03:16 AM

@dgrames, you should be good to compile on a std slackware installation. What ver of Slackware are you using?


All times are GMT -5. The time now is 05:17 AM.