LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Mandriva (https://www.linuxquestions.org/questions/mandriva-30/)
-   -   Access to DVD-RW (UDF) (https://www.linuxquestions.org/questions/mandriva-30/access-to-dvd-rw-udf-356707/)

Telman 08-24-2005 10:20 PM

Access to DVD-RW (UDF)
 
I'm using Mandriva 9.1, and i try to open a DVD-RW recorded with my Samsung DVD-R120 recorder.

I can access this data as root but not as current user.

Just before trying to access the DVD-RW disc, i have the following situation, seen as root user:
drwxr-xr-x 2 root root 4096 fév 27 13:44 cdrom/
drwxrwxrwx 0 root root 0 aoû 24 23:00 cdrom2/
drwxrwxrwx 0 root root 0 aoû 24 20:32 floppy/
[root@Benoit etc]# ls -l /mnt/cdrom2
total 2
drwxrwxrwx 2 4294967295 4294967295 240 jui 28 05:00 DVD_RTAV/

When i try to access the disc as current user, i got the following message:
[user@Linux user]$ ls -l /mnt/cdrom2
ls: /mnt/cdrom2/DVD_RTAV: Permission denied
total 0

And after that, i have the following parameters for the same directory. Note this time, the cdrom2 directory isn't executable for everyone.
[root@Benoit etc]# ls -l /mnt/
total 6
drwxr-xr-x 2 root root 4096 fév 27 13:44 cdrom/
drw-rw-rw- 3 4294967295 4294967295 252 jui 28 04:19 cdrom2/
drwxrwxrwx 0 root root 0 aoû 24 20:32 floppy/

Note: user is member a root group.

Why user don't have access to this directory? Any clue!

Thanks

Ben

minrich 08-25-2005 10:50 AM

Could you post what you have in /etc/fstab please.

Telman 08-25-2005 09:39 PM

In my previous message, i said mandrake 9.1, it's not right. It's 10.1 up-to-date.

Here is some tries tonight:
----------------------
Try #1
Just after rebooting Linux.
I try to enter /mnt/cdrom2
As user: I got a popup indicating "Impossible to enter directory /mnt/cdrom2" (it's my translation of french message)
As root: Simply nothing is displayed when entering /mnt/cdrom2

I note that supermount doesn't have mounted the drive automatically. As root, i do: mount /mnt/cdrom2
Now, as root: I'm able to access the contents.
Again, as user: I got "permission denied"
Unmounting manually the drive
The fstab is the same as try #2 below.
---------------------
Try #2
Now, i remove the DVD-RW disc and replace it. It seems supermount, again, doesn't have automatically mounted /mnt/cdrom2

The specific line in fstab is:
none /mnt/cdrom2 supermount dev=/dev/hdc,fs=udf:iso9660,--,exec,umask=0,sync,noauto 0 0
And in mtab:
There is nothing about /mnt/cdrom2. (The drive isn't mounted)

--------------------
Try #3
Change the line in fstab for, i added the "user" option:
none /mnt/cdrom2 supermount dev=/dev/hdc,fs=udf:iso9660,--,user,exec,umask=0,sync,noauto 0 0
I just added user option.

Double click the drive icon, and got the message "Impossible to enter directory /mnt/cdrom2". I looked in mtab, the drive isn't mounted.
As root, i mounted the drive and got this line in mtab:"none /mnt/cdrom2 supermount rw,nosuid,nodev,sync,dev=/dev/hdc,fs=udf:iso9660,--,umask=0 0 0"

As user, i double-click the icon and got the message "access denied"
As root: i can see the content

Unmounting the drive

-----------------------
Try #4 (i try to be specific about the user in fstab)

none /mnt/cdrom2 supermount dev=/dev/hdc,fs=udf:iso9660,--,user=bdube,exec,umask=0,sync,noauto 0 0

mounting the drive as root, i got this line in mtab: none /mnt/cdrom2 supermount rw,sync,dev=/dev/hdc,fs=udf:iso9660,--,user=bdube,umask=0 0 0

As user bdube: i'm able to double-click the cdrom2 disck icon, but nothing appear.
As root: same thing as user. I can open the directory and nothing appear.

--------------------------
Try #5 (instead of using "user" option, i will try "users" option)
fstab is now: none /mnt/cdrom2 supermount dev=/dev/hdc,fs=udf:iso9660,--,users,exec,umask=0,sync,noauto 0 0

mounting /mnt/cdrom2
In mtab:
none /mnt/cdrom2 supermount rw,nosuid,nodev,sync,users,dev=/dev/hdc,fs=udf:iso9660,--,umask=0 0 0

as user: i got "access denied" when trying to double-click cdrom2 icon.
as root (in konsole): in can open and see the contents.

I don't know what to try now.

Telman 08-25-2005 10:37 PM

How to bypass the directory security
 
Just after mounting the drive, i have the following security setted for cdrom2:
d--------- 3 4294967295 4294967295 252 jui 28 04:19 cdrom2/

In fstab, i have tried nosuid, but it doesn't make any apparent effects.

minrich 08-26-2005 06:05 AM

Okay - but I am not sure about some of the entries that you have in /etc/fstab, my line reads:

/dev/dvdram /media/dvdram subfs noauto,fs=cdfs,ro,procuid,nosuid,nodev,exec,iocharset=utf8 0 0

since I am using SuSE 9.3 Pro, with a x86_64 arch on a 2.6.11.4-21-8 kernel, and it has the /media directory (and udev rather than devfs) I think that you should substitute /mnt/cdrom2 where I have /media/dvdram.

Another point: you should check the content of your /etc/mtab file. NB: it will not show a CD drive until it has media in it (or at least it doesn't on my machine). When you have entered a CD into your drive you should check /etc/mtab to see if anything is mounted.


Another point: According to my understanding of the 'options' in fstab from reading man fstab and man mount(8) there is a difference between 'users' and 'user', adding 'user' allows anyone to mount the device but only root can mount the drive otherwise. More precisely:

user --- Allow an ordinary user to mount the file system. The name of the mounting user is written to mtab so that he can unmount the file system again. This option implies 'noexec','nosuid', and 'nodev' (unless overridden by subsequent options, as in the option line 'user,exec,dev,suid')

users --- Allow every user to mount and unmount the file system. This option implies 'noexec','nosuid', and 'nodev' (unless overridden by subsequent options, as in the option line 'users,exec,dev,suid').

Hope this helps

Telman 08-26-2005 10:13 PM

With the following line in fstab:
none /mnt/cdrom2 supermount dev=/dev/hdc,fs=udf:iso9660,--,gid=bdube,uid=bdube,user,exec,suid,umask=777,sync 0 0

I got this privilege to access cdrom2.
d--------- 3 bdube bdube 252 jui 28 04:19 cdrom2/

As you can see, even if i'm the user & group, i can't access the cdrom2 directory. Only root user can.

Within fstab, how to force other privileges or ignore the one from the dvd?

If someone knows the trick to bypass this behavior, i will appreciate a lot. I'm working on this one since 5 to 6 days.

Thanks for your help.

Ben

minrich 08-27-2005 09:04 AM

When you have the cd in the drive do you get an icon on the desktop? If not, can you use a file manager on /mnt/cdrom2 to right click and get up the Properties - you should be able to change the Permissions to whatever you want (for the drive). I use kde and use the File Manager - Super User Mode and can change anything that I like.

HTH

Telman 08-27-2005 09:40 AM

Access rights to DVD-RW
 
Yes i got the icon on the desktop.

But even as root, it refuse to change the access rights. I try this with konqueror & through konsole.

In Konsole, to the command "chmod 660 /mnt/cdrom2", I got the message:
modification des permissions de `/mnt/cdrom2': Read-only file system

Is there any relation with UDF tools or service pktcdvd which I try to start, but he can't for whatever reason?

Ben

Telman 09-04-2005 08:57 AM

Updrading to Mandrive LE2005 (10.2)
 
This morning, i have upgraded from Mandriva 10.1 to 10.2. I always have the same behavior with DVD-RW access..

Here is the ls -l /mnt (cdrom is now the DVDWriter, since i have inverted the flat cable to make it primary instead of slave)

drw-r--r-- 3 4294967295 4294967295 252 jui 28 04:19 cdrom/
dr-xr-xr-x 1 root root 2048 nov 19 2001 cdrom2/
drwxrwxrwx 0 root root 0 sep 4 09:08 floppy/

As you can see, cdrom isn't accessible, no "x" nor for owner, group or others.

Is there someone else who have this problem and find the solution.

Regards,

Ben

minrich 09-04-2005 12:02 PM

Can I suggest the following thread: http://www.linuxquestions.org/questi...ght=supermount which seems to relate to your use of supermount, which appears to be a Mandrake/mandriva thing only.

Incidentally, having re-read your previous posts in this thread you seem to have lost one of the x's that originally appeared for cdrom.

Rather than starting the /etc/fstab line with 'none' which again appears to be a 'supermount' speciality, I would suggest that you mount /dev/cdrom /mnt/cdrom fs=udf:iso9660,--,gid=bdube,uid=bdube,user,exec,suid,umask=777,sync 0 0. It appears that your /dev/hdc is not pointing to your cdrom.

Finally, it should do no harm to add 'rw' in there somewhere, as you probably known this makes the device read/write.

Hope this helps

Telman 09-04-2005 02:00 PM

Thanks Minrich...

Unfortunately, Mandriva seems to use gnome volume manager in 10.2, instead of supermount. Then, i remove lines in FSTAB related to cd-rom, and leave Mandriva enter the line, through Control Center. Unfortunately, this doesn't solve the access problem i have.

But, i noted with that dmesg shows "Mounting volume Samsung UDF Volume". But as always, it's only accessible by root user. The Samsung UDF Volume is the one created by my Movie DVD Recorder - DVD-R120.

I don't know to try now, but i will search again.

Thanks for your time, I appreciate.

Ben

minrich 09-04-2005 07:42 PM

Since I don't use gdm, since suse defaults to kde, and I haven't tried Mandriva 10.2 (yet) I would suggest that you start a new thread - hopefully you will attract a new '0 replies' reader. Perhaps an appropriate title would be "Changing permissions on cdrom and dvd drives".

By the way congratulations on your excellent command of the English language - I only wish that I was as fluent in French!

All the best

Richard


All times are GMT -5. The time now is 12:26 AM.