LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
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


Reply
  Search this Thread
Old 03-02-2008, 12:35 PM   #1
toynbee
Member
 
Registered: Jan 2007
Location: Maryland
Distribution: Arch and Red Hat
Posts: 34

Rep: Reputation: 17
OpenLDAP in Debian 4.1


Hi guys,

I'm trying to install OpenLDAP on DEbian 4.1 Etch, as the title suggests. I have found several howtos, but they always fail on the first step (apt-get install slapd or some package that installs slapd as a dependency). I get a whole heap of output as a result, but I think the main part is this:

Setting up slapd (2.3.30-5) ...
Creating initial slapd configuration... done.
Creating initial LDAP directory... slapadd: bad configuration file!
Failed to slapadd this data:

This has happened consistently through several attempts and despite several minimal attempts to troubleshoot (minimal only because I only know enough to break it further). It seems a simple matter of recovering a valid configuration file, as the service is installed and can even be started/stopped in /etc/init.d/; however, I'm not sure what file that is and exhaustive googling of everything I can think of has turned up 0 results (other than one guy who apparently had the same error I did and got no help on it, some other forum). Any advice would be appreciated.
 
Old 03-02-2008, 10:20 PM   #2
drokmed
Member
 
Registered: Dec 2005
Location: St Petersburg, FL, USA
Posts: 220

Rep: Reputation: 31
Installing openldap on Etch is incredibly easy. The Debian maintainers did a great job at automating the installation for you. It sounds like your openldap install has been corrupted some how.

Normally, you would just do:

# apt-get install slapd

Debian would fetch the files it needs, examine your system to determine your server and domain name, ask you what 'admin' password you want, then automatically create the /etc/ldap/slapd.conf file for you, install the /etc/init.d/slapd start-up file, create a default DIT, add the admin user, and bring up the server! Debian is great... other distro's don't do any of these things. They just install the program files, then leave you to figure out everything by yourself.

Since it sounds like your openldap is messed up somehow, I'd say do a reconfigure on it first.

# dpkg-reconfigure slapd

This will reforce it to ask you configuration questions, then regenerate everything for you, like in the original install.

If you are new to openldap, I should warn you it can be very hard to learn. Depending on what you want to use openldap for, it can be quite challenging.

As for how-to's, most are written for Sarge. I haven't seen any good ones written for Etch. Here's a good one I've used, it was written for sarge (3.1), but works for etch (mostly), and covers openldap and samba integration pretty nicely:

http://nomis52.net/?section=docs&page=samldap

If the above dpkg-reconfigure didn't help, then I'd suggest totally uninstalling the slapd package:

# dpkg --purge slapd

Normally, when you uninstall a package in Debian, it removes everything EXCEPT the config files. The --purge will tell it to remove everything. That way, when you re-install, it should be from scratch.

If you still get errors after reconfiguring and uninstall/reinstalling slapd, I'd suggest if that's a new install, format that hard disk, and start over. I get the feeling you might have tried installing from source... on Debian, it is always best to install from packages when they are available.

Hope this helps
 
Old 03-02-2008, 11:19 PM   #3
toynbee
Member
 
Registered: Jan 2007
Location: Maryland
Distribution: Arch and Red Hat
Posts: 34

Original Poster
Rep: Reputation: 17
Hi drokmed, thanks for your advice. dpkg --purge was actually one of the first things I tried, thinking the package may have become corrupted as sometimes happens. However, that didn't resolve it. I may compile from source, but I'd prefer to avoid that avenue if possible.

I've been contemplating reformatting, but this server has remained stable for nigh a year (pretty much since I moved), so I would prefer to avoid that as well. However, I am not totally adverse to it as a last resort.
 
Old 03-05-2008, 08:16 AM   #4
toynbee
Member
 
Registered: Jan 2007
Location: Maryland
Distribution: Arch and Red Hat
Posts: 34

Original Poster
Rep: Reputation: 17
Quote:
Originally Posted by toynbee View Post
I've been contemplating reformatting, but this server has remained stable for nigh a year (pretty much since I moved), so I would prefer to avoid that as well. However, I am not totally adverse to it as a last resort.
Hi guys.

I gave in and reformatted -- there were other problems with my server from when I had tried, unsuccessfully, to setup Xen. After reformatting, apt-get install slapd returned no errors whatsoever. Just figured you would want to know. Thanks for your help in the meantime!
 
Old 03-06-2008, 11:23 AM   #5
drokmed
Member
 
Registered: Dec 2005
Location: St Petersburg, FL, USA
Posts: 220

Rep: Reputation: 31
Glad to hear that, I was wondering if you were able to get it working.
 
  


Reply

Tags
debian, etch, ldap, openldap



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenLDAP velu.net Linux - Software 1 11-16-2006 08:34 PM
LXer: LDAP Series Part IV - Installing OpenLDAP on Debian Plus Some LDAP Commentary LXer Syndicated Linux News 0 10-31-2006 06:54 PM
OpenLDAP in Ubuntu/Debian depam Linux - Software 3 08-28-2006 12:45 PM
openldap.so.2 mrlucio79 Fedora 2 08-24-2006 02:28 PM
openldap quarry_06 Linux - Networking 7 11-21-2004 01:11 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration