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 2010-03-29 17:30:55

gontzal
Member
Registered: 2009-06-17
Posts: 31

error forcing synchronization

Hi everybody!

When I'am pointed on a user and I press the "Force synchronization" button I obtained a php error:

29-03-2010 16:57
Warning(2): ldap_read() [<a href='function.ldap-read'>function.ldap-read</a>]: Search: No such object
Backtrace :
/opt/lampp/htdocs/glpi/inc/user.class.php:676           ldap_read()
/opt/lampp/htdocs/glpi/inc/ldap.function.php:116                User->getFromLDAP()
/opt/lampp/htdocs/glpi/front/massiveaction.php:526              ldapImportUserByServerId()

29-03-2010 16:57
Warning(2): ldap_get_entries() expects parameter 2 to be resource, boolean given
Backtrace :
/opt/lampp/htdocs/glpi/inc/user.class.php:677           ldap_get_entries()
/opt/lampp/htdocs/glpi/inc/ldap.function.php:116                User->getFromLDAP()
/opt/lampp/htdocs/glpi/front/massiveaction.php:526              ldapImportUserByServerId()

This occurs on any user. I've GLPI 0.72.3 on an Opensuse box. I've no idea of php, so if anyone can help me I'd appreciate.

Offline

#2 2010-03-29 17:55:57

wawa
GLPI-DEV
From: Montpellier / France
Registered: 2006-07-03
Posts: 6,019
Website

Re: error forcing synchronization

what's your ldap config in glpi ? what's your directory ?

Offline

#3 2010-03-30 13:03:15

gontzal
Member
Registered: 2009-06-17
Posts: 31

Re: error forcing synchronization

I've Active Directory and in glpi I'm using the AD template.

I hope it's enough, but if you need more info, please ask me for it.

Thanks in advance

Offline

#4 2010-03-30 14:27:03

JMD
GLPI - Lead
Registered: 2004-09-13
Posts: 9,180
Website

Re: error forcing synchronization

Give us your config  AD/GLPI please


JMD / Jean-Mathieu Doléans - Glpi-project.org - Association Indepnet
Apportez votre pierre au  projet GLPI   : Soutenir

Offline

#5 2010-03-30 15:35:05

gontzal
Member
Registered: 2009-06-17
Posts: 31

Re: error forcing synchronization

At Identification - LDAP:

Name: Total
Server: dc01
Basedn: OU=Comunes,OU=Usuarios,DC=xxx,DC=xxx
ID: 97
Port: 389
Filter: (objectClass=user)
rootdn: domain\root
Login field: samaccountname
TLS: No
Alias: never

Thanks again

Offline

#6 2010-03-30 15:43:18

wawa
GLPI-DEV
From: Montpellier / France
Registered: 2006-07-03
Posts: 6,019
Website

Re: error forcing synchronization

please use the AD preconfiguration model
and please search on the forum, this problem happens all the time

Offline

#7 2012-11-28 17:31:52

nicubalti
Member
Registered: 2012-11-28
Posts: 2

Re: error forcing synchronization

Hello
I  have the following code:

$ldapconn = ldap_connect("mycompany.com")
    or die("Could not connect to LDAP server.");

if ($ldapconn) {

    // binding anonymously
    $ldapbind = ldap_bind($ldapconn);
    $ds = "OU=DEV,OU=Users,OU=CHI,OU=mycompany,DC=mycompany,DC=com";
    $filter="(objectclass=*)";
    $sr = ldap_read($ldapconn, $ds, $filter);
    $info = ldap_get_entries($ldapconn, $sr);

    if ($ldapbind) {
        echo "LDAP bind anonymous successful...";
    } else {
        echo "LDAP bind anonymous failed...";
    }

}

This code gives me the follwing error:
Warning: ldap_read() [<a href='function.ldap-read'>function.ldap-read</a>]: Search: Operations error in D:\SymfonyProject\myreport\web\app_dev.php on line 36
Line 36 is

$sr = ldap_read($ldapconn, $ds, $filter);

if I set the

$ds = "";

then the error disappear but in $info there are no data from ldap. In $info are only same generale information like currenttime, subschemasubentry, dsservicename, supportedcontrol etc.

The message LDAP bind anonymous successful.. is shown

Last edited by nicubalti (2012-11-28 17:37:22)

Offline

#8 2012-11-28 17:33:09

nicubalti
Member
Registered: 2012-11-28
Posts: 2

Re: error forcing synchronization

Sorry for my bad English. Thanks

Offline

Board footer

Powered by FluxBB