LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 08-08-2006, 11:59 AM   #46
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492

Okay, it is slightly less confusing. I understand now you want the machine used as the LDAP server to be also an NFS server.

One question remains: in your case, is that single machine already set as an NFS server, and are the user's home directories already exist on it.

By the way, the usual convention is to have the home directories on /export/home/<username> not /home/<username>.
 
Old 08-08-2006, 12:49 PM   #47
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
yea right its /export/home/test2.

Well no NFS server is there on that single machine.

Well i didnt create any user's directories on it . I just created the user using DS console and in its home directory option i gave the path /export/home/test2. But when i tried to login with test2 user from ldap client workstation it didnt mount its home directory but login was successful.

I tried to create folder on LDAP Server machine
bash#pwd
/export/home
bash#mkdir test2
It gave me some error as i m not in office so cannot tell u exact error.

Last edited by capricorn80; 08-08-2006 at 12:52 PM.
 
Old 08-08-2006, 02:39 PM   #48
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
On each client machine, just add this line to the /etc/auto_home file:
Code:
* nfs-server:/export/home/&
Of course, replace "nfs-server" with the hostname of your LDAP/NFS server.

There is no problem creating a directory in /export/home as root, I think you had an error message when you tried to create one under /home, which is by default illegal.

Don't forget to change the owner of the home directories to their respective owners, use their numerical id, as the LDAP server cannot be a LDAP client for the passwd database. Alternatively, have all the LDAP users exist in the LDAP server /etc/passwd file.
 
Old 08-09-2006, 05:26 AM   #49
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
hi !
I just edit the /etc/auto_home file and add the line * myserver:/export/home/& on ldap client machine and then trying to login with user test2 but its still giving me error " cannot access Home directory".

I didnt understand the lines given below
Don't forget to change the owner of the home directories to their respective owners, use their numerical id, as the LDAP server cannot be a LDAP client for the passwd database. Alternatively, have all the LDAP users exist in the LDAP server /etc/passwd file.

Last edited by capricorn80; 08-09-2006 at 05:43 AM.
 
Old 08-09-2006, 06:30 AM   #50
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
On the "myserver" machine, run
Code:
chown 156 /export/home/test2
I'm not sure you have done anything to have these home directories NFS shared though, did you ?
 
Old 08-09-2006, 06:40 AM   #51
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
no.
i told u i just add the path in Posix User option where we have Home Directory Attribute in Directory Server and after that i add the line * myserver:/export/home/& in /etc/auto_home file .
 
Old 08-09-2006, 01:43 PM   #52
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
Add this line to the /etc/dfs/dfstab
Code:
share -F nfs -o rw -d "home dirs" /export/home
then run one of these commands,
on Solaris 10 and newer:
Code:
svcadm enable network/nfs/server
on Solaris 9 and older:
Code:
/etc/init.d/nfsserver start
 
Old 08-10-2006, 12:53 AM   #53
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
Add this line to the /etc/dfs/dfstab

Code:
share -F nfs -o rw -d "home dirs" /export/home
U didnt mention whether i should i add this to solaris 10 ldap server or solaris 9 ldap client.
I first add this code to solaris 10 and when i tried to execute command /etc/init.d/nfs.server start the message was NFS server was not started because no entry in /etc/df/dfstab. So i added the the line to the /etc/dfs/dfstab
share -F nfs -o rw -d "home dirs" /export/home in solaris 9 ldap client.
and /etc/init.d/nfs.server worked ok. Then i try to login with test2 user but it didnt work as same error " unable to access home directory ". I also tried to use this command
share -F nfs -o rw -d "home dirs" /export/home
only on solaris 9 ldap client still test2 got same login error.

chown 156 /export/home/test2
this command also not working after i started the nfs
error was : No such file or directory.

I have tried all possibilities but all were use less.

Last edited by capricorn80; 08-10-2006 at 12:58 AM.
 
Old 08-10-2006, 01:49 AM   #54
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
I'm afraid you are completely missing how NFS works.
The machine that need to share the home directories is the NFS server (which you still confusingly call the LDAP server).

Consequently, the above commands are only to be run on the NFS server.

About the chown, if it fails on the NFS server, you have missed to create the test2 user's home directory.
I believe that is obvious from the error message.
 
Old 08-10-2006, 02:01 AM   #55
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
not exactly . I used NFS on linux . but there are some confusion going on with respect to ldap dirctory mounting. i got it wrong i thought u wrote this command
/etc/init.d/nfsserver start
to run it on solaris 9 . but your meaning was that to start nfs server on solaris 9 we can use the above command.
 
Old 08-10-2006, 02:35 AM   #56
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
i just performed the following steps to mount the user home directory.
step1: on client machine i added entry in /etc/auto_home file
* myserver:/export/home/&
step2: then i created a folder on ldap server
mkdir /export/home/test2
chown 156 /export/home/test2
and then on ldap server i configure the nfs and added line to /etc/dfs/dfstab
share -F nfs -o rw -d "home dirs" /export/home
and in last
svcadm enable network/nfs/server
I think this is all procedure to mount user home directories using nfs.
let me try to login from client machine.
No not working same error " unable to access home directory. click ok to start failsafe session or cancel to restart login.
 
Old 08-10-2006, 05:13 AM   #57
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
If u got free. plz reply
 
Old 08-10-2006, 10:47 AM   #58
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
On the server machine, run
Code:
ls -ld /export/home/test2
On the client machine, run
Code:
showmount -e myserver
ls -l /net/myserver/export/home
ls -ld /home/test2
and post the output.
 
Old 08-11-2006, 12:05 AM   #59
capricorn80
Member
 
Registered: Jun 2006
Distribution: CentOS
Posts: 154

Original Poster
Rep: Reputation: 15
bash-3.00# ls -ld /export/home/test2
drwxr-xr-x 2 156 root 512 Aug 10 12:02 /export/home/test2

bash-2.05# showmount -e myserver
showmount: myserver :RPC : unknown host

bash-2.05# ls -l /net/myserver/export/home
/net/myserver/export/home: No such file or directory

bash-2.05# ls -ld /home/test2
/home/test2: No such file or directory.
 
Old 08-11-2006, 01:26 AM   #60
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
Replace "myserver" by this machine's IP address in the /etc/auto_home files.
For example assuming it is 192.168.1.2, the file would be:
Code:
* 192.168.1.2:/export/home/&
Restart the automounter:
Code:
/etc/init.d/volmgt stop; /etc/init.d/volmgt start
then run again on the client side:
Code:
showmount -e 192.168.1.2
ls -l /net/192.168.1.2/export/home
ls -ld /home/test2
 
  


Reply



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
Configure LDAP yongsp Linux - Software 3 04-15-2006 02:54 AM
pam + ldap client paul_mat Linux - Networking 0 10-25-2005 10:55 PM
LDAP client configuration help omart Linux - Software 1 11-22-2004 02:06 AM
suse 9.1 as ldap client egyptian Linux - Networking 0 07-19-2004 02:41 AM
Configure LDAP rockwell_001 Linux - Software 0 07-07-2004 10:47 AM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 03: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