Phpldapadmin does not work for an unknown reason
Asked Answered
Q

2

9

I'm trying to install LDAP. I've installed slapd and the PhpLDAPAdmin tool on Debian, but when I'm logged in, I cannot do anything. Despite I've logged in as 'cn=admin,dc=barbucha', I see on the right side instead of the tree:

Logged in as: dc=example,dc=com
   This base cannot be created with PLA.

I tried Google, but this error seems to be a rare one. I've created a database there is the 'cn=admin,dc=barbucha' in. (Otherwise I could not use the name to log in.)

Querist answered 17/12, 2012 at 19:44 Comment(0)
Q
17

This happens quite rarely. From an unknown reason the configuring process didn't get data from the LDAP server and didn't set proper values in the /etc/phpldapadmin/config.php script. Somewhere near by line 300 were two important lines generated erroneously:

$servers->setValue('server','base',array('dc=example,dc=com'));
$servers->setValue('login','bind_id','cn=admin,dc=example,dc=com');

These settings uses PhpLDAPAdmin to access LDAP datatase regardless to the login name you've been logged in with. To update these lines helped:

$servers->setValue('server','base',array('dc=barbucha'));
$servers->setValue('login','bind_id','cn=admin,dc=barbucha');
Querist answered 18/12, 2012 at 9:17 Comment(2)
maybe it's not that rare: it's enough to install phpldapadmin before slapd for example.Litotes
I faced this issue when I uninstalled my ldap server and re-installed with a different Base DN, thanks to your answer everything works fine.Burlie
D
0

probably you should add a LDAP root first: create a file in /etc/openldap/

vim /etc/openldap/base.ldif

then input:

dn: dc=em,dc=com
o: RDCenter
objectclass: dcobject
objectclass: organization

and run this command in the directory:

ldapadd  -f base.ldif  -x -D  cn=Admin,dc=em,dc=com -W

Input your own password,and the root node would be added. Reopen the phpldapadmin,you will find everything is well

Decidua answered 17/8, 2017 at 7:27 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.