You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2018-10-31 13:12:50

laurentc
Member
Registered: 2011-04-22
Posts: 9

problème liaison annuaire ldap

Bonjour tout le monde,

Après moult recherches et tests, je viens vers vous car je n'ai pas trouvé de solution à mon problème que je vais essayer de détailler autant que possible. D'abord voici ma configuration:

GLPI 9.1.7.1
Xampp 5.5.37 (Apache 2.4.17 et PHP 5.5.37)
Windows Server 2012r2

Lorsque je tente de faire une importation de Users de mon AD, cela ne fonctionne plus.

-> J'ai essayé de paramétrer sur différents AD = KO
Voici la configuration actuelle:

Annuaire LDAP    Nom    S248
Serveur par défaut    Actif   
Serveur: s248.chloches.fr
Port (par défaut 389):389
Filtre de connexion: (&(objectClass=user)(objectCategory=person)(!(userAccountControl:1.2.840.113556.1.4.803:=2)))
BaseDN   
dc=chloches,dc=fr
DN du compte (pour les connexions non anonymes)   
CN=xxx,OU=Info,DC=ch...,DC=fr
Champ de l'identifiant    : samaccountname


-> J'ai une tâche planifiée d'import et de synchro = OK apparemment

Voici le fichier bat:
@echo off
REM Placez-vous dans le dossier ou se trouve le script
cd "C:\xampp\htdocs\glpi\scripts"
REM Exécuter php.exe avec le script et Importation des users
REM le filtre ne renvoi que les utilisateurs non désactivés
C:\xampp\php\php.exe ldap_mass_sync.php -ldapservers_id=1 action=0 ldap_filter="(&(objectClass=user)(objectCategory=person)(!(userAccountControl:1.2.840.113556.1.4.803:=2)))"
REM temporisation
ping 127.0.0.1 -n10 > NUL
REM Exécuter php.exe avec le script et Synchronisation des users
C:\xampp\php\php.exe ldap_mass_sync.php -ldapservers_id=1 action=1 ldap_filter="(&(objectClass=user)(objectCategory=person)(!(userAccountControl:1.2.840.113556.1.4.803:=2)))"
ping 127.0.0.1 -n10 > NUL

VOICI le résultat (jene sais pas pourquoi il m'affiche toute ces lignes?):
  MIB search path: c:/usr/share/snmp/mibs
Cannot find module (IP-MIB): At line 0 in (none)
Cannot find module (IF-MIB): At line 0 in (none)
Cannot find module (TCP-MIB): At line 0 in (none)
Cannot find module (UDP-MIB): At line 0 in (none)
Cannot find module (HOST-RESOURCES-MIB): At line 0 in (none)
Cannot find module (SNMPv2-MIB): At line 0 in (none)
Cannot find module (SNMPv2-SMI): At line 0 in (none)
Cannot find module (NOTIFICATION-LOG-MIB): At line 0 in (none)
Cannot find module (UCD-SNMP-MIB): At line 0 in (none)
Cannot find module (UCD-DEMO-MIB): At line 0 in (none)
Cannot find module (SNMP-TARGET-MIB): At line 0 in (none)
Cannot find module (NET-SNMP-AGENT-MIB): At line 0 in (none)
Cannot find module (DISMAN-EVENT-MIB): At line 0 in (none)
Cannot find module (SNMP-VIEW-BASED-ACM-MIB): At line 0 in (none)
Cannot find module (SNMP-COMMUNITY-MIB): At line 0 in (none)
Cannot find module (SNMP-FRAMEWORK-MIB): At line 0 in (none)
Cannot find module (SNMP-MPD-MIB): At line 0 in (none)
Cannot find module (SNMP-USER-BASED-SM-MIB): At line 0 in (none)
Cannot find module (SNMP-NOTIFICATION-MIB): At line 0 in (none)
Cannot find module (SNMPv2-TM): At line 0 in (none)
Processing LDAP Server: S248, ID: 1
.
Imported: 1
Synchronized: 0
Deleted from LDAP: 0


MIB search path: c:/usr/share/snmp/mibs
Cannot find module (IP-MIB): At line 0 in (none)
Cannot find module (IF-MIB): At line 0 in (none)
Cannot find module (TCP-MIB): At line 0 in (none)
Cannot find module (UDP-MIB): At line 0 in (none)
Cannot find module (HOST-RESOURCES-MIB): At line 0 in (none)
Cannot find module (SNMPv2-MIB): At line 0 in (none)
Cannot find module (SNMPv2-SMI): At line 0 in (none)
Cannot find module (NOTIFICATION-LOG-MIB): At line 0 in (none)
Cannot find module (UCD-SNMP-MIB): At line 0 in (none)
Cannot find module (UCD-DEMO-MIB): At line 0 in (none)
Cannot find module (SNMP-TARGET-MIB): At line 0 in (none)
Cannot find module (NET-SNMP-AGENT-MIB): At line 0 in (none)
Cannot find module (DISMAN-EVENT-MIB): At line 0 in (none)
Cannot find module (SNMP-VIEW-BASED-ACM-MIB): At line 0 in (none)
Cannot find module (SNMP-COMMUNITY-MIB): At line 0 in (none)
Cannot find module (SNMP-FRAMEWORK-MIB): At line 0 in (none)
Cannot find module (SNMP-MPD-MIB): At line 0 in (none)
Cannot find module (SNMP-USER-BASED-SM-MIB): At line 0 in (none)
Cannot find module (SNMP-NOTIFICATION-MIB): At line 0 in (none)
Cannot find module (SNMPv2-TM): At line 0 in (none)
Processing LDAP Server: S248, ID: 1
.....
LDAP Server size limit exceeded: user deletion disabled

Imported: 0
Synchronized: 5
Deleted from LDAP: 0


-> lorsque j'essaie un import avec date ou sans date d'un utilisateur, il note aucun utilisateur à importer. En mode debug voici le message:
PHP Warning: ldap_search(): Search: Invalid DN syntax in C:\xampp\htdocs\glpi\inc\authldap.class.php at line 1381


-> J'ai créé une règle d'affectation automatique des utilisateurs dont voici la configuration:
   
Nom: Agents       Description: importation agents vers GLPI
Opérateur logique: Actif   

Commentaires   
transferts automatiques des agents vers l'entité LOCHES et droits UTILISATEUR par défaut lorsque l'on fait un import de l'AD

Critère: Annuaire LDAP est S248

Action: Entité    Assigner    Entité Racine > LOCHES
Récursif    Assigner    Non
Profils    Assigner    Utilisateurs



J'espère avoir donné assez d'information.
D'avance, merci pour votre aide

Offline

#2 2018-10-31 13:13:44

laurentc
Member
Registered: 2011-04-22
Posts: 9

Re: problème liaison annuaire ldap

oupps je me suis trompé d'endroit :-(

Offline

Board footer

Powered by FluxBB