From: Paul Furness Subject: Re: Non-root mount of a FS? Date: 28 Oct 2002 15:02:22 +0000 Sender: linux-admin-owner@vger.kernel.org Message-ID: <1035817342.2764.8.camel@zebra.vil.ite.mee.com> References: <1035812871.2016.14.camel@zebra.vil.ite.mee.com> <15805.18699.823029.39760@cerise.nosuchdomain.co.uk> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <15805.18699.823029.39760@cerise.nosuchdomain.co.uk> List-Id: Content-Type: text/plain; charset="us-ascii" To: linux-admin@vger.kernel.org Hurrah! That got it! Thanks, Glynn. Just in case anyone else is trying to get this to work, here's what I did: In order for users to mount devices, they need to have perms to the device file. The display manager knows who's just logged into the console, and therefore should have rights to change this permissions, and it is configured in /etc/security/console.perms (man console.perms helps here). Basically, the device you want to make available must have some appropriate entries in here, and then the ownership of the device files gets changed when you log in. To get USB Flash drive to work, the simplest way is to use an already existing entry in this config file - ie, create a link in /dev to the device which youre flash drive comes up as (sda1 or sdb1, probably) and call the link "flash" something (eg flash, flash1 or flash01). Then create a mount point for it under /mnt which is also called flash* (/mnt/flash or /mnt/flash1 and so on). Finally, create an entry in /etc/fstab which maps the device to the mount point. The easiest is to copy the cdrom or floppy entry, and make sure it doesn't have "ro" in the options. Then it works. Paul. On Mon, 2002-10-28 at 14:26, Glynn Clements wrote: > > Paul Furness wrote: > > > So it's a permission thing, right? This is where I get lost. "ls -l > > /dev/cdrom" shows that it's a pointer to /dev/scd0. "ls -l /dev/scd0 > > shows that the file is owned by me. If I log into the machine as someone > > else, the file is owned by them. > > However, /dev/sda1 is persistently owned by root. > > > > So something is changing the ownership of the device files to enable the > > user to mount those devices? > > > > What? > > AFAICT, the display manager (xdm, gdm, kdm, ...) is configured to use > the pam_console module, which sets the permissions of various devices > as specified by /etc/security/console.perms. > > -- > Glynn Clements > - > To unsubscribe from this list: send the line "unsubscribe linux-admin" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > -- Paul Furness Systems Manager Steepness is an illusion caused by flat things leaning over.