Summary: Allowning non-privledged users to mount CDROM

From: Ron Bramblett <bramblett_at_fullerbrush.com>
Date: Wed, 21 Jun 2000 14:00:46 -0500

My original question:
    This may be a very simple question but I have looked and don't know
how
> it works yet.
> I have a CD-ROM on my Alpha 2100 server. I am running Tru-64 4.0D.
> HOw do I allow a non-root user to have access to the cd-rom without
> using root password??
> Is there a way to make the command easier to do??
>
> This is the command that I am having the user run now but I don't know

> what is going on yet.
> mount -r -t cdfs /dev/rz4c /cdrom
>
> I get the following messages
> /dev/rz4c on /cdrom: Not owner
>
> Can I simplify the command to something like this
> mount -r -t cdfs /dev/cdrom /cdrom
>
> Thanks in advance.


I had many responses, there must have been 10 or so responses. The
general answer was to get sudo.
I downloaded it from : http://www.courtesan.com/sudo/sudo.html
After installing it I just followed the examples in sudoers.html adding
just references to the cdrom only and to the operators of the system. I
then created 2 batch files, 1 to mount the cdrom and the 2nd to umount
it.
I typed the whole command line into each batch file.
        Example of mount file called cd-rom
    sudo /sbin/mount -r - t cdfs -o nosuid/,nodev /dev/rz4c /cdrom
        (making sure that this line exactly matches the one in the
/etc/sudoers file, then made cd-rom executible by chmod u+x cd-rom.
Now when the operators sign in to their account they can simply type
this to mount the CDROM:
    cd-rom
to unmount it again they just type
    cd-romU

I did it. I got both of the items I requested help on accomplished. I
got it so that I can mount the cd-rom as a non-privaleged user and also
simplified it a bunch. Only the system or root has access to the files
necessary to get any other access.

I should have browsed the archives before asking such a simple time
wasting question. Sorry I will learn next time.

--
Ron Bramblett
Systems Administrator
The Fuller Brush Company
Received on Wed Jun 21 2000 - 19:00:34 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:40 NZDT