Technology Questions

Go Back   Technology Questions > Software Questions > Operating System Questions > Linux

Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old 09-26-2007, 03:50 AM
heavytull
Newsgroup Contributor
 
Posts: n/a
users to use mount

is there a way for users to use mount.
for instance to mount an iso image in their home directory to a directory in
their home one.
i'm using slackware and it says only root can do that

--
heavytull
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

 
Old 09-26-2007, 03:50 AM
  #2 (permalink)  
Old 09-26-2007, 05:10 AM
Lew Pitcher
Newsgroup Contributor
 
Posts: n/a
Re: users to use mount

On Sep 26, 6:28 am, heavytull <heavyt...********.com> wrote:
> is there a way for users to use mount.
> for instance to mount an iso image in their home directory to a directory in
> their home one.
> i'm using slackware and it says only root can do that


If you designate the mount as "user" or "users" in your /etc/fstab,
then an unpriviledged user can issue the mount for the mountpoint. See
mount(8) and fstab(5). The mount(8) manpage contains the following
example...

Normally, only the superuser can mount file systems.
However,
when fstab contains the user option on a line, anybody can
mount the
corresponding system.

Thus, given a line
/dev/cdrom /cd iso9660 ro,user,noauto,unhide
any user can mount the iso9660 file system found on his CDROM
using the
command
mount /dev/cdrom
or
mount /cd

HTH
--
Lew


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #3 (permalink)  
Old 09-26-2007, 05:40 AM
heavytull
Newsgroup Contributor
 
Posts: n/a
Re: users to use mount

Lew Pitcher wrote:

> On Sep 26, 6:28 am, heavytull <heavyt...********.com> wrote:
>> is there a way for users to use mount.
>> for instance to mount an iso image in their home directory to a directory in
>> their home one.
>> i'm using slackware and it says only root can do that

>
> If you designate the mount as "user" or "users" in your /etc/fstab,
> then an unpriviledged user can issue the mount for the mountpoint. See
> mount(8) and fstab(5). The mount(8) manpage contains the following
> example...

ok let's assume i don't want to make an entry for each iso file that users
download and want to mount -oloop
more over i don't want to be aware of the tonnes of iso files they use.

>
> Normally, only the superuser can mount file systems.
> However,
> when fstab contains the user option on a line, anybody can
> mount the
> corresponding system.
>
> Thus, given a line
> /dev/cdrom /cd iso9660 ro,user,noauto,unhide
> any user can mount the iso9660 file system found on his CDROM
> using the
> command
> mount /dev/cdrom
> or
> mount /cd
>
> HTH
> --
> Lew


--
heavytull
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #4 (permalink)  
Old 09-26-2007, 06:40 AM
birre
Newsgroup Contributor
 
Posts: n/a
Re: users to use mount

On 2007-09-26 14:30, heavytull wrote:
> Lew Pitcher wrote:


> ok let's assume i don't want to make an entry for each iso file that users
> download and want to mount -oloop
> more over i don't want to be aware of the tonnes of iso files they use.



It may be possible to hard link the iso file to a known name first.
(for example cd.iso)

It`s also possible that /etc/auto.misc can be used, but I will not even try :-)

user1 -fstype=iso9660,ro,nosuid,loop /home/&/cd.iso
user2 -fstype=iso9660,ro,nosuid,loop /home/&/cd.iso
(or maybe :/home/&/image...)

And enable auto.misc in /etc/auto.master, and start autofs

If it works as I hope, then user1 just have to do
cd /misc/user1 and /home/user1/cd.iso will be mounted there if it exist.
(and unmounted short after it's unused )

A symlink /home/user1/something kan be make to /misc/user1

I have never tested auto.misc, so it's just another suggestion if you really
must have this function.

One can also make a /usr/local/bin script that do the job, and add it to
/etc/sudoers for a group of users.
Example sudo /usr/local/bin/isomount name.iso

/bb
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #5 (permalink)  
Old 09-26-2007, 09:50 AM
Mike
Newsgroup Contributor
 
Posts: n/a
Re: users to use mount

Responding to heavytull...
> is there a way for users to use mount.
> for instance to mount an iso image in their home directory to a directory in
> their home one.
> i'm using slackware and it says only root can do that
>


'man mount' and 'man sudoers' could be interesting to peruse.

IOW, a specific command to mount X_resource to Y_mountpoint could be
included in /etc/sudoers so that a user could mount something
somewhere specifically. The user's password may or may not be
required, as decided by sysadmin (you?), meaning a user would never
need to know the root password to do such things. Kinda neat when you
have multiple users you can't trust that far. ;)

Probably better ways that this though.

--
Yellow Submarine?
Nah. Its a TeaPot!
www.tinyurl.com/382gmp
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Guest users can no longer mount a USB drive after IE7 is installed. Requires Admin privileges. Huh? Thee Chicago Wolf Windows XP 2 08-31-2007 08:20 PM
Mac Volume won't mount on G4: Need Help Sean C Apple Macintosh Hardware 2 02-06-2007 04:24 PM
Local users become domain users and their data... Geir Holmavatn Windows XP 0 01-29-2007 06:30 AM
Domain users disappear from local computer users Daryl Windows XP 0 01-04-2007 04:22 AM
Domain users disappear from local computer users Daryl Windows XP 0 01-04-2007 04:22 AM


New To Technology Questions? Do You Need Help with Your Computer or Device? Do You Need Help with this site?

All times are GMT -8. The time now is 01:18 PM.


2003 - 2009 All Rights Reserved. Technology Questions

Search Engine Friendly URLs by vBSEO 3.3.0