Normail user cannot write on /dev/sg0

Bug #6530 reported by effetto
6
Affects Status Importance Assigned to Milestone
udev (Ubuntu)
Medium
Scott James Remnant (Canonical)

Bug Description

I plugged in an external CD/DVD writer:

Vendor: TSSTcorp Model: CD/DVDW SH-W162C Rev: TS09

Ubuntu 5.10 recognized it quite well but trying to write or blank a cdr/dvdr the application (Gnomebaker 0.5.0) scream his pain:

Error trying to open /dev/sg0 exclusively (Permission denied)... retrying in 1 second.

Everything works well working with sudo (sudo gnomebaker). I suppose it's a problem how the permission are sets creating the new device.

ls -l /dev/sg0
crw-rw---- 1 root root 21, 0 2006-01-07 12:40 /dev/sg0

Revision history for this message
Daniel Holbach (dholbach) wrote :

Thanks for your bug report. Which 'groups' is your user in.

Revision history for this message
effetto (effetto-deactivatedaccount) wrote :

$ groups
hardskinone adm dialout cdrom floppy audio dip video plugdev lpadmin scanner admin

Revision history for this message
lyon (r-steiger) wrote :

I can confirm this bug in KUbuntu Breezy. The /dev/sg0 nod should be set to cdrom group, as other CD nodes usually are. K3b also had problems writing on such drive, unless i set the GID to 'cdrom'.

I guess this should be handled somewhere in /etc/udev/*.

Tested on notebook with SATA DVD-RW drive.

Revision history for this message
emile (espanjer) wrote :

I can confirm this bug also exist in ubuntu
dapper flight 6 with all (available) updates.

sudo cdrecord -scanbus gives following info;
scsibus1:
        1,0,0 100) '_NEC ' 'DVD+-RW ND-6650A' '102C' Removable CD-ROM
        1,1,0 101) *

cdrecord -scanbus WITHOUT sudo gives;
Error trying to open /dev/sg0 exclusively (Permission denied)... retrying in 1 second.
etc

ls -al /dev/sg0
crw-rw---- 1 root root 21, 0 2006-04-16 08:54 /dev/sg0

emile@dell:~$ groups
emile adm dialout cdrom floppy audio dip video plugdev lpadmin scanner admin

Revision history for this message
effetto (effetto-deactivatedaccount) wrote :

I upgraded to Dapper Drake this month and the bug stand still. My Dapper is update to this afternoon (15:00, Rome, GMT+2). The hardware is same of original report.

Revision history for this message
Matt Zimmerman (mdz) wrote :

Working fine here:

crw-rw---- 1 root cdrom 21, 0 2006-05-05 15:17 /dev/sg0

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

Please attach /var/log/udev from a dapper installation showing /dev/sg0 owned by root/root.

Thanks

Changed in udev:
status: Unconfirmed → Needs Info
Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

Note that it is likely that /dev/sg0 is *NOT* your CD-Writer drive, and this is a bug in cdrecord picking the wrong device (there are several open on it)

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

Without the requested information, we cannot debug this further.

This is almost certainly a duplicate of bug 23203, so will be treated as such

Revision history for this message
PabloRQ (pablo-romeroquinteros) wrote :

Scott, I don't think it's a duplicate of bug 23203, 'coz in that bug the problem is a conflict between an hd and a cd writer, 'n in this bug the problem is that the only way to record the cd is running the app as root.
Someone opens another bug ( Bug #69952) that i think is the same that this one.
The community has a patch for this issue, found in http://www.ubuntu-es.org/index.php?q=node/15837

sudo chmod a+x /usr/bin/cdrecord
sudo chown root:cdrom /usr/bin/cdrdao
sudo chown root:cdrom /usr/bin/X11/cdrdao
sudo chmod 4710 /usr/bin/cdrdao
sudo chmod 4710 /usr/bin/X11/cdrdao
sudo chown root:cdrom /usr/bin/cdrecord.mmap
sudo chown root:cdrom /usr/bin/X11/cdrecord.mmap
sudo chmod 4710 /usr/bin/cdrecord.mmap
sudo chmod 4710 /usr/bin/X11/cdrecord.mmap

Anyway, i think it could be a better user experience if this bug could by fixed and everything could work without headaches!

-----
parq!

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers