Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Playing audio CD

139 views
Skip to first unread message

Haines Brown

unread,
Jun 8, 2011, 5:32:05 PM6/8/11
to
I decided to use my computer for more than just work and to
play an audio CD. I did it years ago, but it no longer works with my
Squeeze installation.

I installed xfreecd and when I run it with a CD inserted in the drive I
get: cdrom_init(CDROMVOLREAD-2): Input/output error and the interface
does not pop up. I find that I need to have read permission for the
device (chmod ugo+r /dev/hdc), but with Squeeze I now use uuid and so
there's no hdc.

Incidentally, $ mplayer cdda:// does play the disk, although with
regular priodic brief pauses for some reason.

Haines Brown



Message has been deleted

Haines Brown

unread,
Jun 8, 2011, 10:55:51 PM6/8/11
to
"H.I.T.man" <H.I....@debian.user.invalid.org> writes:

> Didn't expressly ask for advice, but I assume you desire it. As such,
> make certain you are a member of the right groups; for instance:
>
> cmo@codybeau:~$ groups
> cmo adm cdrom audio video plugdev games fuse admin

I have "root", but no "admin" group. I have fuse-utils installed, but no
fuse group. Although I'm in the adm group, the $ groups command does not
list it. I was not in one of the groups you mentioned, and now at least
the xfreecd interface comes up. Even there's a CD disk in the drive, I
get xfreecd interface error: "No Disk", and in the terminal I get:

$ xfreecd
XfreeCD v0.9.0.1
<http://xfreecd.sourceforge.net>

cdrom_init(CDROMVOLREAD-2): Input/output error
cdrom_init(CDROMVOLREAD-2): Input/output error

So my problem remains. It seems that xfreecd assumes that I use the
/dev/hdc interface, but I'm using uuid, and so at this point there's no
device interface file for it. This would certainly account for the I/O
error. I'm not sure what to tell xfreecd what the UUID for the drive is.

Haines Brown

Message has been deleted

Sven Joachim

unread,
Jun 9, 2011, 5:01:34 AM6/9/11
to
On 2011-06-08 23:32 +0200, Haines Brown wrote:

> I decided to use my computer for more than just work and to
> play an audio CD. I did it years ago, but it no longer works with my
> Squeeze installation.
>
> I installed xfreecd and when I run it with a CD inserted in the drive I
> get: cdrom_init(CDROMVOLREAD-2): Input/output error and the interface
> does not pop up. I find that I need to have read permission for the
> device (chmod ugo+r /dev/hdc), but with Squeeze I now use uuid and so
> there's no hdc.

You cannot use UUID for CD-ROM drives because they don't have one. Your
drive is most probably called /dev/sr0 these days, and there should be a
/dev/cdrom symlink to it.

> Incidentally, $ mplayer cdda:// does play the disk, although with
> regular priodic brief pauses for some reason.

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=629158 for that
part of the story.

Sven

Haines Brown

unread,
Jun 9, 2011, 7:23:03 AM6/9/11
to
"H.I.T.man" <H.I....@debian.user.invalid.org> writes:

> I'm suggesting is that you should be in cdrom, audio and, perhaps,
> plugdev so you can access those devices.

$ groups
haines lp voice cdrom floppy audio dip video plugdev ssh lpadmin netdev
saned

$ ls -la /dev | grep cdrom
lrwxrwxrwx 1 root root 3 Jun 8 22:30 cdrom -> sr0
crw-rw---- 1 root cdrom 21, 1 Jan 6 10:12 sg1
brw-rw----+ 1 root cdrom 11, 0 Jun 8 22:30 sr0

I assume that, although root owns cdrom, since sr0 is in cdrom group
user should be able to read from the CD drive.

> Once it is established you are in the right groups, then try resolving
> application problems.

Are you saying that since my audio system is working (mplayer plays a
disk), user's group memberships are correct, and there is a symlink from
cdrom to sr0, the problem must be with the application (xfreecd) itself?
However, I tried the cccd application, and it doesn't work either:

The cccd status window has:

Unknown
Track 1
00:00 track
Error Normal

The last line describes the "status", but I find it to be cryptic. Is
the error message that things are normal? Is there an error named
"normal"?

Haines

J G Miller

unread,
Jun 9, 2011, 7:56:11 AM6/9/11
to
On Thu, 09 Jun 2011 07:23:03 -0400, Haines Brown explained:


> $ ls -la /dev | grep cdrom
> lrwxrwxrwx 1 root root 3 Jun 8 22:30 cdrom -> sr0
> crw-rw---- 1 root cdrom 21, 1 Jan 6 10:12 sg1 brw-rw----+ 1
> root cdrom 11, 0 Jun 8 22:30 sr0
>
> I assume that, although root owns cdrom, since sr0 is in cdrom group
> user should be able to read from the CD drive.

1) Start xfreecd at the command line

user> xfreecd

You will see the xfreecd graphical interface.

2) Click with the left mouse button on the question mark button "?"

3) You will see a new window open titled XFreeCD Setup.

By default the first tab "About" is displayed.

4) Click with the left mouse button on the second table labeled "Setup".

You will now see the text label "CDROM device:" and an input text field.

I suspect that the current contents of this text field are /dev/hdc

5) Delete the string "hdc" and replace with the string "cdrom"

6) Change any other options according to your preferences.

7) Cick the close button with the left mouse button.

8) Insert audio CD-ROM audio disc into your CD-ROM playing device.

Does xfreecd find the disc and do a CDDB lookup?

Haines Brown

unread,
Jun 10, 2011, 6:53:15 AM6/10/11
to
J G Miller <mil...@yoyo.ORG> writes:

> 4) Click with the left mouse button on the second table labeled "Setup".
>
> You will now see the text label "CDROM device:" and an input text field.
>
> I suspect that the current contents of this text field are /dev/hdc

Thanks for providing directions I didn't see in the manual. I did as you
suggested, and found that in fact, the field had /dev/cdrom.

> 8) Insert audio CD-ROM audio disc into your CD-ROM playing device.
>
> Does xfreecd find the disc and do a CDDB lookup?

No.

$ xfreecd
XfreeCD v0.9.0.1
<http://xfreecd.sourceforge.net>

CDROM device: No medium found
CDROM device: No medium found

I now insert a disk, but it has no effect. The interface continues to
display the message "No Disk", even though Autoplay is enabled. I click
Play button:

cdrom_init(CDROMVOLREAD-2): Input/output error

If I click Eject button on the xfreecd interface, it does not work, but
in the terminal are displayed a long list of libraries being used I
suppose and ending:

...
b6ca0000-b6ca2000 rw-p 00023000 08:07 262681 /usr/lib/libexpat.so.1.5.2
b6ca2000-b6cbb000 r-xp 00000000 08:05 391024 /lib/libselinux.so.1
b6cbb000-b6cbc000 r--p 00018000 08:05 391024 /lib/libselinux.so.1
b6cbc000-b6cbd000 rw-p 00019000 08:05 391024 /lib/libselinux.so.1
b6cbd000-b6cbe000 rw-p 00000000 00:00 0
b6cbe000-b6cce000 r-xp 00000000 08:05 391003 /lib/i686/cmov/libresolv-2.11.2.sosigabrt caught
cddbd read error: Success

I get feeling the next to last line is the attempt to access cddbd
online, but for some reason the process is aborted because of
"successful" read error. No idea what this means or why it should
prevent xfreecd from playing a disk.


Shadow

unread,
Jun 10, 2011, 9:12:20 AM6/10/11
to
On Fri, 10 Jun 2011 06:53:15 -0400, Haines Brown
<hai...@HistoricalMaterialism.info> wrote:

>If I click Eject button on the xfreecd interface, it does not work, but
>in the terminal are displayed a long list of libraries being used I
>suppose and ending:

What happens if you type
eject
In the terminal ?
[]'s

J G Miller

unread,
Jun 10, 2011, 10:38:07 AM6/10/11
to
On Friday, June 10th, 2011 at 06:53:15h -0400, Haines Brown explained:

> CDROM device: No medium found
> CDROM device: No medium found

What is the actual brand/model of the CD-ROM hardware device?

I presume it is not a SCSI CD-ROM since xfreecd does not support
SCSI CD-ROMs.

> cdrom_init(CDROMVOLREAD-2): Input/output error

Have you tried more than one audio CD-ROM?

It could be that that particular audio disc is bad.

It could also be that your CD-ROM device is dying.

The fact that it is reporting a input/output error tends
to indicate that xfreecd is trying to use the correct device.

Do you see the light come on or hear any hardware spin up
activity when you try to play the disc?

Incidentally, xmcd is a much nicer audio disc player
than xfreecd.

Haines Brown

unread,
Jun 11, 2011, 9:05:34 AM6/11/11
to
Thanks JG, but first in reply to Shadow, an $ eject command does eject
the tray.

J G Miller <mil...@yoyo.ORG> writes:

> Have you tried more than one audio CD-ROM?

Yes

> It could also be that your CD-ROM device is dying.

I have a Sony Optiarc 24X DVD/CD Rewritable SATA AD-7240S-0B - OEM,
purchased in 2009 and not much used. However, it does run DVD disks
without a problem. I tried a little compressed air toward the laser, but
of course this was an act of desperation.

> The fact that it is reporting a input/output error tends
> to indicate that xfreecd is trying to use the correct device.

That's what I suspected and good to have a confirmation.

> Do you see the light come on or hear any hardware spin up
> activity when you try to play the disc?

The LED goes on for a while, but I don't hear the disk spin up, but not
absolutely sure (super-quiet case and ancient ears). Starting xfreecd
and clicking the Play button had no effect, on either LED or spin up.

> Incidentally, xmcd is a much nicer audio disc player than xfreecd.

I tried it, and it is prettier and more capable. However, with it I get
a similar error. When the xmcd app is started, I get:
CD audio: ioctl error on /dev/cdrom: cmd=CDROMVOLCTRL errno=5
This is only controls the volume level. I was unable to pin down
errno=5, so don't know if this minor nuisance or a more serious access
problem.

When the Play button is clicked, I get:
CD audio: ioctl error on /dev/cdrom: cmd=CDROMPLAYMSF errno=95

I ran strace on xmcd. I'm no expert on this kind of troubleshooting,
but I did encounter the following suspicious lines. The initial line
here I gather means disk is OK: the drive did detect a medium. I don't
know what a return of 0 for CDROMSTART means.

...
ioctl(4, CDROM_DRIVE_STATUS, 0x7fffffff) = 4
ioctl(4, CDROMSTART, 0) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [CHLD], SA_RESTART}, 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
nanosleep({2, 0}, 0xbfbd6244) = 0
ioctl(4, CDROMPLAYMSF, 0xbfbd62c6) = -1 EOPNOTSUPP (Operation not
supported)
write(2, "CD audio: ioctl error on /dev/cd"..., 37) = 37
write(2, "cmd=CDROMPLAYMSF errno=95\n", 26) = 26
gettimeofday({1307794380, 952567}, NULL) = 0
gettimeofday({1307794380, 952607}, NULL) = 0
read(3, 0xa00cf38, 4096) = -1 EAGAIN (Resource
temporarily unavailable)

It seems the ioctl() function to access the drive uses CDROMPLAYMSF to
address the drive in a Minutes, Sectors, Frames format. It provides
start position, but the operation is not supported for transport
endpoint. Does this mean the physical drive does not understand where to
start playing?

I gather the API is pretty simple and robust and so it may be that the
physical drive is gone bust, although it does well with
DVD. Unfortunately, substituting another in my fancy case is such a
time-consuming and tricky operation that I can't do it out now.

Joe

unread,
Jun 11, 2011, 9:37:30 AM6/11/11
to
On Sat, 11 Jun 2011 09:05:34 -0400
Haines Brown <hai...@HistoricalMaterialism.info> wrote:

>
> I gather the API is pretty simple and robust and so it may be that the
> physical drive is gone bust, although it does well with
> DVD. Unfortunately, substituting another in my fancy case is such a
> time-consuming and tricky operation that I can't do it out now.
>

Have you tried software discs? If they read OK, then try booting a
recent Knoppix or Ubuntu DVD and have a look at the resulting devices
and modules. They run direct from disc, so the drive is not available
for audio CDs, but you may pick up some clues. Both of these are
Debian-based, so the underlying structure should be similar.

I don't know how easy it is these days, but it might be practical
to make a bootable USB-drive copy of a live distribution, which will
leave the drive available. I'd be surprised if a recent live distro
couldn't play audio discs from a working device, however unusual it was.
If you can get that far, it shouldn't be too hard to see what isn't
happening with straight Debian.

--
Joe

J G Miller

unread,
Jun 11, 2011, 12:12:45 PM6/11/11
to
On Saturday, June 11th, 2011 at 09:05:34h -0400, Haines Brown wrote:

> I have a Sony Optiarc 24X DVD/CD Rewritable SATA AD-7240S-0B - OEM,
> purchased in 2009 and not much used.

Well that is a decent piece of hardware so I am surprised that you
are having these problems.

> ...
> ioctl(4, CDROM_DRIVE_STATUS, 0x7fffffff) = 4 ioctl(4, CDROMSTART, 0)
> = 0 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
> rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [CHLD], SA_RESTART}, 8) = 0
> rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 nanosleep({2, 0},
> 0xbfbd6244) = 0 ioctl(4, CDROMPLAYMSF, 0xbfbd62c6) = -1
> EOPNOTSUPP (Operation not
> supported)
> write(2, "CD audio: ioctl error on /dev/cd"..., 37) = 37 write(2,
> "cmd=CDROMPLAYMSF errno=95\n", 26) = 26 gettimeofday({1307794380,
> 952567}, NULL) = 0 gettimeofday({1307794380, 952607}, NULL) = 0
> read(3, 0xa00cf38, 4096) = -1 EAGAIN (Resource
> temporarily unavailable)

This does seem to indicate a hardware problem.

This message is coming not from the software program but from the kernel

<http://www.mjmwired.NET/kernel/Documentation/ioctl/cdrom.txt>

error return:
ENOSYS cd drive not audio-capable.

The two things I would try are to install the very simple command line
CD player package cdtool, and try

cdplay -d /dev/sr0

and see if that gives similar errors, but since it appears to be
a kernel issue, it more than likely will give the same error.

And I know that it is probably considered heresy to suggest it,
but if you can boot your system into Windoze, do that and see
if trying to play audio CDs under Windoze also fails.

The purpose of that test is to show whether or not the failure
to play is independent of the operating system.

> Unfortunately, substituting another in my fancy case is such a
> time-consuming and tricky operation that I can't do it out now.

If you are desperate to play CDs on that machine you could temporarily
connect up a USB CD player. If you have a spare CD player lying around,
you would not need to buy a brand new external drive, just an external
enclosure.

Haines Brown

unread,
Jun 12, 2011, 12:17:21 AM6/12/11
to
J G Miller <mil...@yoyo.ORG> writes:

> This does seem to indicate a hardware problem.
>
> This message is coming not from the software program but from the kernel
>
> <http://www.mjmwired.NET/kernel/Documentation/ioctl/cdrom.txt>
>
> error return:
> ENOSYS cd drive not audio-capable.
>
> The two things I would try are to install the very simple command line
> CD player package cdtool, and try
>
> cdplay -d /dev/sr0
>
> and see if that gives similar errors, but since it appears to be
> a kernel issue, it more than likely will give the same error.

Yes, it did:

$ cdplay -d /dev/sr0
cdplay: ioctl cdromplaymsf: Operation not supported

> And I know that it is probably considered heresy to suggest it,
> but if you can boot your system into Windoze, do that and see
> if trying to play audio CDs under Windoze also fails.

I have no way to boot Windows: no Windows disk, no DOS partition, or
whatever might be needed. I've never used Windows.

> The purpose of that test is to show whether or not the failure
> to play is independent of the operating system.

I've got Linux on flash drive and could boot that, but I hesitate to
reboot my system (haven't done that for almost a year). I should
mention, although I don't see any relevance, that I don't use any
desktop manager.

>> Unfortunately, substituting another in my fancy case is such a
>> time-consuming and tricky operation that I can't do it out now.
>
> If you are desperate to play CDs on that machine you could temporarily
> connect up a USB CD player. If you have a spare CD player lying around,
> you would not need to buy a brand new external drive, just an external
> enclosure.

Problem is that I'm not desperate to play CDs. However, I did order an
external USB drive and will try to use it with an audio CD when it
arrives later this week.

Curt

unread,
Jun 12, 2011, 10:11:27 AM6/12/11
to

The only application I've used to read audio cds that functioned without
the "periodic brief pauses" syndrome is rhythmbox.

God know why.

Haines Brown

unread,
Jun 14, 2011, 6:35:27 PM6/14/11
to
Haines Brown <hai...@HistoricalMaterialism.info> writes:

> J G Miller <mil...@yoyo.ORG> writes:
>
>> This does seem to indicate a hardware problem.

I plugged in an external USB CD/DVD RW drive and loaded an audio
disk. The $ cdplay -d /dev/sr0 command and it returns the same error as
the internal drive:

$ cdplay -d /dev/sr0
cdplay: ioctl cdromplaymsf: Operation not supported

The problem is that I currently have two cdrom drives connected, and yet
only one "cdrom" symlink. Years ago the issue was simpler, for I'd have
a set of different cdrom symlinks to different device files.


J G Miller

unread,
Jun 14, 2011, 7:42:40 PM6/14/11
to
On Tuesday, June 14th, 2011 at 18:35:27h -0400, Haines Brown explained:

> I plugged in an external USB CD/DVD RW drive and loaded an audio disk.
> The $ cdplay -d /dev/sr0 command and it returns the same error as the
> internal drive:
>
> $ cdplay -d /dev/sr0
> cdplay: ioctl cdromplaymsf: Operation not supported

The problem here I think is that you are still trying to play
the built in Optiarc CD-ROM, unless you have disconnected that.

The second external CD-ROM should I think be on /dev/sr1.

Just after plugging in the external CD-ROM run dmesg and see
what device file has been allocated to it by the kernel.

> Years ago the issue was simpler, for I'd have a set of different
> cdrom symlinks to different device files.

If udev rules were setup correctly, a second cdrom link should be
created.

Haines Brown

unread,
Jun 15, 2011, 6:50:55 AM6/15/11
to
When I plug in the external USB CD drive,

$ dmsg
...
[13805214.082404] scsi 20:0:0:0: CD-ROM
TSSTcorp CDDVDW SE-S084F TS00 PQ: 0 ANSI: 0
[13805214.162140] sr1: scsi3-mmc drive: 8x/24x writer dvd-ram cd/rw
xa/form2 cdda tray
[13805214.162233] sr 20:0:0:0: Attached scsi CD-ROM sr1
[13805214.162444] sr 20:0:0:0: Attached scsi generic sg3 type 5

$ ls -la /dev | grep cdrom

lrwxrwxrwx 1 root root 3 Jun 15 06:16 cdrom -> sr0
lrwxrwxrwx 1 root root 3 Jun 15 06:17 cdrom1 -> sr1
lrwxrwxrwx 1 root root 3 Jun 15 06:17 cdrom2 -> sr1


crw-rw---- 1 root cdrom 21, 1 Jan 6 10:12 sg1

crw-rw---- 1 root cdrom 21, 3 Jun 15 05:59 sg3
brw-rw----+ 1 root cdrom 11, 0 Jun 15 06:16 sr0
brw-rw----+ 1 root cdrom 11, 1 Jun 15 06:17 sr1

This command starts some process, but it terminates after a few
seconds. No sound. The cdrom disk is spinning and cdeject works.

$ cdplay -d /dev/sr1

So I try:

$ cdplay -D -d /dev/sr1
cdplay: reading track 1 tocentry
cdplay: reading track 2 tocentry
cdplay: reading track 3 tocentry
cdplay: reading track 4 tocentry
cdplay: reading track 5 tocentry
cdplay: reading track 6 tocentry
cdplay: reading track 170 tocentry
do_play: called, trk0=0, trk1=0
do_play: trk[0.1]==0, status=0x15
cdplay: ioctl subchnl: NO_STATUS

I don't know how to read this, but it seems the disk TOC is read, but
when it comes to read track 1 it does not see it has any content and
so the process terminates. I find that status 0x15 is only that there is
no current audio status to return.

sh@dow

unread,
Jun 15, 2011, 8:53:16 AM6/15/11
to
On Wed, 15 Jun 2011 06:50:55 -0400, Haines Brown wrote:

> When I plug in the external USB CD drive,

> I don't know how to read this, but it seems the disk TOC is read, but
> when it comes to read track 1 it does not see it has any content and so
> the process terminates. I find that status 0x15 is only that there is no
> current audio status to return.

Is this with ANY music disk ? You could be trying to play those
DRM protected (&*⁽&%(%((%.
Just a though. Either that, or udev or libraries are messed up
somewhere.
[]'s

Haines Brown

unread,
Jun 16, 2011, 8:30:16 AM6/16/11
to
I tried CD disk that I know does play. I get sound when playing a DVD
disc on either CD drive, but no sound from a CDROM audio disk.

I did: # udevadm info -a -p $(udevadm info -q path -n /dev/sr0). This
provided a lot of info about the device and its parents, but I assume
that since DVD successfully uses that same interface, the problem is not
udev.

The only oddity is that the man udevadm says I can run udevadm with
"--debug", but I get:

# udevadm --debug
missing or unknown command

Is this error saying that udevadm --debug is an unknown command or that
udev is missing a command?

I tried:

# udevadm test /dev/sr1
...
parse_file: reading '/etc/udev/rules.d/z60_hdparm.rules' as rules file
udev_rules_new: rules use 37524 bytes tokens (3127 * 12 bytes), 19977 bytes b$
udev_rules_new: temporary index used 23240 bytes (1162 * 20 bytes)
unable to open device '/sys/dev/sr1'

This last line apparently because there is no such file:

# ls -la /sys/dev
total 0
drwxr-xr-x 4 root root 0 Jun 16 06:39 .
drwxr-xr-x 13 root root 0 Jan 6 10:12 ..
drwxr-xr-x 2 root root 0 Jun 16 06:59 block
drwxr-xr-x 2 root root 0 Jun 16 08:03 char

I'm in here way over my head, but something seems confused.


0 new messages