LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-14-2010, 03:18 PM   #1
Blue_Ice
Member
 
Registered: Jul 2006
Location: Belgium
Distribution: Debian, Fedora, CentOS, Windows
Posts: 361

Rep: Reputation: Disabled
Question ldap+nfs+autofs for centralized storage of home directories


Hi all,

Does anyone have experience with setting up OpenLDAP with NFS and AutoFS regarding to the storage of home directories?
When I googled I got some information, but I have the feeling that most of them are incomplete or maybe even incorrect. So I wonder if someone can help me setting it up.
I already have an NFS share setup for it. Created an ldif file based on some howto's found by google. And finally OpenLDAP is setup and running supporting Samba domain logon and linux client logon.

Code:
# /etc/exports

/opt/nfs/home   10.0.0.0/8(rw)
Code:
# autofs.ldif

dn: ou=auto.master,dc=hulshoff,dc=home
objectClass: top
objectClass: automountMap
ou: auto.master

dn: cn=/home,ou=auto.master,dc=hulshoff,dc=home
objectClass: top
objectClass: automount
automountInformation: ldap:ldap.hulshoff.home:ou=auto.home,dc=hulshoff,dc=home
cn: /home

dn: ou=auto.home,dc=hulshoff,dc=home
objectClass: top
objectClass: automountMap
ou: auto.home

dn: cn=/,ou=auto.home,dc=hulshoff,dc=home
objectClass: automount
cn: Administrator
automountinformation: -rsize=8192,wsize=8192,intr server.hulshoff.home:/opt/nfs/home/&
cn: /
Code:
dn: uid=Administrator,ou=users,dc=hulshoff,dc=home
objectClass: account
objectClass: posixAccount
objectClass: sambaSamAccount
objectClass: shadowAccount
uid: Administrator
cn: Administrator
displayName: Administrator
uidNumber: 50000
sambaSID: S-1-5-21-960022806-<hidden>
sambaPasswordHistory: 00000000000000000000000000000000000000000000000000000000
 00000000
sambaAcctFlags: [U          ]
loginShell: /bin/bash
gidNumber: 50001
sambaLMPassword: <password>
sambaNTPassword: <password>
sambaPwdLastSet: 1265359113
gecos: Administrator
shadowWarning: 7
shadowMax: 99999
userPassword:: <password>
shadowFlag: 0
shadowLastChange: 14615
ou: users
homeDirectory: /home/Administrator
TIA,
Arjan
 
Old 02-15-2010, 08:21 AM   #2
Blue_Ice
Member
 
Registered: Jul 2006
Location: Belgium
Distribution: Debian, Fedora, CentOS, Windows
Posts: 361

Original Poster
Rep: Reputation: Disabled
Fixed it myself...

I changed /etc/sysconf/autofs, which I shouldn't have done. Further more I had to change /etc/autofs_ldap_auth.conf and set usetls="yes".
And last but not least the ldif file should look like:
Code:
dn: nisMapName=auto.master,dc=hulshoff,dc=home
objectClass: top
objectClass: nisMap
nisMapName: auto.master

dn: cn=/home,nisMapName=auto.master,dc=hulshoff,dc=home
objectClass: nisObject
cn: /home
nisMapEntry: ldap:ldap.hulshoff.home:nisMapName=auto.home,dc=hulshoff,dc=home
nisMapName: auto.master

dn: nisMapName=auto.home,dc=hulshoff,dc=home
objectClass: top
objectClass: nisMap
nisMapName: auto.home

dn: cn=/,nisMapName=auto.home,dc=hulshoff,dc=home
objectClass: nisObject
cn: /
nisMapEntry: -fstype=nfs server.hulshoff.home:/opt/nfs/home/&
nisMapName: auto.home
One thing I haven't tried yet is to change the location where the client will expect to find the home directory. Currently I am not going to worry about that. For this I probably need to change the dn: cn=/home,nisMapName=auto.master,dc=hulshoff,dc=home and the attribute homeDirectory of the ldap account should probably also changed to the new location.

Going to test that later on.
 
  


Reply

Tags
autofs, ldap, nfs



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Archiving old files from /home/* directories to less expensive disk storage. Cerephim Linux - Server 6 11-06-2009 11:25 AM
Need help:Configuring autofs to automount the home directories of NIS users. Savita Eli Linux - Server 4 08-26-2009 11:26 PM
Apache 2.2 and LDAP Based home directories tpe Linux - Server 0 07-03-2009 08:22 AM
autofs nfs mounting home directories question extendedping Linux - Networking 3 01-30-2008 03:02 PM
NIS, NFS, autofs and /home folder question ramram29 Linux - Networking 2 08-25-2006 08:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:03 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration