History of /home Directory – When Did It Appear?

directory-structurefhshistoryhome

Originally in Unix, /usr was used for user (home) directories. So if I had a user named alex, my home directory would be /usr/alex. (Interestingly, Plan 9, the successor to Unix, still has user directories in /usr.)

Nowadays, of course, we store home directories in /home. (At least on GNU/Linux. I don't know about other Unices, but OS X doesn't count.) At what point did this become standard practice? What Unix flavor did it appear in? How long did adoption by other Unices take? Has /home been adopted by everyone?

I've done some searching on here, but turned up nothing.

Best Answer

This change was introduced by BSD after 1985 (BSD 4.2 was still documenting /usr) and in or before 1988 (BSD 4.3/SunOS 4.1 hier(7) manual page already documents /home). It was quickly followed by Solaris 2.0 (which kind of merged System V and BSD) and was later adopted by most other Unix vendors.

This is from the Solaris 2.0 useradd manual page:

   -D          Display the default values for group, basedir, skel, shell,
               inactive, and expire.  When used with the -g, -b, -f, or -e
               options,  the  -D  option  sets  the default values for the
               specified fields.  The default values are:

                       group       other (GID of 1)
                       basedir     /home
                       skel        /etc/skel
                       shell       /sbin/sh
                       inactive    0
                       expire      Null (unset).

Before that, older Unixes were using either the traditional /usr directory or some variants like /user1 documented in SVR3 and SVR4.0. Unix version 7 hier(7) manual page defines /usr as the default location for user's home directory:

/usr/wd/     initial working directory of a user, typically wd is the
             user's login name

Unix version 6, the first Unix to be widely released outside of the Bell Labs had not the hier manual page yet but was already using and documenting /usr.

There are several reasons that explain the move from /usr to something else, including:

  • With some Unix versions, upgrading the OS was blowing away the /usr directory.

  • Usernames like tmp, src, bin, local and the likes were forbidden as they clashed with existing directories under /usr.

  • Using /usr as an automounter base directory was not possible as it was not empty (Thanks to Johan for pointing this)

  • Diskless machines were expected to use a read only NFS share for /usr but read-write home directories

Related Question