wait_for_lock() in mount
Hi,
I'm trying to bring up a stacked file system on top of an NFS mount point both via automount.
For example:
On my client system I have two directories /data1 and /data2 /data1/nfs_01
/data2/nfs_01
nfs_server:/data/nfs_01 is mounted on /data1/nfs_01 (type nfs)
/data1/nfs_01 is mounted on /data2/nfs_01
The automount config files look like:/etc/auto.data1:nfs_01 nfs_server:/data/nfs_01
/etc/auto.data2:nfs_01 -fstype=ecryptfs :/data1/nfs_01
The problem:
When I try to access /data2/nfs_01 it kicks in automount to mount /data1/nfs_01, which in turn kicks in automount again to mount nfs_server:/data/nfs_01 on /data1/nfs_01.
The second mount waits for 10secs for a lock file held by the first mount in mount_nfs.c after mkdir_path().
Is there a way I can configure things such that the second mount doesn't wait?
The lock file is a single global.
Should the file be specific to the mount point?
Any help would be appreciated.
Thanks,
_______________________________________________
autofs mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/autofs
Ian Kent
maintainerQuoted 34 lines · Rajouri Jammu
Hi,
I'm trying to bring up a stacked file system on top of an NFS mount point both via automount.
For example:
On my client system I have two directories /data1 and /data2 /data1/nfs_01
/data2/nfs_01nfs_server:/data/nfs_01 is mounted on /data1/nfs_01 (type nfs)
/data1/nfs_01 is mounted on /data2/nfs_01
The automount config files look like:
/etc/auto.data1:nfs_01nfs_server:/data/nfs_01
/etc/auto.data2:nfs_01-fstype=ecryptfs :/data1/nfs_01The problem:
Quoted 7 lines
When I try to access /data2/nfs_01 it kicks in automount to mount /data1/nfs_01, which in turn kicks in automount again to mount nfs_server:/data/nfs_01 on /data1/nfs_01.
The second mount waits for 10secs for a lock file held by the first mount in
mount_nfs.caftermkdir_path().
So you're running version 4?
Quoted 4 lines
Is there a way I can configure things such that the second mount doesn't wait?
There is a patch around to add a configure option "--disable-mount-locking" but you need to be sure you're mount(8) is at least reasonably up to date.
You may want to look in
http://www.kernel.org/pub/linux/daemons/autofs/v4/
Quoted 6 lines
The lock file is a single global.
Should the file be specific to the mount point?
No, it is meant help prevent corruption of /etc/mtab as the locking in mount(8) was broken for a long time.
Ian
Thank you for the prompt response.
Yes, I'm using autofs4 which came with CentOS release 4.6
mount -V
mount: mount-2.12a
Is that version of mount OK or do I need a newer version to work with the locking path?
If I need a newer version can you please let me know approximately which one?
Lastly, does autofs5 not have this issue?
Thanks,
Quoted 61 lines · Ian Kent
Quoted 34 lines · Rajouri Jammu
Hi,
I'm trying to bring up a stacked file system on top of an NFS mount point both via automount.
For example:
On my client system I have two directories /data1 and /data2 /data1/nfs_01
/data2/nfs_01nfs_server:/data/nfs_01 is mounted on /data1/nfs_01 (type nfs)
/data1/nfs_01 is mounted on /data2/nfs_01
The automount config files look like:
/etc/auto.data1:nfs_01nfs_server:/data/nfs_01
/etc/auto.data2:nfs_01-fstype=ecryptfs :/data1/nfs_01The problem:
Quoted 7 lines
When I try to access /data2/nfs_01 it kicks in automount to mount /data1/nfs_01, which in turn kicks in automount again to mount nfs_server:/data/nfs_01 on /data1/nfs_01.
The second mount waits for 10secs for a lock file held by the first mount in
mount_nfs.caftermkdir_path().So you're running version 4?
Quoted 4 lines
Is there a way I can configure things such that the second mount doesn't wait?
There is a patch around to add a configure option "--disable-mount-locking" but you need to be sure you're mount(8) is at least reasonably up to date.
You may want to look in
http://www.kernel.org/pub/linux/daemons/autofs/v4/Quoted 3 lines
Quoted 12 lines
Quoted 3 lines
The lock file is a single global.
Should the file be specific to the mount point?
No, it is meant help prevent corruption of
/etc/mtabas the locking in mount(8) was broken for a long time.Ian
_______________________________________________
autofs mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/autofs
Ian Kent
maintainerQuoted 4 lines · Rajouri Jammu
Thank you for the prompt response.
Yes, I'm using autofs4 which came with CentOS release 4.6
RHEL-4 U6 should be OK.
But I don't think any of the versions of mount are 100%.
Quoted 7 lines
mount -V
mount: mount-2.12a
Quoted 7 lines
Is that version of mount OK or do I need a newer version to work with the locking path?
If I need a newer version can you please let me know approximately which one?Lastly, does autofs5 not have this issue?
This is a problem with mount and any version of autofs that uses /etc/mtab will have this problem.
The later revisions of autofs v4 and autofs v5 use /etc/mtab somewhat less and so are less vulnerable.
Using the patch requires a configure option to be specified. I'm not sure if this patch has been added to the RHEL-4 package, you'll need to check. In RHEL-5 the configure option is used when the package is built so CentOS 5 will have this already.
Ian
Hi,
I'm again running into problem with cascaded automounts.
This time I'm using the autofs as part of CentOS 5.0 rpm -qa | grep autofs autofs-5.0.1-0.rc2.43.0.2
Quoted 4 lines
Using the patch requires a configure option to be specified. I'm not sure if this patch has been added to the RHEL-4 package, you'll need to check. In RHEL-5 the configure option is used when the package is built so CentOS 5 will have this already
Does autofs-5.0.. version have "--disable-mount-locking" configured by default?
Any suggestions would be of great help.
Thanks!
Ranjit
Quoted 31 lines · Ian Kent
Quoted 4 lines · Rajouri Jammu
Thank you for the prompt response.
Yes, I'm using autofs4 which came with CentOS release 4.6
RHEL-4 U6 should be OK.
But I don't think any of the versions of mount are 100%.Quoted 7 lines
mount -V
mount: mount-2.12aQuoted 7 lines
Is that version of mount OK or do I need a newer version to work with the locking path?
If I need a newer version can you please let me know approximately which one?Lastly, does autofs5 not have this issue?
This is a problem with mount and any version of autofs that uses
/etc/mtabwill have this problem.The later revisions of autofs v4 and autofs v5 use
/etc/mtabsomewhat less and so are less vulnerable.
Quoted 10 lines
Using the patch requires a configure option to be specified. I'm not sure if this patch has been added to the RHEL-4 package, you'll need to check. In RHEL-5 the configure option is used when the package is built so CentOS 5 will have this already.
Ian
_______________________________________________
autofs mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/autofs
Ian Kent
maintainerQuoted 3 lines · Rajouri Jammu
Hi,
I'm again running into problem with cascaded automounts.
What sort of problem?
Quoted 4 lines
This time I'm using the autofs as part of CentOS 5.0 rpm -qa | grep autofs autofs-5.0.1-0.rc2.43.0.2
That's a really old version considering the amount of development that has happened in v5.
Quoted 10 lines
Quoted 3 lines
Using the patch requires a configure option to be specified. I'm not sure if this patch has been added to the RHEL-4 package,
you'll
Quoted 1 line
need to check. In RHEL-5 the configure option is used when the
package
Quoted 1 line
is built so CentOS 5 will have this already
Does autofs-5.0.. version have "--disable-mount-locking" configured by default?
Yes.
Quoted 57 lines
Any suggestions would be of great help.
Thanks!
Ranjit
On Sun, Apr 20, 2008 at 6:50 AM, Ian Kent <[email protected]> wrote:
On Sat, 2008-04-19 at 10:52 -0700, Rajouri Jammu wrote:
> Thank you for the prompt response.
>
>
> Yes, I'm using autofs4 which came with CentOS release 4.6RHEL-4 U6 should be OK.
But I don't think any of the versions of mount are 100%.>
>
> mount -V
> mount: mount-2.12a
>
>
>
> Is that version of mount OK or do I need a newer version to work with
> the locking path?
> If I need a newer version can you please let me know approximately
> which one?
>
>
> Lastly, does autofs5 not have this issue?This is a problem with mount and any version of autofs that uses
/etc/mtabwill have this problem.The later revisions of autofs v4 and autofs v5 use
/etc/mtabsomewhat
less and so are less vulnerable.Using the patch requires a configure option to be specified. I'm not sure if this patch has been added to the RHEL-4 package, you'll
need to check. In RHEL-5 the configure option is used when the package
is built so CentOS 5 will have this already.Ian