strange crash with freeradius 1.1.2 on startup
Hello. I'm a mandriva package maintainer, and I'm trying to solve a strange issue with our freeradius package. On mandriva 2007.1, the server crashes immediatly after forking (SIGPIPE error), whereas it works OK with -x debug flag. The same package, built on mandriva 2007.0, works OK also. You have a bug report available at http://qa.mandriva.com/show_bug.cgi?id=32597, with traces of both cases. I initially thought of some kind of bogus autoconf detection of build environment, due to the lack of commands such as setsid in wrong trace, and tghe use of conditional builds directives in the code. However, comparating autoconf.h in both build tree doesn't show any sensible hint (in particular, HAVE_SETSID is set even for the non-working case, whereas it doesn't appear in the trace). Comparing build commandes neither (only difference being -mpentiumpro versus -mgeneric gcc flag). Using ldd on radiusd binary doesn't show any sensible difference neither. Freeradius 1.1.6 and 1.1.7 work perfectly on current mandriva development version, however, I'd prefer to fix the issue on stable release without changing version if possible. Any hint welcome. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
A.L.M.Buxey@lboro.ac.uk a écrit :
Hi,
Hello.
I'm a mandriva package maintainer, and I'm trying to solve a strange
1.1.7 As stated in my initial message, I have to fix the issue without changing version (standard distribution bugfix policy). Meaning backporting fix eventually. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
Guillaume Rousse wrote:
1.1.7 As stated in my initial message, I have to fix the issue without changing version (standard distribution bugfix policy). Meaning backporting fix eventually.
If you stick with 1.1.2, there's a whack of other fixes you MUST back-port: http://freeradius.org/security.html It's likely easier to upgrade. Alan DeKok.
Guillaume Rousse wrote:
1.1.7 As stated in my initial message, I have to fix the issue without changing version (standard distribution bugfix policy). Meaning backporting fix eventually.
If you stick with 1.1.2, there's a whack of other fixes you MUST back-port:
http://freeradius.org/security.html
It's likely easier to upgrade. OK, I tried freeradius 1.1.7 on 2007.1 with exactly same result: clone(Process 11236 attached child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xb7be2708) = 11236 [pid 11235] exit_group(0) = ? [pid 11236] getsockname(3, Process 11235 detached {sa_family=AF_INET, sin_port=htons(45941), sin_addr=inet_addr("193.55.250.81")}, [16]) = 0 getpeername(3, {sa_family=AF_INET, sin_port=htons(389), sin_addr=inet_addr("193.55.250.2")}, [16]) = 0 fcntl64(3, F_GETFD) = 0x1 (flags FD_CLOEXEC) dup(3) = 6 fcntl64(6, F_SETFD, FD_CLOEXEC) = 0 socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 7 close(3) = 0 fcntl64(7, F_GETFD) = 0 dup2(7, 3) = 3 fcntl64(3, F_SETFD, 0) = 0 close(7) = 0 write(3, "\25\3\1\0 SA\367\245\363$ \335\277\247\337|\330\263h\360"...,
Alan DeKok a écrit : 37) = -1 EPIPE (Broken pipe) --- SIGPIPE (Broken pipe) @ 0 (0) --- Process 11236 detached Whereas it works perfectly OK on cooker :/ There is definitevely something wrong in 2007.1 build or running environment I can't identify. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
Guillaume Rousse wrote:
OK, I tried freeradius 1.1.7 on 2007.1 with exactly same result:
2007.1? What's that? And if you have the same result, it's likely because there's a library from 1.1.2 that's left over, and is being used by 1.1.7. Make sure that 1.1.7 uses the libraries from 1.1.7. Alan DeKok.
Alan DeKok a écrit :
Guillaume Rousse wrote:
OK, I tried freeradius 1.1.7 on 2007.1 with exactly same result:
2007.1? What's that? mandriva 2007.1, the only version where the problem occurs. Both mandriva 2007.0 (previous mandriva version) and cooker (development version) are OK.
And if you have the same result, it's likely because there's a library from 1.1.2 that's left over, and is being used by 1.1.7. Make sure that 1.1.7 uses the libraries from 1.1.7. I'm sure, upgrading package remove all files from previous versions.
I also attempted to use gdb with follow-fork-mode set to child, it prevent the SIGPIPE to happens. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
Guillaume Rousse wrote:
2007.1? What's that? mandriva 2007.1, the only version where the problem occurs. Both mandriva 2007.0 (previous mandriva version) and cooker (development version) are OK.
Then file a bug with Mandriva. Their package is broken. When anyone else uses 1.1.7 on any other platform, it works. Alan DeKok.
Alan DeKok a écrit :
Guillaume Rousse wrote:
2007.1? What's that? mandriva 2007.1, the only version where the problem occurs. Both mandriva 2007.0 (previous mandriva version) and cooker (development version) are OK.
Then file a bug with Mandriva. Their package is broken. Maybe you should read my original message again: the bug report is already open, and I'm the guy trying to fix it... -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
Guillaume Rousse wrote:
Then file a bug with Mandriva. Their package is broken. Maybe you should read my original message again: the bug report is already open, and I'm the guy trying to fix it...
Forgive me for getting large volumes of mail, and not remembering all of the details of each and every one. In this case, try an install of 1.1.7 on a fresh machine. It works for every other distribution. Failing that, because 1.1.7 works on every other system, I have little additional advice to offer. Alan DeKok.
Alan DeKok a écrit :
Guillaume Rousse wrote:
Then file a bug with Mandriva. Their package is broken. Maybe you should read my original message again: the bug report is already open, and I'm the guy trying to fix it...
Forgive me for getting large volumes of mail, and not remembering all of the details of each and every one.
In this case, try an install of 1.1.7 on a fresh machine. It works for every other distribution. A manual install works OK, I already know. This is likely to be a build issue in the official package.
If that matters, the whole package, including patches and spec file, are available from the: http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/freeradius/curren...
Failing that, because 1.1.7 works on every other system, I have little additional advice to offer. Can you have a look at the traces I posted at http://qa.mandriva.com/show_bug.cgi?id=32597, and try to guess why the wrong build tries to open a socket immediatly after forking, whereas the correct build does setsid first, then opens its pid file ?
Despite my initial guess, HAVE_SETSID is defined in both cases. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
Guillaume Rousse wrote:
If that matters, the whole package, including patches and spec file, are available from the: http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/freeradius/curren...
Some of your site-specific patches are problematic. The patch to un-comment "/etc/shadow" isn't necessary. I suggest trying the build with the patches installed one by one. It's highly likely that of the patches is breaking the server. Alan DeKok.
Alan DeKok a écrit :
Guillaume Rousse wrote:
If that matters, the whole package, including patches and spec file, are available from the: http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/freeradius/curren...
Some of your site-specific patches are problematic. The patch to un-comment "/etc/shadow" isn't necessary.
I suggest trying the build with the patches installed one by one. It's highly likely that of the patches is breaking the server. Actually, the problem was absolutly not related to freeradius, nor to applied patches, but to nss_ldap version shipped in 2007.1, as the server was trying to resolve 'radius' user id and gid: http://bugzilla.padl.com/show_bug.cgi?id=273
I'm interested to your opinion about applied patches however, i may discuss them with the package maintainer. And we would be interested in having everything related to biarch handling (freeradius-1.1.2-libdir.diff) merged, if possible. -- Guillaume Rousse Moyens Informatiques - INRIA Futurs Tel: 01 69 35 69 62
participants (3)
-
A.L.M.Buxey@lboro.ac.uk -
Alan DeKok -
Guillaume Rousse