'su lfs' dropping into the background

Anderson Lizardo lizardo at linuxfromscratch.org
Wed Jan 21 08:38:17 PST 2004


On Tuesday 20 January 2004 10:26, James Robertson wrote:
> Bruce Dubbs wrote:
> 
> > Greg Schafer wrote:
> >> Yes, of course. So, your /etc/skel is a mess. I don't see how LFS can do
> >> much about that.
> >>
> > I second that.
> > 
> 
> I third it.  What if we do not put the -m in the useradd command line? 
> We won't get the stuff from a potentially dirty /etc/skel dir.  Is there 
> someting else -m does that I am not aware of that requires us to use it?

It creates the user's $HOME dir chown'ing and chgrp'ing it properly.

I just found a way we can use to avoid useradd copying files from /etc/skel 
(IMHO, we should care about that, to avoid influences from the host system as 
much as possible):

useradd -s /bin/bash -m -k /dev/null lfs

This way, "useradd" will try to copy files from the null device which results 
in _nothing_ being copied. I've tested this and google points some 
occurrences of this method.
-- 
Anderson Lizardo
lizardo at linuxfromscratch.org
http://www.linuxfromscratch.org/




More information about the lfs-dev mailing list