Gentoo Archives: gentoo-user

From: Neil Bothwick <neil@××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] pmount question
Date: Tue, 22 Feb 2011 01:04:18
Message-Id: 20110222001111.56c63e95@digimed.co.uk
In Reply to: [gentoo-user] pmount question by David Relson
1 On Mon, 21 Feb 2011 18:58:38 -0500, David Relson wrote:
2
3 > I've also modified /etc/udev/rules.d/10-local.rules to use "pmount
4 > device label" rather than "mount -a". This is mounting flash drives
5 > in /media as desired:
6
7 mount -a was always a bad idea, because it could potentially affect
8 drives other than the one the rule was intended for. What would happen if
9 you had unmounted a filesystem to run fsck on it and you plugged in your
10 USB drive?
11 >
12 > root@osage media # ls -l
13 > total 32
14 > drwx------ 19 root plugdev 16384 Dec 31 1969 PNY
15 > drwx------ 3 root plugdev 16384 Dec 31 1969 SD_2G
16 >
17 > However (as can be seen above) the permissions are 700, which
18 > makes the drives unusable by members of the plugdev group.
19 >
20 > Alternatively, I can use "pmount -u 007 device label" to provide full
21 > access to the plugdev group. This seems awkward and inelegant.
22 >
23 > What's the right way to use pmount and set permissions?
24
25 pmount is supposed to be run as a user and it mounts the filesystem owned
26 by the user running it. If you only have a single user, you could call
27 pmount with su. If you have multiple users, you should be letting a
28 desktop tool handle the mounting anyway.
29
30
31 --
32 Neil Bothwick
33
34 We all know what comes after 'X', said Tom, wisely.

Attachments

File name MIME type
signature.asc application/pgp-signature