Mailing List
Home
Forum Home
Linux - General Red Hat Linux discussion list
Enterprise Linux 3 - Discussion of Red Hat Enterprise Linux 3 (Taroon)
Installation - Getting started with Red Hat Linux
Red Hat Linux 9 - Discussion of Red Hat Linux 9 (Shrike)
Red Hat Linux 7.3 - Discussion of Red Hat Linux 7.3 (Valhalla)
Red Hat Linux 7.2 - Discussion of Red Hat Linux 7.2 (Enigma)
Apache Web Server
Oracle database, Microsoft SQL server ...
Subjects
application/x mplayer2 plugin
RPM error: db4 error(16) from dbenv >remove: Device or resource
   busy
Command stream end of file while reading
X Windows problem (xauth)
Upgrading openoffice 1 1 rpm
FTP: connection refused
FTP: connection refused
mount: /dev/cdrom: is not a valid block device
Dell Precision 650, RedHat 9, no sound
how to trace the cause resulting in the crash of bind server
Virus on the list
UNINSTALL RPM MYSQL
usb pen drives: mounting as a user
broadcom network interface
make mrproper
sendmail configuration on redhat
Couldn 't open PID file /var/run/named/named pid Permission denied
Promise 378 controller
kernel 2 6 and /dev/sound/mixer not found
Problem using up2date
mrtg step by step howto/configuration for a newbie?
Compiling and Installing Kernel 2 6
Can 't locate module ppp0, can 't locate module ppp compress 21
HOW I CAN MAKE BOOTABLE FLOPPY DISKET
Lotus Notes under Wine
/etc/security/limits conf question
Intel E/1000 driver
Command stream end of file while reading
rpm database corrupt
qla2300 modules
 
Search:  
Power your search with and, or, +, -, or "some phrase" operators.
USB utilities

USB utilities

2005-03-23       - By Stephen Gardner

 Back
Reply:     1     2     3     4     5     6     7     8     9     10  

On Wed, 23 Mar 2005, Akop Pogosian wrote:

> I am often being asked is whether there exist utilities that allow
> users to mount USB storage devices without superuser's intervention.
> Does such thing exist on RHEL 3? What about RHEL 4?

Akop,
  This is certainly very easy under RHEL4 which uses a combination
of the  hald  process to detect the insertion of the USB storage device
and  fstab-sync  to create the appropriate line in fstab to enable the
device to be mounted by the user on console. RHEL4 has a /media directory
into which user mountable CDROM, USB storage etc  mount points are
created.

  Under RHEL3 there are a couple of options I can think of. Firstly
a crude option is to attempt to minic the RHEL4 /media directory
with an entry in /etc/fstab something similar to

/dev/sda   /media/usbdevice   auto   user,noauto,unhide,sync   0 0
[ change /dev/sda to suit your system, it's where my USB device ends up ]

This doesn't always work as auto-detecting the filesystem can be
problematic. The "user" option allows a user to mount and unmount the
device. You can have problems with a user forgetting to unmount the device
and simply removing the storage device. Changing that option to "users"
will allow any user (not just the person who mounted it originally) to
mount and unmount the device (NOTE: if you allow remote logins this can
allow a remote user to unmount a local users filesystem). The "user"(s)
option sets some sensible security defaults, see mount(8) man pages for
more details.

Secondly there's the automounter. A quick-and-dirty guide would be to have
a line in /etc/auto.master like
/media        /etc/auto.media  --timeout=120

Then create a file called /etc/auto.media containing
usbdevice        -fstype=auto,nosuid,nodev,sync        :/dev/sda
[ change /dev/sda to suit your system, it's where my USB device ends up ]

Then when a user goes into the /media/usbdevice it'll get mounted
automatically. Plus after 2 minutes of inactivity the device will be
unmounted. autofs(5) is worth reading.

One note of warning about all of the above is that if you plan to perform
an upgrade to RHEL4 from RHEL3 (rather than a clean install) and use some
of the above suggestions they will cause conflicts with the internal RHEL4
functions. If that's a possibility avoid using the /media and choose
another location.

Regards,
  Stephen


--
Taroon-list mailing list
Taroon-list@(protected)
http://www.redhat.com/mailman/listinfo/taroon-list

Earn $52 per hosting referral at Lunarpages.