Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Newbie needs help with cdrom

If none of the specific sub-forums seem right for your thread, ask here.
Post Reply
Message
Author
jozmak
Posts: 52
Joined: 2005-06-17 02:33

Newbie needs help with cdrom

#1 Post by jozmak »

Hi,

I installed sarge a few weeks ago and it runs great, except a few minor glitches. The most annoying among them is that I cannot unmount or eject cds from the cd drive. When I try to unmount the cd it gives me the following error message.

[mntent]: warning: no final newline at the end of /etc/fstab
unmount: /media/cdrom0: device is busy
unmount: /media/cdrom0: device is busy
Please check that the disk is entered correctly.

I have exactly the same problem with floppies.
I am running kde desktop.

Could anyone suggest me a solution to this problem?

Thanks a lot
jozmak

User avatar
sensovision
Posts: 113
Joined: 2004-11-15 11:38
Location: Ukraine
Contact:

#2 Post by sensovision »

Hi jozmak!
Generally this error: unmount: "/media/cdrom0: device is busy " mean that cdrom is beign used by some program, e.g. one of your terminals or filemanager or whatever could cause the problem, try to close all applications which you've used to access files(in terminal just make cd / to change directory you're currently viewing. After this is done try to umount once again, if you fail try this umount -l /media/cdrom0 or try to access it directly umount -l /dev/hdc
Hope this would help.
BTW you need to add one blank line to /etc/fstab to avoid error during (u)mount operations.
Denis

User avatar
jobezone
Posts: 214
Joined: 2005-06-12 07:20
Location: Portugal

#3 Post by jobezone »

sensovision wrote:Hi jozmak!
BTW you need to add one blank line to /etc/fstab to avoid error during (u)mount operations.
One blank line at the end of /etc/fstab . Just make it clearer.

jozmak
Posts: 52
Joined: 2005-06-17 02:33

#4 Post by jozmak »

Thanks for the suggestions.

I placed a blank line in the fstab file. Now, at least, the first error message disappeared. But the

unmount: /media/cdrom0: device is busy
unmount: /media/cdrom0: device is busy
Please check that the disk is entered correctly.

still remains.
I also closed all windows and tried unmounting and ejecting by right clicking on the cd icon but no luck still. On the other hand, the umount -l /dev/hdc command works. It unmounted the cd but I still cannot eject it. The only way I can eject the cd if I log out and login again. Then it works.

Regards,
jozmak

User avatar
sensovision
Posts: 113
Joined: 2004-11-15 11:38
Location: Ukraine
Contact:

#5 Post by sensovision »

hmm, not sure what exactly could cause this but I think that it's some program causing this, because when you log all programs which was opened by you is closed and therefore they no longer use cdrom...
can you try to mount and un-mount cdrom from console and see how it works? if you would be able to do both than the problem probably in some GUI program...
too bad I'm not using KDE(I prefer Gnome) so don't know exactly what could cause such problem.
Denis

jozmak
Posts: 52
Joined: 2005-06-17 02:33

#6 Post by jozmak »

Thanks sensovision,

I did what you said. From the command line the cd mounts and unmounts nicely; but when i right click on the icon, after unmounting the cd, to eject it, i get the following error message:

Eject /dev/hdc failed.

jozmak

User avatar
sensovision
Posts: 113
Joined: 2004-11-15 11:38
Location: Ukraine
Contact:

#7 Post by sensovision »

it seems that some program won't free cdrom after it's used it. You can try to discover what program is this by running this:
ps awx |grep /media/cdrom and see what programs are using specific directories. If this doesn't show anything you could try to disply all entries without filtering by ps awx.
Denis

jozmak
Posts: 52
Joined: 2005-06-17 02:33

#8 Post by jozmak »

I ran the command and this is what i got.

mak@debian:~$ ps awx |grep /media/cdrom
2771 pts/1 R+ 0:00 grep /media/cdrom
mak@debian:~$

User avatar
sensovision
Posts: 113
Joined: 2004-11-15 11:38
Location: Ukraine
Contact:

#9 Post by sensovision »

jozmak wrote:I ran the command and this is what i got.

mak@debian:~$ ps awx |grep /media/cdrom
2771 pts/1 R+ 0:00 grep /media/cdrom
mak@debian:~$
and in the same time KDE doesn't let you to eject CDRom? as right now it's only shows that you execute command and noone seems to use your CDRom drive.
Denis

jozmak
Posts: 52
Joined: 2005-06-17 02:33

#10 Post by jozmak »

Hi sensovision,

Thanks a lot for helping me with the cd ejection problem. But in the mean time, I've found the solution. Googling around all day to day, I came across a posting on the mepis site where the solution was given. I paste it here so that others can benefit from it.

“There is a bug in KDE that prevents ejecting a disc from a CD-ROM or DVD as a user. This appears to be related to a KDE process, namely, kio_audiocd. It affects only those drives connected to system sound with an audio cable. There are a couple of workarounds, however. As root, check setuid in the permissions of /usr/bin/eject. If you don't want to use setuid, you simply can kill the errant process, either with Ksystemguard or with a script like this:

#! /bin/bash
killall kio_audiocd
eject /dev/hdc (or /dev/hdd as appropriate)

Save as xcd.sh or xdvd.sh in /usr/bin and give it the proper user permissions with chmod 755. I like this script; set up an icon to run it, use a red X from the actions list, and you can eject a disc with one mouse action instead of three.”

And this works great.

The Debian community is the best.

Regards,
jozmak

User avatar
sensovision
Posts: 113
Joined: 2004-11-15 11:38
Location: Ukraine
Contact:

#11 Post by sensovision »

glad you've find out solution :) And I'm sure that people who use KDE and have this bug would appreciate you.
Denis

Guest

Re: Newbie needs help with cdrom

#12 Post by Guest »

jozmak wrote:Hi,

I installed sarge a few weeks ago and it runs great, except a few minor glitches. The most annoying among them is that I cannot unmount or eject cds from the cd drive. When I try to unmount the cd it gives me the following error message.

[mntent]: warning: no final newline at the end of /etc/fstab
unmount: /media/cdrom0: device is busy
unmount: /media/cdrom0: device is busy
Please check that the disk is entered correctly.

I have exactly the same problem with floppies.
I am running kde desktop.

Could anyone suggest me a solution to this problem?

Thanks a lot
jozmak

Post Reply