Friday, May 13, 2016

RHEL7 - LDAP client configuration

RHEL7 - LDAP client configuration

[root@localhost tmp]# id ldapuser1
id: ldapuser1: no such user
[root@localhost tmp]#


Install nss-pam-ldap

[root@localhost tmp]# yum install nss-pam-ldap


[root@localhost tmp]# authconfig-tui

Authentication configuration menu pops up.

On LDAP setting menu, enter the following info.
Do not select use TLS
Server: ldap://expanor.local
Base DN: dc=expanor, DC=local

Press next and enter the following info at the Kerberos setting menu

Realm: EXPANOR.LOCAL
KDC: sam.expanor.local
Admin Server: sam.expanor.local
and check [*] Use DNS to resolve hosts to realms


check nsswitch.conf file
[root@localhost tmp]# vi /etc/nsswitch.conf

passwd:     files sss ldap

wq!


Look for your ldap user that you imported to LDAP server
[root@localhost tmp]# grep ldapu /etc/passwd

no result

Now, server on LDAP database

[root@localhost tmp]# getent passwd ldapuser1
ldapuser1:x:1002:1002:ldapuser1:/home/ldapuser1:/bin/bash
[root@localhost tmp]# getent passwd ldapuser2
ldapuser2:x:1003:1003:ldapuser2:/home/ldapuser2:/bin/bash
[root@localhost tmp]#

if you don't get return result, you might have mistake somewhere.








No comments:

Post a Comment