How can I change my home directory? Is there anything more to it than
editing the line in /etc/passwd?
sjfromm
Sent via Deja.com http://www.deja.com/
Before you buy.
sjfromm
Sent via Deja.com http://www.deja.com/
Before you buy.
> How can I change my home directory? Is there anything more to it than
> editing the line in /etc/passwd?
> sjfromm
> Sent via Deja.com http://www.deja.com/
> Before you buy.
> > How can I change my home directory? Is there anything more to it
than
> > editing the line in /etc/passwd?
> > sjfromm
> > Sent via Deja.com http://www.deja.com/
Sent via Deja.com http://www.deja.com/Quote:> > Before you buy.
You *could* do it that way - but therein lies the path to madness. UseQuote:> How can I change my home directory? Is there anything more to it than
> editing the line in /etc/passwd?
--
Rich Teer
NT tries to do almost everything UNIX does, but fails - miserably.
The use of Windoze cripples the mind; its use should, therefore, be
regarded as a criminal offence. (With apologies to Edsger W. Dijkstra)
Voice: +1 (250) 979-1638
URL: http://www.rite-online.net
> > How can I change my home directory? Is there anything more to it
than
> > editing the line in /etc/passwd?
> You *could* do it that way - but therein lies the path to madness.
Use
> usermod instead. Or, if you're using the automounter, just change
your
> auto_home map, restart automountd, and away you go (yet another
reason why
> turning off the automounter to use /home - or just using /export/home
for
> home directories - is generally a bad idea).
Why is using /export/home a bad place for home directories?
sjfromm
Sent via Deja.com http://www.deja.com/
Before you buy.
That's basically the reason. Usermod has certain sanity checks in itQuote:> Why is it mad? The only reason I can think of is that one might make
> an error editing /etc/passwd. Is there any other reason?
I need to be more precise: /export/home is the place for the homeQuote:> Why is using /export/home a bad place for home directories?
It's far better to set up everyone's home directory in /etc/passwd
or NIS(+) as /home/$USER, and then use the automounter to put things
in the right place. SO, you could start off with /export/home being
the place where people's home directories really live. Then, when that
disk gets full, you add another, say /export/anotherhome, and all
new user accounts created in there. However, as far as you're concerned,
everyone is under /home - much easier and more flexible!
--
Rich Teer
NT tries to do almost everything UNIX does, but fails - miserably.
The use of Windoze cripples the mind; its use should, therefore, be
regarded as a criminal offence. (With apologies to Edsger W. Dijkstra)
Voice: +1 (250) 979-1638
URL: http://www.rite-online.net
> group.com>,
> > > How can I change my home directory? Is there anything more to it
> than
> > > editing the line in /etc/passwd?
> > You *could* do it that way - but therein lies the path to madness.
> Use
> > usermod instead.
{snip}
> Why is it mad? The only reason I can think of is that one might make
> an error editing /etc/passwd. Is there any other reason?
- You started to vi /etc/passwd
- Another user changed their home directory using (say) usermod or
passwd
- You wrote back your changes
Use usermod or passwd -h (or passmgmt -m if you prefer and have root
privileges) or even /usr/ucb/vipw as these will make sure that the
password file is locked appropriately while you're changing it.
--
Tony
This posting does not constitute official support from Sun Microsystems
1. after changing a user's home dir, cd ~user in ksh still use old dir
See example below:
[julie:/export/home/root]grep oracle7 /etc/passwd
oracle7:x:65535:65535:Oracle Workgroup Server user:/opt:/usr/bin/sh
[julie:/export/home/root]cd ~oracle7
ksh: /opt/oracle7: not found
Please note another subshell will do fine:
[julie:/export/home/root]/bin/ksh
[julie:/export/home/root]cd ~oracle7
What does this mean? Thanks.
--
Michael Wang
http://www.mindspring.com/~mwang
3. MC msg: Couldn't change to home dir
5. Changing default rights in home dirs?
7. passwd core dumping on home dir change
9. changing permissions on home dir on sunos 5.7
10. how to get apache to translate server/dir to home dir?
11. Apache MultiViews: /dir returns /dir/, not dir.html
12. weird... can't put a cd \dir\dir\dir\ in a .csh file...
13. How to make a dir not in /home/ftp available anonymously