Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] cant eject cdrom
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Wed Jan 31, 2007 7:17 pm    Post subject: [SOLVED] cant eject cdrom Reply with quote

Hi!

When I run eject cdrom I get this message.

Quote:
eject: tried to use `/dev/cdrom' as device name but it is no block device
eject: unable to find or open device for: `cdrom'

I have installed the system quite recently but from what I can recall the eject has worked before...

Any ideas?
_________________
Dig where you stand!


Last edited by Re-JeeP on Fri Feb 02, 2007 10:33 pm; edited 1 time in total
Back to top
View user's profile Send private message
tkhobbes
Guru
Guru


Joined: 12 Nov 2004
Posts: 367
Location: Switzerland

PostPosted: Wed Jan 31, 2007 8:07 pm    Post subject: Reply with quote

Hi

Where does /dev/cdrom point to?

so long
thomas
_________________
My systems and some screenshots: http://www.hobbes.ch/techie/
My Gentoo client installation page: http://www.hobbes.ch/techie/gentoo-client/
My Gentoo Server installation: http://www.hobbes.ch/category/server
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Wed Jan 31, 2007 8:21 pm    Post subject: Reply with quote

tkhobbes wrote:
Hi

Where does /dev/cdrom point to?

so long
thomas

The weird thing is that it doesn't exist... :?
_________________
Dig where you stand!
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Wed Jan 31, 2007 9:29 pm    Post subject: Reply with quote

Hence the error message... :D From the eject manpage, it says that it will default to /dev/cdrom unless you specify the correct device or mount point. So either create a /dev/cdrom symlink or specify the correct device or mountpoint when you run eject.
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Wed Jan 31, 2007 9:40 pm    Post subject: Reply with quote

yabbadabbadont wrote:
Hence the error message... :D From the eject manpage, it says that it will default to /dev/cdrom unless you specify the correct device or mount point. So either create a /dev/cdrom symlink or specify the correct device or mountpoint when you run eject.

Shoulndt the cdrom be in /dev if there is support for it in the kernel?
How would you create a symlink? from / to? I have never done that before.

In the manual it also said that I should be able to eject with the mount point as the argument. But I get the same message there.
_________________
Dig where you stand!
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Wed Jan 31, 2007 10:03 pm    Post subject: Reply with quote

Post the contents of your /etc/fstab file.
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Thu Feb 01, 2007 6:33 pm    Post subject: Reply with quote

yabbadabbadont wrote:
Post the contents of your /etc/fstab file.

Here is it!
Quote:
/dev/cdrom /mnt/cdrom auto defaults,user 0 0


Edit*
I actually solved it. ln -sf /dev/hdb /dev/cdrom did the job. But how can I make that to be permanent? Should I change in /etc/fstab to
Quote:
/dev/hdb /mnt/cdrom auto defaults,user 0 0

_________________
Dig where you stand!
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Fri Feb 02, 2007 1:48 am    Post subject: Reply with quote

Re-JeeP wrote:
I actually solved it. ln -sf /dev/hdb /dev/cdrom did the job. But how can I make that to be permanent? Should I change in /etc/fstab to
Quote:
/dev/hdb /mnt/cdrom auto defaults,user 0 0

Udev should have created the link automatically for you... You might want to start researching udev cdrom issues.

I always change my fstab file so that the real device is listed for my cdrw and dvdrw drives. That way it doesn't matter if udev doesn't create the links properly. So I would say yes to your suggestion.
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Fri Feb 02, 2007 2:51 pm    Post subject: Reply with quote

yabbadabbadont wrote:
Re-JeeP wrote:
I actually solved it. ln -sf /dev/hdb /dev/cdrom did the job. But how can I make that to be permanent? Should I change in /etc/fstab to
Quote:
/dev/hdb /mnt/cdrom auto defaults,user 0 0

Udev should have created the link automatically for you... You might want to start researching udev cdrom issues.

I always change my fstab file so that the real device is listed for my cdrw and dvdrw drives. That way it doesn't matter if udev doesn't create the links properly. So I would say yes to your suggestion.

I actually did get a lot of these messages when staring the computer. I think a as you said that I need to start researching udev issues.
Quote:
udevd-event[3346]: run_program: exec of program /sbin/udev_run_devd failed


Changing in /etc/fstab didnt help.
_________________
Dig where you stand!
Back to top
View user's profile Send private message
count_zero
Guru
Guru


Joined: 17 May 2004
Posts: 460
Location: Little Rock, Arkansas, USA

PostPosted: Fri Feb 02, 2007 2:59 pm    Post subject: Reply with quote

add this to your /etc/udev/rules.d/10-local.rules file. (and restart udev)
Code:
KERNEL=="hdb", SYMLINK="cdrom"


Check out this nice tutorial on udev: http://www.reactivated.net/writing_udev_rules.html
_________________
"We must all hang together, or assuredly we shall all hang separately."
-Ben Franklin
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Fri Feb 02, 2007 6:22 pm    Post subject: Reply with quote

count_zero wrote:
add this to your /etc/udev/rules.d/10-local.rules file. (and restart udev)
Code:
KERNEL=="hdb", SYMLINK="cdrom"


Check out this nice tutorial on udev: http://www.reactivated.net/writing_udev_rules.html

Thanks. I will check that tutorial.

When I entered that folder I saw two udev-files.
Quote:
._cfg0000_50-udev.rules
05-udev-early.rules

Could the problem be bacause I havent updated my config file?
If so, can I delete 05-udev-early.rules and rename ._cfg0000_50-udev.rules to 05-udev-early.rules?
_________________
Dig where you stand!
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Fri Feb 02, 2007 9:11 pm    Post subject: Reply with quote

Always update your config files after package upgrades! As the various system ebuilds will warn you, your system is not guaranteed to work if you don't. Use either etc-update or dispatch-conf to update your config files.

You probably should re-emerge udev and maybe even baselayout.
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Fri Feb 02, 2007 9:32 pm    Post subject: Reply with quote

yabbadabbadont wrote:
Always update your config files after package upgrades! As the various system ebuilds will warn you, your system is not guaranteed to work if you don't. Use either etc-update or dispatch-conf to update your config files.

You probably should re-emerge udev and maybe even baselayout.

I have read about etc-update but havent had time to install it yet. Sounds like its about time to make time for it... :)

When you say re-emerge, do you mean just emerge it againl like this emerge baselayout udev or should I unmerge them first?
_________________
Dig where you stand!
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Fri Feb 02, 2007 10:16 pm    Post subject: Reply with quote

etc-update is installed with portage, so you already have it. :D

Yes, when I said to re-emerge them, it just means to emerge them again. There isn't any need to unmerge them first, and in this case it would be very dangerous to do so. After thinking about it some more, I think you probably only need to emerge udev again. It's always best to start out with the smallest number of changes you can, and then add more if needed.

You might want to read through the portage documentation when you get a chance too.

http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=1
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
Re-JeeP
Apprentice
Apprentice


Joined: 10 Oct 2006
Posts: 294
Location: Sweden

PostPosted: Fri Feb 02, 2007 10:32 pm    Post subject: Reply with quote

yabbadabbadont wrote:
etc-update is installed with portage, so you already have it. :D

Good to know... :D

yabbadabbadont wrote:
Yes, when I said to re-emerge them, it just means to emerge them again. There isn't any need to unmerge them first, and in this case it would be very dangerous to do so. After thinking about it some more, I think you probably only need to emerge udev again. It's always best to start out with the smallest number of changes you can, and then add more if needed.

emerge udev did a very nice job! :P

yabbadabbadont wrote:
You might want to read through the portage documentation when you get a chance too.

http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=1

I read that part when installing the system. Might be time to read it again...

Quote:
Please add SOLVED to the subject of your original post when you feel that your problem is resolved.

Done... Thanks very much for the help! :D
_________________
Dig where you stand!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo 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