Subject: Re: vipw creating homes
To: Emmanuel Dreyfus <>
From: Greywolf <>
List: tech-userlevel
Date: 03/06/2001 13:36:07
On Tue, 6 Mar 2001, Emmanuel Dreyfus wrote:

# Hi!
# I've added a -h flag to my local vipw. vipw -h creates home directories
# for all users that do not have a home.
# What is your opinion about committing this change? There is one
# drawback: we should not use /nonexistent home directories in
# /etc/passwd, because vipw -h would create /nonexistent
# For now, I just create the directories, and give them away to their
# owners. I think about also copying the files from /usr/share/skel, and
# for this, I would need to define a _PATH_SKEL in paths.h. Any problem
# here?

It probably won't scale too well; if you have a passwd database with,
say, 40,000 users already, the first time you run 'vipw -h', it's going
to have to go out and stat 40,000 paths.  Don't know if you've noted, but
namei() is probably one of the more expensive filesystem operations :-).

# Emmanuel Dreyfus.
# Windows 95, Windows 98, Windows 2000
# Désormais, les OS portent la date de peremption dans leurs noms.

*BSD: For The Network Generation