Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
1367 connectés 

  FORUM HardWare.fr
  Systèmes & Réseaux Pro
  Réseaux

  [RESOLU] replication ldap sous squeeze et Openldap 2.4.23

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

[RESOLU] replication ldap sous squeeze et Openldap 2.4.23

n°96025
cureuil57
Posté le 15-05-2012 à 15:53:42  profilanswer
 

Bonjour,
 
j'ai 2 serveurs d'authentification samba/ldap sous squeeze. Le but c'est d'en faire un cluster haute dispo. mais d'abord j'aimerai mettre en place la réplication de l'annuaire d'un serveur à l'autre.
J'utilise ldap 2.4.23, et donc il n'y a plus de fichier de conf slapd.conf
C'est bien dommage par ce que la config de la réplication avait l'air très simple avec ce fichier. La config se fait maintenant dans le dossier /etc/ldap/slapd.d/ qui contient de nombreux fichier de conf et je ne sais pas quoi modifier ni comment. Je trouve aucun tuto sur le net et les quelques docs que j'ai trouvé jusqu'à maintenant ne m'ont pas beaucoup aidé.
 
donc si quelqu'un a déjà fait ce genre de manip un coup de main serait le bienvenu =)
 
je suis à la recherche d'infos, tutos, etc. sur la réplication ldap (multi-maitre ou mirrormod) sous squeeze avec ldap 2.4.23.
 
Merciii d'avance


Message édité par cureuil57 le 16-05-2012 à 17:48:18

---------------
stagiaire... presque Administrateur système & réseaux debutant =D
mood
Publicité
Posté le 15-05-2012 à 15:53:42  profilanswer
 

n°96040
cureuil57
Posté le 16-05-2012 à 08:10:32  profilanswer
 

Personne n'a deja fait ca ?
 
J'ai ce lien qui semble correspondre a mon projet.  
http://www.openldap.org/doc/admin2 [...] lti-Master
Mais je ne vois pas clairement dans quel fichier de conf effectuer les éodification, c'est juste dit que c'est dans /etc/ldap/slapd.d/cn=\config/ mais il y a beaucoup de fichier dans ce dossier.
 
Si quelqu'un pouvait m'éclairer...


---------------
stagiaire... presque Administrateur système & réseaux debutant =D
n°96094
cureuil57
Posté le 16-05-2012 à 17:46:38  profilanswer
 

Bon bah finalement j'ai reussi en faisant une petite pirouette. J'ai appris qu'on pouvait utiliser l'ancien système de configuration.
il suffit de supprimer ou renommer le slapd.d :
 

Code :
  1. mv /etc/ldap/slapd.d/ /etc/ldap/slapd.d.save/


 
Slapd prendra maintenant en compte le fichier slapd.conf =)
 
Je vous met le miens au passage, comme ca si un jours quelqu'un cherche a faire une replication miroir sous squeeze il y arrivera rapidement :
 
sur le premier ldap :

Code :
  1. nano /etc/ldap/slapd.conf


 
et copier :
 

Code :
  1. # This is the main slapd configuration file. See slapd.conf(5) for more
  2. # info on the configuration options.
  3. #######################################################################
  4. # Global Directives:
  5. ServerID 1
  6. # Features to permit
  7. #allow bind_v2
  8. # Schema and objectClass definitions
  9. include         /etc/ldap/schema/core.schema
  10. include         /etc/ldap/schema/cosine.schema
  11. include         /etc/ldap/schema/nis.schema
  12. include         /etc/ldap/schema/inetorgperson.schema
  13. include                /etc/ldap/schema/samba.schema
  14. # Where the pid file is put. The init.d script
  15. # will not stop the server if you change this.
  16. pidfile         /var/run/slapd/slapd.pid
  17. # List of arguments that were passed to the server
  18. argsfile        /var/run/slapd/slapd.args
  19. # Read slapd.conf(5) for possible values
  20. loglevel        none
  21. # Where the dynamically loaded modules are stored
  22. modulepath        /usr/lib/ldap
  23. moduleload        back_hdb.so
  24. moduleload        syncprov.la
  25. # The maximum number of entries that is returned for a search operation
  26. sizelimit 500
  27. # The tool-threads parameter sets the actual amount of cpu's that is used
  28. # for indexing.
  29. tool-threads 1
  30. #######################################################################
  31. # Specific Backend Directives for @BACKEND@:
  32. # Backend specific directives apply to this backend until another
  33. # 'backend' directive occurs
  34. backend                hdb
  35. #######################################################################
  36. # Specific Backend Directives for 'other':
  37. # Backend specific directives apply to this backend until another
  38. # 'backend' directive occurs
  39. #backend                <other>
  40. #######################################################################
  41. # Specific Directives for database #1, of type @BACKEND@:
  42. # Database specific directives apply to this databasse until another
  43. # 'database' directive occurs
  44. database        hdb
  45. # The base of your directory in database #1
  46. suffix          "dc=domain,dc=local"
  47. # rootdn directive for specifying a superuser on the database. This is needed
  48. # for syncrepl.
  49. rootdn          "cn=admin,dc=domain,dc=local"
  50. rootpw                toto
  51. # Where the database file are physically stored for database #1
  52. directory       "/var/lib/ldap"
  53. # The dbconfig settings are used to generate a DB_CONFIG file the first
  54. # time slapd starts.  They do NOT override existing an existing DB_CONFIG
  55. # file.  You should therefore change these settings in DB_CONFIG directly
  56. # or remove DB_CONFIG and restart slapd for changes to take effect.
  57. # For the Debian package we use 2MB as default but be sure to update this
  58. # value if you have plenty of RAM
  59. dbconfig set_cachesize 0 2097152 0
  60. # Sven Hartge reported that he had to set this value incredibly high
  61. # to get slapd running at all. See http://bugs.debian.org/303057 for more
  62. # information.
  63. # Number of objects that can be locked at the same time.
  64. dbconfig set_lk_max_objects 1500
  65. # Number of locks (both requested and granted)
  66. dbconfig set_lk_max_locks 1500
  67. # Number of lockers
  68. dbconfig set_lk_max_lockers 1500
  69. # Indexing options for database #1
  70. index                objectClass eq
  71. index           entryCSN,entryUUID eq
  72. #provider configuration
  73. overlay syncprov
  74. syncprov-checkpoint        100 10
  75. syncprov-sessionlog        100
  76. #consumer configuration
  77. syncrepl rid=001
  78.         provider=ldap://192.168.3.113
  79.         type=refreshAndPersist
  80.         retry="60 +"
  81.         searchbase="dc=domain,dc=local"
  82.         scope=sub
  83.         schemachecking=on
  84.         bindmethod=simple
  85.         binddn="cn=admin,dc=domain,dc=local"
  86.         credentials=toto
  87. mirrormode        on
  88. # Save the time that the entry gets modified, for database #1
  89. lastmod         on
  90. # Checkpoint the BerkeleyDB database periodically in case of system
  91. # failure and to speed slapd shutdown.
  92. checkpoint      512 30
  93. # The userPassword by default can be changed
  94. # by the entry owning it if they are authenticated.
  95. # Others should not be able to see it, except the
  96. # admin entry below
  97. # These access lines apply to database #1 only
  98. access to attrs=userPassword,shadowLastChange
  99.         by dn="cn=admin,dc=domain,dc=local" write
  100.         by anonymous auth
  101.         by self write
  102.         by * none
  103. # Ensure read access to the base for things like
  104. # supportedSASLMechanisms.  Without this you may
  105. # have problems with SASL not knowing what
  106. # mechanisms are available and the like.
  107. # Note that this is covered by the 'access to *'
  108. # ACL below too but if you change that as people
  109. # are wont to do you'll still need this if you
  110. # want SASL (and possible other things) to work
  111. # happily.
  112. access to dn.base="" by * read
  113. # The admin dn has full write access, everyone else
  114. # can read everything.
  115. access to *
  116.         by dn="cn=admin,dc=domain,dc=local" write
  117.         by * read
  118. # For Netscape Roaming support, each user gets a roaming
  119. # profile for which they have write access to
  120. #access to dn=".*,ou=Roaming,o=morsnet"
  121. #        by dn="@ADMIN@" write
  122. #        by dnattr=owner write
  123. #######################################################################
  124. # Specific Directives for database #2, of type 'other' (can be @BACKEND@ too):
  125. # Database specific directives apply to this databasse until another
  126. # 'database' directive occurs
  127. #database        <other>
  128. # The base of your directory for database #2
  129. #suffix                "dc=debian,dc=org"


 
pensez a modifier le fichier pour qu'il corresponde a votre domaine et a votre mot de passe admin.
 
Pour le fichier slapd.conf du deuxieme ldap cest exactement la meme chose sauf qu'il faut mettre ServerID 2 et l'adresse du provider (cest a dire l'adresse du ldap01).


---------------
stagiaire... presque Administrateur système & réseaux debutant =D
n°101453
simonet
Posté le 03-10-2012 à 13:56:14  profilanswer
 

Configuration : fichier slapd.conf
L'intégralité de la configuration du serveur OpenLDAP (le démon slapd) s'effectue en modifiant le fichier slapd.conf, situé dans le répertoire /etc/ldap.
 
Editer le fichier de configuration du serveur /etc/openldap/slapd.conf avec les entrées suivantes :
 
access to attr=userPassword
by self write
by anonymous auth
by dn="cn=Manager,dc=menara,dc=ma" write
by * compare
 
access to *
by self write
by dn="cn=Manager,dc=menara,dc=ma" write
by * read
 
 
 
database  bdb
suffix    "dc=menara,dc=ma"
rootdn    "cn=Manager,dc=menara,dc=ma"
rootpw    ijFYNcSNctBYg  
 
 
Utiliser la commande :
 
slappasswd -v -s secret -h {CRYPT}
 
 
pour générer le mot de passe crypté cprrespondant à secret . Ce mot de passe crypté sera utilisé pour le champ rootpw.
 
et pour plus de configuration  de openldap de A a Z voila le lien http://electro-media.blogspot.com/ [...] on-de.html


Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Systèmes & Réseaux Pro
  Réseaux

  [RESOLU] replication ldap sous squeeze et Openldap 2.4.23

 

Sujets relatifs
Ping - Défaillance général HELP !!!Help !! CRM ERP
Antivirus - Console d'administration pour clients hors annuaire LDAPhelp,pc vue comme peripherique unknow device
Firewall + LDAP[HELP]Recuperer des mails effacés sur un PST
Réplication file serveur windows / clusterPousser l'authentification Squid-LDAP
Plus de sujets relatifs à : [RESOLU] replication ldap sous squeeze et Openldap 2.4.23


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR