Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] [gnome] can't mount CDs
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Aquous
l33t
l33t


Joined: 08 Jan 2011
Posts: 700

PostPosted: Tue Feb 28, 2012 12:56 pm    Post subject: [solved] [gnome] can't mount CDs Reply with quote

I can't mount any CD's. Nautilus reports:
Quote:
Error mounting: mount: block device /dev/sr1 is write-protected, mounting read-only
mount: wrong fs type, bad option, bad superblock on /dev/sr1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so

dmesg|tail only contains
Code:
[18482.714085] ISO 9660 Extensions: Microsoft Joliet Level 3

and mounting the drive manually works fine.

So what's the problem?


Last edited by Aquous on Mon Mar 05, 2012 8:11 am; edited 1 time in total
Back to top
View user's profile Send private message
bigbangnet
Apprentice
Apprentice


Joined: 11 Jun 2007
Posts: 174

PostPosted: Tue Feb 28, 2012 1:25 pm    Post subject: Reply with quote

Give us the output of your /etc/fstab. It's possible there could be a problem in there.
_________________
I'm a noob, be gentle with me. TEACH ME
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6194

PostPosted: Tue Feb 28, 2012 4:55 pm    Post subject: Reply with quote

:roll: There shouldn't be any fstab entry.
But lets try something different: see what effect 'udisks --mount' has.
Back to top
View user's profile Send private message
bigbangnet
Apprentice
Apprentice


Joined: 11 Jun 2007
Posts: 174

PostPosted: Wed Feb 29, 2012 4:56 am    Post subject: Reply with quote

should't be eh ? ok but I wonder why on that cause I do have a "cdrom" in my fstab and it's working great. But I'm not here to cut throught he ops problems really.

Anyways, beside mounting that cd or cd's, what are you trying to do ? and any detailed info on those cd's ?
_________________
I'm a noob, be gentle with me. TEACH ME
Back to top
View user's profile Send private message
WvR
Apprentice
Apprentice


Joined: 03 Mar 2011
Posts: 189
Location: Tsuruga, Japan

PostPosted: Wed Feb 29, 2012 11:39 pm    Post subject: Reply with quote

Make sure you are in the group "cdrom". As root, check the file /etc/group. Your user name should have a line like

Code:

wheel::10:root,rooijen
floppy::11:root
man::15:man
cdrom::19:rooijen


Note that last line. Use

Code:

man usermod


to find out how to add your user to the group "cdrom".
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6194

PostPosted: Wed Feb 29, 2012 11:57 pm    Post subject: Reply with quote

WvR wrote:
...some silly stuff...

...and the guesses keep getting better...:sigh:, who's next ?
Back to top
View user's profile Send private message
WvR
Apprentice
Apprentice


Joined: 03 Mar 2011
Posts: 189
Location: Tsuruga, Japan

PostPosted: Thu Mar 01, 2012 11:38 pm    Post subject: Reply with quote

Well, VoidMage, you may have more posts than me but that does not make my advice silly. I have actually experienced this problem in an old version of XFCE (Thunar) and at that time, the solution was to add the user to the "cdrom" group. If you think my post is silly, then explain why it is silly - and we will all learn something. Your posting says more about your own view of yourself than about your willingness to learn or teach others - which is the goal of this foum.

OK, I see that the OP has a problem in Nautilus, but the CD can be mounted by hand. Interesting.

1. Is CDROM support in the kernel, as well as the necessary file system support (assume yes, otherwise a manual mount would not work either)

2. Do a revdep-rebuild or emerge --sync && emerge -auvDN world. Maybe a helper program for Nautilus has changed?

3. USE flags for Nautilus show nothing about CDs so that should not be a problem

4. If at all possible, to try to figure out which command Nautilus uses to mount the CD - then the next step is to see how you can change that command :) .
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6194

PostPosted: Fri Mar 02, 2012 12:26 am    Post subject: Reply with quote

As the original post is about Nautilus, the very first thing to test are consolekit/dbus/udisks problems.
As such groups don't matter at all.

Also, it was already said that manual mounting works.
If it's a kernel problem, groups likely still won't matter.
Back to top
View user's profile Send private message
WvR
Apprentice
Apprentice


Joined: 03 Mar 2011
Posts: 189
Location: Tsuruga, Japan

PostPosted: Fri Mar 02, 2012 12:49 am    Post subject: Reply with quote

VoidMage, I admit I misread the OP. I didn't realize that the TS can mount his CDs manually. Indeed, this problem is related to nautilus and not to groups - probably.

I have had some weird encounters with CDROMs over the years: automounting that disappears after updating some seemingly unrelated package, or the situation where some applications have access to the CDROM but others not (I remember GRIP and old versions of Sound Juicer to be particularly troublesome - but we are talking about 8 to 9 years ago). In Thunar I had a case where the CD icon would appear, but only "root" could actually mount the CDROM. So my advice was really: first things first. Double check all settings that could be related to failure of mounting a CDROM.
Back to top
View user's profile Send private message
Aquous
l33t
l33t


Joined: 08 Jan 2011
Posts: 700

PostPosted: Fri Mar 02, 2012 4:09 pm    Post subject: Reply with quote

My fstab is fine, no cd-related entry at all.
Code:
# <fs>      <mountpoint>   <type>      <opts>            <dump/pass>
/dev/sda2   /media/Windows   ntfs-3g      noatime,hide_hid_files,windows_names   0 0
/dev/sda3   /boot      vfat      noatime            0 0
/dev/sda5   /      ext4      noatime            1 1
/dev/sda6   /usr/portage   reiserfs   noatime,notail         0 0
/dev/sda7   /media/Data   ntfs-3g      noatime,hide_hid_files,windows_names   0 0
devpts      /dev/pts   devpts      gid=5,mode=0620         0 0
shm      /dev/shm   tmpfs      nodev,nosuid,noexec      0 0
#none      /selinux   selinuxfs   noatime            0 0
#udev   /dev        tmpfs        rw,rootcontext=system_u:object_r:device_t,seclabel,nosuid,relatime,size=10m,mode=755  0 0

The problem occurs with any CD or DVD.
I am in the cdrom group.

The necessary support is in the kernel. Most of it is built-in, except for isofs, which is a module. The module is correctly loaded automatically when I put in the CD.

udisks --mount says:
Code:
Mount failed: Error mounting: mount: block device /dev/sr1 is write-protected, mounting read-only
mount: wrong fs type, bad option, bad superblock on /dev/sr1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so


Perhaps this is a bug in udev, that causes mount's informative message of the device being mounted read-only to be interpreted as an error?
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6194

PostPosted: Fri Mar 02, 2012 6:16 pm    Post subject: Reply with quote

Well, at least we pushed it one step down - still not very helpful.
Is there anything interesting showing in your syslog (which should be a bit more verbose than dmesg) ?
Could you check 'getfacl /dev/sr1' ?
You could also see if something interesting gets printed in terminal with 'udisks --monitor (--monitor-detail ?)'.
What we're trying to find out here is what command gets sent for mounting.
Back to top
View user's profile Send private message
Aquous
l33t
l33t


Joined: 08 Jan 2011
Posts: 700

PostPosted: Fri Mar 02, 2012 7:01 pm    Post subject: Reply with quote

The system log shows nothing else than that one dmesg line.

Code:
# getfacl /dev/sr1
getfacl: Removing leading '/' from absolute path names
# file: dev/sr1
# owner: root
# group: cdrom
user::rw-
user:cesko:rw-
group::rw-
mask::rw-
other::---


Code:
$ udisks --monitor-detail
Monitoring activity from the disks daemon. Press Ctrl+C to cancel.
job-changed: /org/freedesktop/UDisks/devices/sr1
  job underway:                FilesystemMount, initiated by uid 1000
job-changed: /org/freedesktop/UDisks/devices/sr1
  job underway:                no


Replacing /bin/mount with a program that prints its arguments to a file and then runs the real mount command yields the following command line being used:
Code:
/bin/mount -t iso9660 -o uhelper=udisks,nodev,nosuid,uid=1000,gid=1000,iocharset=utf8,mode=0400,dmode=0500 /dev/sr1 /media/LABEL
with 'LABEL' being the disc label of the CD.


EDIT:
There we go:
Code:
# zcat /proc/config.gz|grep -i utf8
CONFIG_NLS_DEFAULT="utf8"
# CONFIG_NLS_UTF8 is not set

One sec, let me build that module...

Edit: Yup, that fixed it.
Thank you for the ideas, guys :D
Back to top
View user's profile Send private message
WvR
Apprentice
Apprentice


Joined: 03 Mar 2011
Posts: 189
Location: Tsuruga, Japan

PostPosted: Sun Mar 04, 2012 11:43 pm    Post subject: Reply with quote

Please mark topic as [solved]
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum