RHEL autofs/automount issue

Moderator: cah

Post Reply
cah
General of the Army / Fleet Admiral / General of the Air Force
General of the Army / Fleet Admiral / General of the Air Force
Posts: 1342
Joined: Sun Aug 17, 2008 5:05 am

RHEL autofs/automount issue

Post by cah »

I was working on a RHEL 6.4 server (laxm1281) and trying to register it with RHN Satellite server.
When I tried to create a directory, I got the following error message:

Code: Select all

# laxm1281:/apps.mdt%mkdir ks
mkdir: cannot create directory `ks': Permission denied
I searched online and found some clues.
First, I can use 'fuser' command to check on the directory.

Code: Select all

# laxm1281:/root%fuser -mv /apps.mdt
                     USER        PID ACCESS COMMAND
/apps.mdt:           root       2995 f.... automount
Then, I can kill or stop this process and the directory will become writable.

Code: Select all

# service autofs stop
Automount reads from /etc/auto.master file for the list of automounted file systems/directories.
After checking the file, I didn't see anything in it. Then, I checked /etc/nsswitch.conf file. It has the folloiwng setting for automount:

Code: Select all

automount:     files nis
This means automount will read an auto.master file from NIS that I have no access. I believe /apps.mdt and others reside in NIS auto.master file.

Once I remove "nis" from automount line in /etc/nsswitch.conf, /apps.mdt is no longer automounted after restarting autofs/automount.

Code: Select all

laxm1281:/etc%service autofs restart    
Stopping automount:                                        [  OK  ]
Starting automount:                                        [  OK  ]
CAH, The Great
Post Reply