2003-09-12 00:14:41

by Arun Sharma

[permalink] [raw]
Subject: VFS: Busy inodes after unmount on 2 way SMP


We've seen a few "VFS: Busy inodes after unmount. Self-destruct in 5 seconds. Have a nice day.." messages on a dual processor NFS client. Here's the use case:

- Due to network load issues, the NFS server becomes unreachable for some time
- The automounter tries to expire the mount
- The unmount finds a couple of busy inodes. Putting some debug printks shows that typically two inodes are busy i.e. have inode->i_count == 1. But they don't have any waiters on inode->i_wait. Further, the inodes that are busy are
/mnt/foo -> autofs mount point
/mnt/foo/bar -> bar is a symbolic link

It's not clear if this is a NFS issue or a autofs issue, but it's seen often with autofs. Are there any known race conditions that have been fixed after 2.4.20 ? The two calls I'm worried about are:

fs/autofs/root.c:305: d_instantiate(dentry, iget(dir->i_sb,ent->ino));
fs/autofs/root.c:416: d_instantiate(dentry, iget(dir->i_sb,ino));

-Arun




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs


2003-09-12 23:33:44

by Ion Badulescu

[permalink] [raw]
Subject: Re: VFS: Busy inodes after unmount on 2 way SMP

On Thu, 11 Sep 2003 17:11:40 -0700, Arun Sharma <[email protected]> wrote:

> We've seen a few "VFS: Busy inodes after unmount. Self-destruct in 5 seconds. Have a nice day.." messages on a dual processor NFS client. Here's the use case:
>
> - Due to network load issues, the NFS server becomes unreachable for some time
> - The automounter tries to expire the mount
> - The unmount finds a couple of busy inodes. Putting some debug printks shows that typically two inodes are busy i.e. have inode->i_count == 1. But they don't have any waiters on inode->i_wait. Further, the inodes that are busy are
> /mnt/foo -> autofs mount point
> /mnt/foo/bar -> bar is a symbolic link
>
> It's not clear if this is a NFS issue or a autofs issue, but it's seen often with autofs. Are there any known race conditions that have been fixed after 2.4.20 ? The two calls I'm worried about are:
>
> fs/autofs/root.c:305: d_instantiate(dentry, iget(dir->i_sb,ent->ino));
> fs/autofs/root.c:416: d_instantiate(dentry, iget(dir->i_sb,ino));

I don't know if it's the same issue, but I've seen it many many times
while testing amd's autofs functionality. It occurs when a non-empty
autofs filesystem is unmounted, e.g. if it has some leftover
subdirectories from previous mounts. Therefore I'd say it's quite
clearly an autofs issue, at least in my case.

Do you see it when shutting down the automounter, or in other cases as
well?

Ion

--
It is better to keep your mouth shut and be thought a fool,
than to open it and remove all doubt.


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

2003-09-13 00:11:06

by Arun Sharma

[permalink] [raw]
Subject: Re: VFS: Busy inodes after unmount on 2 way SMP

Ion Badulescu wrote:
>
> I don't know if it's the same issue, but I've seen it many many times
> while testing amd's autofs functionality. It occurs when a non-empty
> autofs filesystem is unmounted, e.g. if it has some leftover
> subdirectories from previous mounts. Therefore I'd say it's quite
> clearly an autofs issue, at least in my case.

Do you have a case that can deterministically reproduce the issue ?

> Do you see it when shutting down the automounter, or in other cases as
> well?

Everytime I've seen it, it's during an unmount by /usr/sbin/automount after the mount has expired. It's usually coupled with a temporarily unreachable NFS server.

-Arun



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

2003-09-13 00:17:18

by Ion Badulescu

[permalink] [raw]
Subject: Re: VFS: Busy inodes after unmount on 2 way SMP

On Fri, 12 Sep 2003, Arun Sharma wrote:

> Ion Badulescu wrote:
> >
> > I don't know if it's the same issue, but I've seen it many many times
> > while testing amd's autofs functionality. It occurs when a non-empty
> > autofs filesystem is unmounted, e.g. if it has some leftover
> > subdirectories from previous mounts. Therefore I'd say it's quite
> > clearly an autofs issue, at least in my case.
>
> Do you have a case that can deterministically reproduce the issue ?

Oh yeah, easily. Kill the automounter while some things are mounted,
unmount everything by hand but do not rmdir the mountpoints. When you
unmount the autofs filesystem itself, you will get the self destruct
message.

> Everytime I've seen it, it's during an unmount by /usr/sbin/automount
> after the mount has expired. It's usually coupled with a temporarily
> unreachable NFS server.

So maybe this is a different issue than the one I am describing...

Ion

--
It is better to keep your mouth shut and be thought a fool,
than to open it and remove all doubt.



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs