SUMMARY: NIS+ Home Directory

From: System Admin (root@ksm.my)
Date: Sun Jul 03 1994 - 04:55:19 CDT


SUN Managers,

   Sorry for the (very) late summary, and the problem solved.
   Thanks to all the respondense. All I need to do is, just do not
   click on "AutoHome Setup [ ] Yes if checked" portion in ADMINTOOL.
   and I can see the real home directory when I do a "niscat passwd.org_dir".

   Another thing is, I realise that, when I use the /home as a base
   directory for users home directory (eg. /home/oper/mike) it will not
   create a symbolic link (eg. /home/mike) that it suppose to create
   when I click on the "AutoHome Setup" in admintool.

   Below is one question/answer that I found in file "solaris2.faq"
   (I forgot from where I download it, sorry), about the /home:

>> 3.4) Why can't I write in /home?
>>
>> This is a common one! SunOS is delivered with the "automounter"
>> enabled. The automounter is designed for NFS sites, to
>> simplify maintenance of the list of filesystems that need
>> mounting. However it is a burden for standalone sites.
>>
>> The automounter takes over /home and in effect becomes the NFS
>> server for it, so it no longer behaves like a normal directory.
>> This is normally a Good Thing as it simplifies administration if
>> everybody's home directory is /home/<username>.
>>
>> To kill it off for standalone or small networks, you can comment out
>> the three lines in /etc/init.d/nfs.client that start "if" (from the if
>> to the fi!!), and reboot (Solaris 2.2) or remove the file
>> /etc/rc2.d/S73autofs (Solaris 2.3). You can allways relink
>> that file with /etc/init.d/autofs if you change your mind.
>>
>> To learn about it, read the O'Reilly book "Managing NFS and
>> NIS", or ftp the white paper 'The Art of Automounting". from
>> sunsite.unc.edu in the directory /pub/sun-info/white-papers.
>>

   Thanks to: Mark Halverson mhalvers@admin.co.martin.fl.us
              Andrej.Misik@fmph.uniba.sk
              Andreas Stoll Andreas.Stoll@Germany.Sun.Com
              Gene Loriot epl@kodak.com
              Sekhar Nagasundaram
              Birger
              suzanne

Thank you.

regards

rosley@ksm.my

VISIT MALAYSIA YEAR 1994

===============================================================================
ORIGINAL POSTING

    When I create an NIS+ user, using admintool utility (running Solaris 2.3)
I specify the home directory as "/home/user/mike" where this directory didn't
exist at that time, and I click at "create home directory" (click to ON).
but after successfully add the NIS+ user, I check the NIS+ passwd contents,
but I found out that the home directory changed to "/home/mike".
After that I run the admintool and display the entry for user "mike"
but the home directory still "/home/user/mike".

eg.:
 
# niscat passwd.org_dir | grep mike
mike::103:10:Michael :/home/mike:/bin/csh:8930:0:::::
 
   Running on SUN Sparcstation 10 Solaris 2.3 with below patches:
101250-01, 101262-04, 101277-02, 101284-02, 101294-01, 101297-01,
101306-01, 101311-04, 101316-01, 101317-04, 101318-31, 101325-03,
101327-02, 101328-01, 101329-08, 101330-03, 101331-03, 101332-01,
101340-01, 101343-02, 101344-05, 101345-02, 101347-01, 101350-01,
101359-01, 101362-09, 101368-01, 101371-04, 101378-03, 101379-02,
101381-02, 101384-01, 101388-01, 101389-01, 101398-01, 101409-03,
101411-02, 101415-02, 101416-02, 101418-01, 101425-01, 101428-02,
101429-02, 101448-02, 101471-01, 101484-02, 101489-01, 101493-01,
101494-01, 101497-01, 101500-01, 101512-02, 101514-02, 101520-01,
101521-01, 101534-01, 101545-01, 101546-01, 101594-01, 101672-01,
101674-01.
 
  Is anybody have any ideas on this ? or did I mis-configure something ?
or maybe another patches ?
 
 
===============================================================================
RESPONSE

Mark Halverson mhalvers@admin.co.martin.fl.us :

probably used automount to make a netlink to /home/mike
look to see if /home/user/mike exists, and if so,
cd /home/mike
if you do a pwd and find you are at /home/user/mike,
you have just been automounted!

-------------------------------------------------------------------------------
Andrej.Misik@fmph.uniba.sk :

>
> When I create an NIS+ user, using admintool utility (running Solaris 2.3)
> I specify the home directory as "/home/user/mike" where this directory didn't
> exist at that time, and I click at "create home directory" (click to ON).
> but after successfully add the NIS+ user, I check the NIS+ passwd contents,
> but I found out that the home directory changed to "/home/mike".

        This has something to do with automounter, because users created
        via admintool with home dir e.g. in "/usr/users/mike" have it
        changed to /home/mike, which is symbolic link to /usr/users/mike.
        Since at our site we don't want to use automounter, we changed
        this with database manager.

> After that I run the admintool and display the entry for user "mike"
> but the home directory still "/home/user/mike".
>
        If you displayed it with database manager, than I'm right,
        otherwise I'm probably rigth. But since I'm not very experienced
        with User Account Manager (we're better not using it) I can
        be absolutely wrong :-))

-------------------------------------------------------------------------------
Andreas Stoll Andreas.Stoll@Germany.Sun.Com :
  
I just installed a user with the admintool under /usr/andy. The
admintool changed it to /home/andy. But /home/andy is a link to /usr/andy
May be this helps

-------------------------------------------------------------------------------
Gene Loriot epl@kodak.com :

Nope, Nope, NOPE, everything is just fine. The only problem is if you failed
to click on the "add to automount".

By convention ALL users are to be located in /home/nnnn. It is the job of
the automounter to assign this location to a real directory, such as
/export/home/.... If you were to do a "niscat auto_home.org_dir", you
should see the actual directory that you specified via admintool.

The /home directory is a special reserved one on Solaris 2.3. DO NOT TRY TO
use it directly. Let the system do so, or you will have a fight that you are
bound to loose.

-------------------------------------------------------------------------------
Sekhar Nagasundaram :

Thought that this might be relevant:

The reason is that automounter is running. When you click on the "auto_home
setup" button in admintool, you ask the system to set up the auto_home map
automatically so that whenever you access the home directory, it would show
/home/"user" instead of say /export/home/user which is the physical location.
If you looked in /etc/auto_home you will find a table which shows the physical
location instead of /home/"user" WHICH IS WHAT will appear in the /etc/passwd
file also.

-------------------------------------------------------------------------------
Birger :

autohome setup means that it sets up an entry in the NIS+ auto_home map
that maps server:/home/user/mike to /home/mike. So when you tick the
autohome setup box, it enters /home/<username> into the passwd table,
and a suitable entry into auto_home to map this to the actual directory
you specified.... Perhaps not what you expected.

-------------------------------------------------------------------------------
suzanne :

You have auto-mount turned on, this automatically mounts the "home" directory
in /home. This allows cross mounting of home directories across machines.

-------------------------------------------------------------------------------



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:09:04 CDT