Ask Your Question
0

How do I create local user's account and LDAP user's account in a mixed environment

asked 2014-09-04 15:39:55 -0500

xaz gravatar image

We have a mixed environment that most servers (Linux) are LDAP clients that are managed by LDAP servers. User's account information is stored on LDAP servers (Sun One Directory Server). However, there are a number of servers that are not LDAP managed and user's accounts are stored locally. We try to manage adding new user's account in an automated fashion using puppet. But I don't know how I can accomplish this thing in such a mixed environment. Typically when we do this task not using puppet, we'll add an entry to LDAP servers then create new user's home directory only on LDAP clients, then we'll update local /etc/passwd, /etc/shadow files then create new user's home directory on non-LDAP clients. How do I do this in puppet?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-09-05 05:47:32 -0500

cristaldo gravatar image

I really didn't get the idea. Why have you have to create a home directory at the client? and the user at the Ldap server? There is no sense. If your server is configured to search users on the Ldap Base, all you need to do is to configure the PAM session to create the home directory automatically with the library pam_mkhomedir.so . There's no need to do this manually. But if you have some servers that you don't use with Ldap Server, it's simple to create a module of users to manage them with puppet.

edit flag offensive delete link more

Comments

I didn't know there is a pam module called pam_mkhomedir.so. This is a good information to know. What does it do? Does it work for both CentOS 5 and 6?

xaz gravatar imagexaz ( 2014-09-08 10:02:33 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2014-09-04 15:39:55 -0500

Seen: 1,229 times

Last updated: Sep 05 '14