Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
09-07-2008, 08:18 PM
|
#1
|
Member
Registered: Aug 2004
Location: Hull - England
Distribution: Ubunto and slowly switching to debian
Posts: 308
Rep:
|
ldap wont start after drive migration
hi there,
i have just migrated to a new hard drive but now my ldap servr wont start at boot up or using /etc/init.d/ldap start.
when i run /etc/init.d/ldap start it will return
Starting ldap-serverstartproc: exit status of parent of /usr/lib/openldap/slapd: 1
ldap will start if i use /usr/lib/openldap/slapd
thanks
berrance
|
|
|
09-08-2008, 05:52 AM
|
#2
|
Member
Registered: Aug 2004
Location: Hull - England
Distribution: Ubunto and slowly switching to debian
Posts: 308
Original Poster
Rep:
|
im having no look googling this problem, i just dont understand why "/usr/lib/openldap/slapd" should start ldap when "/etc/init.d/ldap start" doesnt start it.
this is a very larg problem as all user info, samba info, dns records, dhcp info, cyrus info, and sveral other bits and bobs are stored there.
berrance
|
|
|
09-08-2008, 06:35 AM
|
#3
|
LQ Guru
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,216
|
Most likely there is a pid file somewhere that make init script to fail. Check under /var/run/slapd or /var/run to see if you find it and delete it. You can also try any of the following if you cannot find the pid file
Code:
/etc/init.d/ldap stop
service ldap stop
sevice ldap status
Regards
|
|
|
09-08-2008, 06:56 AM
|
#4
|
Member
Registered: Aug 2004
Location: Hull - England
Distribution: Ubunto and slowly switching to debian
Posts: 308
Original Poster
Rep:
|
i can use "/etc/init.d/ldap stop/status" to check or stop the service its just i cannot start it this way, like the way it would start at boot up.
the pid file in /var/run is there but when i stop the service it does go like it is supposed to.
its a tricky one is this!
berrance
|
|
|
09-08-2008, 08:11 AM
|
#5
|
LQ Guru
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,216
|
You bet it's tricky. I guess there is something wrong with the suffixes or somethng.
Anyway to debug this, open /etc/init.d/ldap (make sure you keep a backup copy just in case), locate the line that starts slapd (the one that begins with /sbin/startproc -t 1 ...) and add "-d 7" among the other slapd arguments:
Code:
/sbin/startproc -t 1 -p /var/run/slapd/slapd.pid $SLAPD_BIN -d 7 -h "$SLAPD_URLS ...
Last edited by bathory; 09-08-2008 at 01:30 PM.
|
|
|
09-08-2008, 09:14 AM
|
#6
|
Member
Registered: Aug 2004
Location: Hull - England
Distribution: Ubunto and slowly switching to debian
Posts: 308
Original Poster
Rep:
|
ok that prints loads of output to much to post but this bit looks like something
ldap_create
ldap_extended_operation_s
ldap_extended_operation
ldap_send_initial_request
ldap_new_connection
ldap_int_open_connection
ldap_connect_to_host: TCP localhost:389
ldap_new_socket: 9
ldap_prepare_socket: 9
ldap_connect_to_host: Trying 127.0.0.1:389
ldap_connect_timeout: fd: 9 tm: 30 async: 0
ldap_ndelay_on: 9
ldap_is_sock_ready: 9
ldap_is_socket_ready: error on socket 9: errno: 111 (Connection refused)
and at the end of the output
TLS: could not use key file `/etc/ssl/servercerts/serverkey.pem'.
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0906D06C:PEM routines:PEM_read_bio:no start line pem_lib.c:637
TLS: error:0200100D:system library:fopen:Permission denied bss_file.c:276
TLS: error:20074002:BIO routines:FILE_CTRL:system lib bss_file.c:278
TLS: error:140B0002:SSL routines:SSL_CTX_use_PrivateKey_file:system lib ssl_rsa.c:693
main: TLS init def ctx failed: -1
slapd shutdown: freeing system resources.
slapd stopped.
connections_destroy: nothing to destroy.
if i did a strait copy from 1 disk to another why should of anything have changed?
|
|
|
09-08-2008, 10:13 AM
|
#7
|
LQ Guru
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,216
|
Quote:
TLS: could not use key file `/etc/ssl/servercerts/serverkey.pem'.
...
TLS: error:0200100D:system library:fopen:Permission denied bss_file.c:276
TLS: error:20074002:BIO routines:FILE_CTRL:system lib bss_file.c:278
TLS: error:140B0002:SSL routines:SSL_CTX_use_PrivateKey_file:system lib ssl_rsa.c:693
main: TLS init def ctx failed: -1
|
To me it looks like a permissions problem.
Quote:
if i did a strait copy from 1 disk to another why should of anything have changed?
|
You should preserve files/directories permissions. Also make sure that the user under which slapd runs can read those certificates.
|
|
|
09-08-2008, 10:29 AM
|
#8
|
Member
Registered: Aug 2004
Location: Hull - England
Distribution: Ubunto and slowly switching to debian
Posts: 308
Original Poster
Rep:
|
thank you looks like it got it,
and the way i copied the from one drive to another was by using a live cd and mounting both partitions and cp -a /hd1 /hd2 didnt us dd as i was migrating to a smaller drive. i was told after i asked severel times that cp -a would preserve permissions oh well i have got there in the end
many thanks for your help
berrance
|
|
|
09-08-2008, 10:33 AM
|
#9
|
LQ Guru
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,216
|
Glad to see you've done it.
Regards
|
|
|
All times are GMT -5. The time now is 05:39 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|