Bug 244475
Summary: | crash at startup with new ldap sdk on 64-bit platform | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] 389 | Reporter: | Ulf Weltman <ulf.weltman> | ||||||||||
Component: | Directory Server | Assignee: | Rich Megginson <rmeggins> | ||||||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Viktor Ashirov <vashirov> | ||||||||||
Severity: | high | Docs Contact: | |||||||||||
Priority: | high | ||||||||||||
Version: | 1.1.0 | CC: | nkinder | ||||||||||
Target Milestone: | --- | ||||||||||||
Target Release: | --- | ||||||||||||
Hardware: | other | ||||||||||||
OS: | Other | ||||||||||||
Whiteboard: | |||||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
Doc Text: | Story Points: | --- | |||||||||||
Clone Of: | Environment: | ||||||||||||
Last Closed: | 2015-12-07 16:51:03 UTC | Type: | --- | ||||||||||
Regression: | --- | Mount Type: | --- | ||||||||||
Documentation: | --- | CRM: | |||||||||||
Verified Versions: | Category: | --- | |||||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
Embargoed: | |||||||||||||
Bug Depends On: | |||||||||||||
Bug Blocks: | 240316, 427409 | ||||||||||||
Attachments: |
|
Description
Ulf Weltman
2007-06-15 22:13:44 UTC
I think this issue is resolved. We've been running HP-UX 11.23 IPF (64-bit) acceptance tests for quite some time now. Ulf, can you please confirm? It doesn't look resolved, from conntable.c from the FDS tip: 65 int invalid_socket; .. 69 invalid_socket = SLAPD_INVALID_SOCKET; 70 ber_sockbuf_set_option( ct->c[i].c_sb, LBER_SOCKBUF_OPT_ DESC, &invalid_socket ); And from LDAP SDK's io.c from tip: 1078 int 1079 LDAP_CALL 1080 ber_sockbuf_set_option( Sockbuf *sb, int option, void *value ) 1081 { .. 1136 case LBER_SOCKBUF_OPT_DESC: 1137 sb->sb_sd = *((LBER_SOCKET *) value); and lber.h: 138 typedef long LBER_SOCKET; The SIGBUS "BUS_ADRALN - Invalid address alignment" wasn't happening on all our hosts, it seemed the OS or libc version affected the behavior. ulf, how can I reproduce this problem ? Simply starting up FDS would cause a crash, but I don't have the host where it was happening anymore. I had a small test case that would determine if the host would have a problem but it was lost with that host. I'll try to get it back and see if any of our hosts have the magic combination but I'm not sure how much it'll help because I don't think you want to mess with OS and libc patch levels on your QA hosts. At any rate, the code is incorrect and will cause a crash sooner or later on some 64bit platform. Created attachment 190111 [details]
diffs
Created attachment 190391 [details]
cvs commit log
Reviewed by: nkinder (Thanks!)
Files: see diff
Branch: HEAD
Fix Description: Use LBER_SOCKET as the socket type instead of int. There was
also a place in ldclt where we were doing the same thing.
Platforms tested: RHEL5 x86_64
Flag Day: no
Doc impact: no
Created attachment 221791 [details]
diffs - clean up usage of OPT_DESC
Created attachment 222111 [details] cvs commit log (Comment #11) Reviewed by: nkinder (Thanks!) Files: see diff Branch: HEAD Fix Description: I went ahead and cleaned up or removed the incorrect ber code. We do not need to use LBER_SOCKBUF_OPT_DESC or LBER_SOCKBUF_OPT_READ_FN or LBER_SOCKBUF_OPT_WRITE_FN. I removed an unnecessary malloc/free and just used the stack as we do everywhere else in the code. It looks as though the start_tls cleanup code is almost never used - the code assumes that when you do a start_tls, that stays in force throughout the lifetime of the connection. Removing this code now should insulate us from future ldap c sdk changes. Platforms tested: RHEL5 x86_64 Flag Day: no Doc impact: no |