Sponsored Content
Top Forums UNIX for Advanced & Expert Users Problem: Automounting Home directory for nis & nfs configuration doesn't work Post 302141304 by pioneer on Thursday 18th of October 2007 02:07:56 PM
Old 10-18-2007
Problem: Automounting Home directory for nis & nfs configuration doesn't work

Hi all,
First of all, i am so sorry about my bad level in English writing.
I have some problem in linux and i hope the experts of this forum to help me if they have enough time to reply to me.

I have a scenario of configuring NIS and NFS in Redhat Linux environment such that user can login from any machine in the network and after he login, the home directory is supoosed to be mounted from the server using the automounting .
I configured the NFS server and NIS server and i checked everything and it is supposed everything is OK (all the related daemons are running). But the problem started when i start configuring the client. I started by configuring the NFS client because my goal is to mount the home directory of the user from the server once he login to the client machine. After i configured the NFS, i configured the NIS client. as i could see, NIS works well, because i can get the passwd file from the NIS server by running the command 'ypcat passwd' in the NIS client. But the problem started when i tried to log in in the client machine. The error which appeared showed that i can't login because the home directory is not found. If i login as root, no error appear and i can login. But when i try to login using the other accounts which created in the NIS server, i can't login because that error appears.

I followed the next procedure to configure the two machines:server and client:
1- in the server:
- i add "/home *(rw,sync)" to the file /etc/exports
- i run the command exportfs -a
- i run and chkconfug: nfslock, nfs and portmap

2- in the client:
- i run and chkconfig: nfslock, netfs, and portmap
- i duplicate the home directory, rename the new copy to home.old and delete all the contents of the original home
- i mounted the home of the server to the home directory in the client using the mount command and it worked. then i unmount it using umount.
- i added "/home /etc/auto.home --timeout 600" to etc/auto.master file
- i created the file etc/auto.home and i add this line to it "* -fstype=nfs,soft,intr,rsize=8192,wsize=8192,nosuid,tcp /
<server ip address>:/home:&"
- i run and chkconfig autofs

3- in the server:
- i edit /etc/sysconfig/network by adding the line "NISDOMAIN="NIS-SCHOOL-NETWORK""
- i edit /etc/yp.conf by adding the line "ypserver 127.0.0.1"
- i run and chkconfig: portmat, yppasswdd, ypserv
- i run /usr/lib/yp/ypinit -m
- i run and chkconfig ypbind and ypxfrd
- i added a new user in the server and set his password

4- in the client
- i run authconfig and specify the name of domain and the server ip address
- i run and chkconfig portmap, ypbind
- i verifed the name resolution of both client and server
- i tested nis access to nis server by runing ypcat in the client to get passwd file
- i can ssh from the server to the client by using one of the account created in the nis server.

after this step: when i tried to login from the client using one of the nis server accounts, the next error appears: home directory not found and i can't login. when i login using the root account i can login.


So, pleeeeeeeeeeeeeeeeeeeeeeeeeeeeeas help me in this problem
Thanks in advance
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

NFS mount home directory

Hello All, I have a question that I think I have the answer to but I'm not sure. All the information I get kind of dance around it. Well, my question is if you have NFS running, automount running, with auto_master and auto_home on a server. If a user logs in form cleint machine that has... (3 Replies)
Discussion started by: larry
3 Replies

2. UNIX for Dummies Questions & Answers

why doesn't this script work on my home computer?

Now it could be as simple as at work I use tsch, and at home it is bash. Warning, first post and I am a complete newbie to unix. At work, I use a simple script for updating a window when I am watching to see how a render is doing... while 1 echo --------------------------- echo ls -lrth... (1 Reply)
Discussion started by: iStealMusic
1 Replies

3. UNIX for Dummies Questions & Answers

home directory & group in UNIX question

folks; I'm going to use LDAP on Solaris 10 to authenticate users, i have 3 questions, i'm hoping it can be possible: 1. when users login for the first time, Is there a way to auto create a home directory like "/home/"user_name" so we don't have to a create a home directory for every single... (3 Replies)
Discussion started by: Katkota
3 Replies

4. UNIX for Dummies Questions & Answers

sleep 10 && command doesn't work

Hi there, I found a trick to easily postpone a command by a few seconds: supernova:~# sleep 10 && command &If you logout, the command should still be executed... But not all the time. Could anyone of you explain me why the following command is executed even after logging out: supernova:~# sleep... (2 Replies)
Discussion started by: chebarbudo
2 Replies

5. Red Hat

PAM configuration: Kerberos authentication and NIS authorization problem

Hi, I've configured two linux boxes to authenticate against Windows Active Directory using Kerberos while retrieving authorization data (uids, gids ,,,)from NIS. The problem I ran into with my PAM configuration is that all authentication attempts succeed in order.i.e. if someone tried his... (0 Replies)
Discussion started by: geek.ksa
0 Replies

6. AIX

Problem with NFS mount and network configuration between AIX and Windows 2003 servers

I ‘m beginner on unix I want to move an unix aix post 5.2 on distant site for use catia V4 with a foundation of data accommodated by a serveur windows 2003 and an environment accommodated on the serveur aix. The computer was linked up by IP (122.0.0.8) with waiter 2003 (via NFS) and the waiter... (8 Replies)
Discussion started by: astiaous
8 Replies

7. Shell Programming and Scripting

Why doesn't piping ls to cd work if there's only one directory?

Hey guys. If I'm in a directory with only one directory, for example: foo@bar:/$ ls really-complicated-or-long-dir-name Why wouldn't piping this single line of output into cd work? foo@bar:/$ ls | cd I'm just getting started with the shell and I was trying to navigate into a directory with a... (1 Reply)
Discussion started by: Hipster
1 Replies

8. UNIX for Dummies Questions & Answers

[Solved]Can anyone tell me why -H flag with sudo doesn't switch to the target user's home directory?

I have checked the man page ,which says : The -H (HOME) option sets the HOME environment variable to the homedir of the target user (root by default) as specified in passwd(5). By default, sudo does not modify HOME But I have tried below command: #... (1 Reply)
Discussion started by: Michaelw321
1 Replies

9. Emergency UNIX and Linux Support

NIS created users without a home directory

Hi all, So I have created two Centos machines. One is configured as a NIS master and the second is a NIS cleint. The NIS configs are all working perfectly. I created a user nisuser on NIS Master and I can use it on the client. BUT it doesnt show a home directory . Ive been told there is... (9 Replies)
Discussion started by: Junaid Subhani
9 Replies

10. Solaris

NFS mounts not automounting on boot

I have several Solaris 11.2 zones. when I reboot them I have to go in and do mountall to mount the NFS mounts. any ideas where to troubleshoot why they are not automounting? (2 Replies)
Discussion started by: os2mac
2 Replies
ypinit(1M)						  System Administration Commands						ypinit(1M)

NAME
ypinit - set up NIS client SYNOPSIS
/usr/sbin/ypinit [-c] [-m] [-s master_server] DESCRIPTION
ypinit can be used to set up an NIS client system. You must be the superuser to run this command. This script need not be used at all if ypbind(1M) is started with the -broadcast option (it is invoked with this option from the svc:/network/nis/client:default service). Normally, ypinit is run only once after installing the system. It may be run whenever a new NIS server is added to the network or an existing one is decommissioned. ypinit prompts for a list of NIS servers to bind the client to; this list should be ordered from the closest to the furthest server. Each of these NIS servers must be listed in either the /etc/hosts or the /etc/inet/ipnodes file along with its IP address. ypinit stores the list in file /var/yp/binding/domain/ypservers. This file is used by ypbind when run without the -broadcast option. OPTIONS
-c Set up a ypclient system. -m Build a master ypserver data base. -s master_server Slave data base. master_server must be the same master configured in the YP maps and returned by the ypwhich -m command. FILES
/etc/hosts /etc/inet/ipnodes /var/yp/binding/domain/ypservers ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWnisu | +-----------------------------+-----------------------------+ SEE ALSO
svcs(1), svcadm(1M), ypbind(1M), sysinfo(2), hosts(4), ipnodes(4), attributes(5), smf(5) NOTES
The NIS client service is managed by the service management facility, smf(5), under the service identifier: svc:/network/nis/client:default Administrative actions on this service, such as enabling, disabling, or requesting restart, can be performed using svcadm(1M). The ser- vice's status can be queried using the svcs(1) command. BUGS
ypinit sets up the list of NIS servers only for the current domain on the system when it is run, that is, the domain returned by the SI_SRPC_DOMAIN command to sysinfo(2). Care should be taken to ensure that this is the same as the desired domain for NIS client processes. SunOS 5.10 13 Aug 2004 ypinit(1M)
All times are GMT -4. The time now is 11:42 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy