Re: umounting too quickly?


From: Amon Ott <ao@rsbac.org>
Subject: Re: umounting too quickly?
Date: Mon, 16 Jul 2001 16:30:10 +0200

Next Article (by Author): Re: Several questions Amon Ott
Previous Article (by Author): Re: Initrd problems again Amon Ott
Top of Thread: umounting too quickly? Sebastian Andersson
Articles sorted by: [Date] [Author] [Subject]


On Fre, 13 Jul 2001 Sebastian Andersson wrote:
> I'm using devfs, reiserfs and lvm together with a rsbac-1.1.1 maintenance
> kernel.
> 
> I mount a lwm-reiserfs filesystem in every users' home:
> find /www -maxdepth 2 -name .x -type d -exec mount /dev/www/www-jail {} \;
> 
> and it seem to work fine.

RSBAC so far did not really handle multiple mounts: All mounts after the first
were simply ignored...
  
> If I then try to unmount them with:
> find /www -maxdepth 2 -name '.x' -type d -exec umount {} \;
> 
> most of the filessystems are still mounted and mount doesn't give any
> errors. Putting a sleep 1 after each umount makes it work correctly, but
> it takes a bit too long for my taste...

> I also get these errors:
> rsbac_adf_request(): rsbac_get_attr() for security_level returned EINVALIDDEV!
> lookup_device(): Invalid device 58:03
> acl_lookup_device(): Invalid device 58:03
> rsbac_get_attr(): Could not lookup device!
> rsbac_adf_request(): rsbac_get_attr() for security_level returned EINVALIDDEV!

...what leads to the problem that with the first umount the data structures
disappear and so the device is unknown. However, umounting might or might
not work, because RSBAC errors do not directly propagate into the umount code.

The upcoming pre8 has just been changed to keep mount counters for 2.4 kernels
(look at /proc/rsbac-info/*devices then). Multiple mounts now seem to be working
correctly. The parent for inheritance is always the first mount point.

Please note: with pre8 you will have to umount the first mount of a device
last, or you will loose inheritance until the next mount of the device, which
replaces the old parent with the new mountpoint!

Amon.
-
To unsubscribe from the rsbac list, send a mail to
majordomo@rsbac.org with
unsubscribe rsbac
as single line in the body.

Next Article (by Author): Re: Several questions Amon Ott
Previous Article (by Author): Re: Initrd problems again Amon Ott
Top of Thread: umounting too quickly? Sebastian Andersson
Articles sorted by: [Date] [Author] [Subject]


Go to Compuniverse LWGate Home Page.