un lien sur openldap
http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-ldap-pam.html
certains elements ont du evoluer avec l integration de openldap sur FC5
To integrate Samba and LDAP you need to install a few tools:
Go to
http://dag.wieers.com/packages/perl-Crypt-SmbHash/ and download the fc3 noarch.rpm file. Once downloaded copy it to the root share accessed earlier.
Go to
http://www.idealx.org/prj/samba/dist/ and click on the latest version .noarch.rpm file to download it. Once downloaded copy it to the root share accessed earlier.
Back in putty issue the following commands:
rpm ?i perl-Crypt-SmbHash-0.02-1.1.fc3.rf.noarch.rpm
rpm ?i smbldap-tools-0.9.1-1.noarch.rpm
(changing file versions where necessary)
Next we must copy the samba scema for the LDAP server:
cp /usr/share/doc/samba-3.0.14a/LDAP/samba.schema /etc/openldap/schema/
To configure the LDAP server for our samba configuration you must edit the conf file:
vi /etc/openldap/slapd.conf
Add the following line under the ?include section? so it looks like this:
include /etc/openldap/schema/core.schema
include /etc/openldap/schema/cosine.schema
include /etc/openldap/schema/inetorgperson.schema
include /etc/openldap/schema/nis.schema
include /etc/openldap/schema/samba.schema
Under the ?database? section, alter it so it looks like this, (altering DOMAIN to the name you want your domain to be):
database bdb
directory /var/lib/ldap
suffix "dc=DOMAIN,dc=COM"
rootdn "cn=Manager,dc=DOMAIN,dc=COM"
rootpw mysecretpwd
Change the rootpw to whatever you want ? I just left it as is.
Next we need to edit some more conf files:
vi /etc/openldap/ldap.conf
Edit so it looks like this: (replacing DOMAIN of course)
HOST 127.0.0.1
BASE dc=DOMAIN,dc=COM
Next we need to configure the LDAP client:
vi /etc/ldap.conf
Find the section that looks like this:
# Your LDAP server. Must be resolvable without using LDAP.
And add below it:
host 127.0.0.1
Find the section that looks like this:
# The distinguished name of the search base.
Add/Change Below It:
base dc=DOMAIN,dc=COM
Replacing DOMAIN where necessary.
Find the section that looks like this:
# The distinguished name to bind to the server with if the effective user ID
# is root. Password must be stored in /etc/ldap.secret (mode 600)
Add/Change Below It:
rootbinddn cn=nssldap,ou=DSA,dc=DOMAIN,dc=COM
Replacing DOMAIN where necessary.
Find the section that looks like this:
# RFC2307bis naming contexts
# we use ?sub (and not the default ?one) because we
# separated sambaAccounts on ou=Computer,dc=DOMAIN,dc=COM
# and ou=Users,dc=DOMAIN,dc=COM
Add/Change Below It:
nss_base_passwd ou=Users,dc=DOMAIN,dc=COM?one
nss_base_passwd ou=Computers,dc=DOMAIN,dc=COM?one
nss_base_shadow ou=Users,dc=DOMAIN,dc=COM?one
nss_base_group ou=Groups,dc=DOMAIN,dc=COM?one
Replacing DOMAIN where necessary.
One last conf file:
vi /etc/nsswitch.conf
Find the section that looks like this:
# significative entries for /etc/nsswitch.conf using
# Samba and OpenLDAP
Add/Change below it:
passwd: files ldap
shadow: files ldap
group: files ldap
We should have a go at starting the LDAP server now:
service ldap start