Home >Backend Development >PHP Problem >How to install and configure linux php ldap
Linux php ldap installation and configuration method: first use yum to install the phpldapadmin tool; then modify the phpldapadmin configuration file; then start the http service; and finally access phpldapadmin.
Recommended: "PHP Video Tutorial"
Linux system installation and configuration LDAP management tool phpldapadmin to achieve web-based management ldap
phpldapadmin provides access through the http service, so you need to install the http environment first
yum -y install httpd php php-ldap php-gd php-mbstring php-pear php-bcmath php-xml
yum to install the phpldapadmin tool
After configuring the http environment, use yum to install phpldapadmin Tool yum -y install epel-releaseyum –enablerepo=epel -y install phpldapadmin
Modify the phpldapadmin configuration file
The phpldapadmin configuration file is: /etc/phpldapadmin/config.php, the specific configuration modifications are as follows :[root@localhost ~]# vim /etc/phpldapadmin/config.php#Uncomment line 397 and add comments to line 398 $servers->setValue('login','attr','dn');// $ servers->setValue('login','attr','uid');
[root@localhost ~]# vim /etc/httpd/conf.d/phpldapadmin.conf
// Modify configuration # Apache 2.4Require local #Add a line to specify the accessible ip segment (although I don’t know why, but this management tool cannot be run without filling it in, so I just wrote the local ip directly) Require ip 172.0. 0.0/8 #This allowed IP segment is the user’s own IP segment
Start http service
systemctl restart httpd
Access phpldapadmin
http://10.9.100.100:8080/phpldapadmin/Login: cn=Manager,dc=baidu,dc=com / 12345678
If you encounter the following error after logging in :
This base cannot be created with PLA. The problem occurs mainly when importing base.ldif. It is best to use the automatically generated base.ldif for import instead of creating it manually.
The above is the detailed content of How to install and configure linux php ldap. For more information, please follow other related articles on the PHP Chinese website!