lkml.org 
[lkml]   [2005]   [Aug]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: inotify and IN_UNMOUNT-events
> > ...
> > results in two events:
> > 1. IN_DELETE_SELF (mask=0x0400)
> > 2. IN_IGNORED (mask=0x8000)
> >
> > Any ideas?
>
> "/mnt" is not unmounted, stuff inside of it is.
>
> Watch, say, "/mnt/foo/bar" and when /dev/hda1 is unmounted, you will get
> an IN_UNMOUNT on the watch.

I tried that too. Seems not to work (at least for me):

root@mobil:/tmp/inotify-utils-0.25 # mount /dev/hda6 /mnt
root@mobil:/tmp/inotify-utils-0.25 # ls /mnt/foo/bar
/mnt/foo/bar
root@mobil:/tmp/inotify-utils-0.25 # ./inotify_test /mnt/foo/bar &
inotify device fd = 3
/mnt/foo/bar WD=1
[1] 8454
root@mobil:/tmp/inotify-utils-0.25 # umount /dev/hda6
read = 32
sizeof inotify_event = 16
pevent->len = 0
pevent->len = 0
EVENT ON WD=1
DELETE_SELF (file) 0x00000400

EVENT ON WD=1
IGNORED (file) 0x00008000

root@mobil:/tmp/inotify-utils-0.25 #

Juergen.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-08-31 09:04    [W:0.062 / U:0.516 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site