Operating System - HP-UX
1751957 Members
5247 Online
108783 Solutions
New Discussion юеВ

Re: home directory issue.

 
SOLVED
Go to solution
Teck Sim
Frequent Advisor

home directory issue.

When I log in to server A as applmgr:
login: applmgr
Password:xxxx
It took me to the following directory:-
[SMM1:/u05/apps/applmgr]>

After a cold-install of HP-UX 11 on server B
when I log in to server B as applmgr:

login: applmgr
Password:
Unable to change directory to "/home/applmgr"
Logging in with home = "/".

It doesn't take me to the right directory, which is:
[SMT1:/u01/apps/applmgr]>
instead, I am at:

$

How can I set the directory right, so that each time when I log in as applmgr, it will point me to the right directory?

Thanks in advance.
9 REPLIES 9
Daimian Woznick
Trusted Contributor
Solution

Re: home directory issue.

You can change the home directory of the applmgr account in the /etc/passwd file or you can use SAM.
Craig Rants
Honored Contributor

Re: home directory issue.

Well, first place to look is in /etc/passwd.

grep appl /etc/passwd and look for /home/applmgr

do the same on server a and look for /u05/apps/applmgr

You can either change this with sam (advisable) or with vipw.

GL,
C
"In theory, there is no difference between theory and practice. But, in practice, there is. " Jan L.A. van de Snepscheut
Rich Wright
Trusted Contributor

Re: home directory issue.

The home directory is set as the 6th field in the /etc/passwd file entry.

You can change it in SAM, or with usermod, or an editor.
Chris Wilshaw
Honored Contributor

Re: home directory issue.

Check the setting of the applmgr home directory in /etc/passwd.

It appears to be currently set to /home/applmgr. Use vipw to change this to the correct location.

It's also worth checking the permissions of the correct home directory and any .profile/.login etc type files below it once you've done that.
Ceesjan van Hattum
Esteemed Contributor

Re: home directory issue.

/home/applmgr is the directory noted in the /etc/passwd file of this users.
This directory is not found, so it goes to /
Just change the path in /etc/passwd of this user to /u01/apps/applmgr

Regards,
Ceesjan
V. V. Ravi Kumar_1
Respected Contributor

Re: home directory issue.

hi,

if u are intended to have same users on both servers u can copy /etc/passwd of A to B. then it will work.
other wise issue
pwget -n applmgr --- it should display some thing like this
applmgr:7NLI0/1wJUaKo:103:20:,,,:/u01/apps/applmgr:/usr/bin/ksh
if not change it.
regds
Never Say No
MANOJ SRIVASTAVA
Honored Contributor

Re: home directory issue.

Hi
The home is set in /etc/passwd file in the netry for that user. In case you are not able to go to the home directory the following can be the reasons:

1. Home directory noy set in /etc/passwd file
2. Home directory set in the passwd file and not physically present .
3. the permissions of the home diorecotry so that the user can access it .
4.The length of the whole entry in /etc/passwd file is long so just reduce the comment field in that entry if the path of the home direcotry is long.

Manoj Srivastava
A. Clay Stephenson
Acclaimed Contributor

Re: home directory issue.

You would also see this sort of thing if /home's mountpoint permissions were very restricted (e.g. 000) OR if you were running the automounter and NIS/NIS+ maps and the automounter or NIS were not running.
If it ain't broke, I can fix that.
Teck Sim
Frequent Advisor

Re: home directory issue.

My probelm is solved. I simply copied /etc/passwd from another server to the current server.
Thanks to all of you.