# cdrom drive speed, why so slow?

## drjimmy42

I have been ripping a lot of cds recently using grip which uses cdparanoia. While ripping grip reports a read speed of about 5.0x to 5.7x. The thing is i have a 40x cdrom drive. The amount of time it takes to rip an audio disc is consistent with the speed reported by grip, so I don't think that its wrong.

I tried ripping from the command line with cdparanoia with -S 40 (which is supposed to explicitly set the read speed ) and it still takes about as long as a 6x should take.

I am using kernel 2.6.0-test8 with no other problems. I am using scsi emulation. Does anyone know how I can crank up the speed on this cdrom drive? I have a lot of cds and just got an ipod...... :Smile: 

Thanks.

----------

## andrew_j_w

40x speed is the raw read speed. When ripping you not only read the cd, but also encode it into another format - probably mp3 or ogg. The encoding is a cpu intensive operation and consequently you'll never see a full speed rip.

I've got a PIII 800MHz and I see similar speeds you - you don't say what speed processor you've got, but I'm guessing there isn't much you can do.

HTH,

Andrew

----------

## Andersson

Perhaps you could increase the voltage? 230V should do it...  :Twisted Evil: 

40x is the maximum possible speed, the average speed on a whole

cd is always lower than this. 5x is not bad... My 8x cd rarely goes

above 1x. But then I've never bothered to increase the speed either.

Try to set the speed to 10, then 20 and see if you can increase the

speed that way. Otherwise look at your setup. Do you have dma

enabled for example? (Use the hdparm program).

----------

## drjimmy42

 *andrew_j_w wrote:*   

> 40x speed is the raw read speed. When ripping you not only read the cd, but also encode it into another format - probably mp3 or ogg. The encoding is a cpu intensive operation and consequently you'll never see a full speed rip.
> 
> I've got a PIII 800MHz and I see similar speeds you - you don't say what speed processor you've got, but I'm guessing there isn't much you can do.
> 
> HTH,
> ...

 

I already turned encoding off.  It is going straight to wav when I'm observing this.

----------

## drjimmy42

 *Andersson wrote:*   

> Perhaps you could increase the voltage? 230V should do it... 
> 
> 40x is the maximum possible speed, the average speed on a whole
> 
> cd is always lower than this. 5x is not bad... My 8x cd rarely goes
> ...

 

That's interesting, and kind of disappointing.  I was looking forward to ripping wavs off these cds in ~2-3 minutes.  Oh well.  By the way.

```
beethoven:/home/jorussel# hdparm /dev/scsi/host0/bus0/target0/lun0/cd

/dev/scsi/host0/bus0/target0/lun0/cd not supported by hdparm

beethoven:/home/jorussel# hdparm /dev/cdroms/cdrom0 

/dev/cdroms/cdrom0 not supported by hdparm

beethoven:/home/jorussel# 

```

I don't know what that means though....

----------

## drjimmy42

And I did try specifying a speed of 10, but no dice.  It still hovers around 5.2x.

----------

## ashtong

hdparm doesn't like SCSI emulation. If you're using ide-scsi you often find that equivalent IDE device files exist that you can run it on. For some reason I've never seen the IDE devices on Gentoo (probably the devfs config).

Try this instead:

```
# cat /proc/ide/hdc/settings

# echo using_dma:1 > /proc/ide/hdc/settings
```

It made quite a difference for me.

----------

## drjimmy42

I just checked that proc file.  DMA is already set to 1.  Thanks anyway though.

----------

## andrew_j_w

 *drjimmy42 wrote:*   

> I already turned encoding off.  It is going straight to wav when I'm observing this.

 

Ah, ok. You didn't mention that in your first post so that seemed like the mostly likly explaination.

I assume that as your cdrom drive has dma enabled your hard disk has as well?

What happens if you copy a file from a data cd? 5x works out to about 95kb/s.

Andrew

----------

## cyrillic

 *drjimmy42 wrote:*   

> I tried ripping from the command line with cdparanoia with -S 40 (which is supposed to explicitly set the read speed ) and it still takes about as long as a 6x should take. 

 

Have you tried cdda2wav ?

I just tried ripping a CD on my CDRW and I get 4521 seconds of audio in 148 seconds = 30x (average)

```
# time cdda2wav -D1,0,0 -B

Type: ROM, Vendor 'YAMAHA  ' Model 'CRW-F1E         ' Revision '1.0d' MMC+CDDA

724992 bytes buffer memory requested, 4 buffers, 75 sectors

#Cdda2wav version 2.01a18_linux_2.4.22-ac4_i686_amd-athlon-tm--, real time sched., soundcard, libparanoia support

AUDIOtrack pre-emphasis  copy-permitted tracktype channels

      1-16           no              no     audio    2

Table of Contents: total tracks:16, (total time 75:21.02)

  1.( 3:05.47),  2.( 4:18.25),  3.( 3:22.05),  4.( 4:33.08),  5.( 4:24.57),

  6.( 5:28.70),  7.( 4:36.65),  8.( 4:14.38),  9.( 6:05.07), 10.( 4:06.05),

 11.( 4:35.55), 12.( 4:32.10), 13.( 6:33.38), 14.( 4:59.37), 15.( 5:30.60),

 16.( 4:54.00)

 

Table of Contents: starting sectors

  1.(       0),  2.(   13922),  3.(   33297),  4.(   48452),  5.(   68935),

  6.(   88792),  7.(  113462),  8.(  134227),  9.(  153315), 10.(  180697),

 11.(  199152), 12.(  219832), 13.(  240242), 14.(  269755), 15.(  292217),

 16.(  317027), lead-out(  339077)

CDINDEX discid: fW7YJKA14_spAVJWhiwRYEO0Dc8-

CDDB discid: 0xf211a910

CD-Text: not detected

CD-Extra: not detected

samplefile size will be 797509148 bytes.

recording 4521.0266 seconds stereo with 16 bits @ 44100.0 Hz ->'audio'...

percent_done:

100%  track  1 successfully recorded

100%  track  2 successfully recorded

100%  track  3 successfully recorded

100%  track  4 successfully recorded

100%  track  5 successfully recorded

100%  track  6 successfully recorded

100%  track  7 successfully recorded

100%  track  8 successfully recorded

100%  track  9 successfully recorded

100%  track 10 successfully recorded

100%  track 11 successfully recorded

100%  track 12 successfully recorded

100%  track 13 successfully recorded

100%  track 14 successfully recorded

100%  track 15 successfully recorded

100%  track 16 successfully recorded

 

real    2m27.967s

user    0m0.116s

sys     0m3.411s 
```

Another possibility is your cdrom may only be 40x for data CDs and 6x for audio CDs

----------

## andrew_j_w

 *cyrillic wrote:*   

> Another possibility is your cdrom may only be 40x for data CDs and 6x for audio CDs

 

Exactly my thought, I believe some cd-drives treat disks differently depending on their content.

----------

## drjimmy42

 *cyrillic wrote:*   

> 
> 
> Have you tried cdda2wav ?
> 
> I just tried ripping a CD on my CDRW and I get 4521 seconds of audio in 148 seconds = 30x (average)
> ...

 

You know, that made me think.  cdparanoia actually does error correction when it rips, that's one of the reasons to use it.  That means that it would have to go slower to do that error checking and correction.  I'll try cdda2wav (which as far as I know just rips the damn thing) and see what the performance is like.  

Thanks for the idea.

John

----------

## drjimmy42

Ok, so the verdict is in.  cdda2wav is WAAAAAAY ( about twice as fast)  faster than cdparanoia, probably for the obvious reasons of cdparanoia error checking.  I suppose I'll stick with cdparanoia though.  I only have to rip these once so I want to get it right.  Also, I have to wait for them to encode in to mp3 anyway which already takes longer than cdparanoia does, so I would just have to wait.   

Anyway, thanks for the help.

John

----------

## secondshadow

 *andrew_j_w wrote:*   

>  *drjimmy42 wrote:*   I already turned encoding off.  It is going straight to wav when I'm observing this. 
> 
> Ah, ok. You didn't mention that in your first post so that seemed like the mostly likly explaination.
> 
> I assume that as your cdrom drive has dma enabled your hard disk has as well?
> ...

 

How do you figure that? 1x=150KB/s (btw the lowercase b means bits, upper its bytes, technically). My 52x cdrom has a max data transfer rate of 7800KB/s. 7800 / 150=52 see? So, using simple math we see that 5 * 150=750 KB/s. No offense but if you have a 5x CDROM that only performs at 95KB/s on average you have a seriously defective/broken CDROM. 

Now, in reference to the slow rips, how old is this CDROM and what brand is it? I had an old 52x Creative CDROM. Loved it to death. Was one of the best CDROMs I ever had, but its audio rip was only around 8x or so at its fastest. Usually it averaged around 6 or so for the 1st 1/2 of a CD (direct to WAV). Most CDROMS do not rip audio anywhere near as fast as the read data. TDK was on of the very first to offer CDROMS that ripped at (theoretically) the same speed as they read data. I can also tell you the grip at the very least using defaults doesn't rip nearly as fast as anything I've ever used in *shudders* windows. I tend to use MusicMatch Jukebox in windows with my 52x32x52 Memorex burner and I've seen it hit somewhere around 30-32x ripping so just because your CDROM says it can read data at 40x doesn't mean it can rip at that speed. The speed your interested in is DAE (Digital Audio Extraction). Most CDROM manufacturers won't even tell you this on the box or in any documentation because they know that its not anywhere even close to data reading, and since a lot of people buy faster CDROMs to rip music, if they told you their DAE was only 20x on a 40x drive, but you saw the TDK burner that had DAE of 48x on a 52x drive, and the extra $40 wasn't an issue, you'd buy the TDK and they'd lose business. Hell, even my HP dvd-writer dvd100i reads data at 32x but only rips somewhere around 10-12. So what I would try, if you can, is to boot up in *shudder* windows and rip something. See how fast it goes there. Make sure its a good, balanced, unscratched CD. This should give you some indication of what kind of performance you can expect from that particular drive.

----------

## andrew_j_w

 *secondshadow wrote:*   

> How do you figure that? 1x=150KB/s (btw the lowercase b means bits, upper its bytes, technically). My 52x cdrom has a max data transfer rate of 7800KB/s. 7800 / 150=52 see? So, using simple math we see that 5 * 150=750 KB/s. No offense but if you have a 5x CDROM that only performs at 95KB/s on average you have a seriously defective/broken CDROM.

 

Ah, you're right - looks like my maths was a teensy bit off there! That should have been 750kb/s.

Andrew

----------

