# The "other" flaw in Linux CD-Burning

## tristure

Hi,

I have read many threads about CD burning and the problems encountered, especially with 2.6.8 kernels.

So please note that this thread IS NOT about the "classic" error with 

"cdrecord returned an unknow error (code12) 

 Cannot allocate memory "

And by the way I've already removed the suid bits of cdrecord and cdrdao, which is the fix usually proposed for the "cannot allocate memory" error ; it did NOT solve anything.

Now the facts :

-I can burn CDs without any apparent problem.

-Most of the times, the CD check (in k3b) fails, and the CD itself is unusable.

-I have encountered this problem with the following kernels :

2.6.7-gentoo-dev-sources-r14

2.6.8-ck3

2.6.9-nitro4

-CD burning works fine with Knoppix, so I assume it's not hardware related

I know that I'm not the only one to have this problem, as I read on several threads. But as this seems slightly different from the usual CD-Burning problem, I thought it might be a good thing to start a new thread so as to keep things sorted.

So if you have (or have had) this problem, could you report it here : symptoms, kernel(s) used, the workarounds you tested, fixes you found, etc...

Your contribution or ideas are welcome.

PS : If you do not use CD-check with k3b, you might want to try it next times you burn CDs : it's the only direct way to know if you have this problem. Well, this and trying to use the burnt CD  :Wink:  !

Thanks a lot!

----------

## tristure

Just some additional information : when checking CD or trying to read it, dmesg reports this kind of errors :

 *Quote:*   

> hdc: media error (bad sector): status=0x51 { DriveReady SeekComplete Error }
> 
> hdc: media error (bad sector): error=0x34
> 
> ide: failed opcode was 100
> ...

 

And this error happens when I burn data CDs or when I burn .iso images.

I haven't tried audio CD's.

----------

## vonhelmet

Not sure if this is relevant to the problem you're suffering, but here goes...

I know my CD writer works, because I have used it in Windows XP.

I have tried various kernels including vanilla sources and gentoo-dev-sources with versions 2.6.5, 2.6.6, 2.6.7, 2.6.8, 2.6.9.

I have tried with ide-cd and ide-scsi (SCSI emulation)

I have tried with modules and with a monolithic kernel

I have tried with k3b, xcdroast, command line

I have tried with suid bits set and unset

I have tried different speeds

I have tried different media

With all of these I have the problem that the cdrecord process hangs and doesn't do anything. It leaves a process that can't be killed, even with a kill -9 command. If I'm using scsi emulation, then the hanging process takes the CDRW drive down with it, and I can't open it in any way and have to reboot the PC.

I installed cdrdao instead and that works fine. I think it's some problem with cdrtools, but it must be very specific to my set up or to my CDRW drive as lots of other people seem to cope fine with it.

----------

## tristure

Mmm actually it doesn't seem to be the same problem. For two reasons :

1) I don't see any hanging processus, I don't have to kill anything

2) (More problematic) I have tried cdrdao as well and it didn't change anything   :Crying or Very sad: 

But thanks for your feedback and the dao tip.   :Wink: 

----------

## Illissius

For me it works with 2.6.9-nitro1, removing the suid bits, and running as a normal user (K3b). Don't know whether it's using cdrecord or cdrdao, I have both installed. Likewise don't know whether it's using SCSI emulation, as iirc I do have it compiled in, but it's also supposed to work without -- my guess would be that it's not using it, but that's just a guess.

Both data and audio CDs work, and play fine.

----------

## tristure

Actually with 2.6.4-nitro4 I had to remove the suid bits to be able to burn CDs but the burnt CDs don't work.

Would you mind posting your kernel config or email it to me (tristan.palerm@noos.fr)?

Thanks a lot.

----------

## Illissius

 *tristure wrote:*   

> Actually with 2.6.4-nitro4 I had to remove the suid bits to be able to burn CDs but the burnt CDs don't work.
> 
> Would you mind posting your kernel config or email it to me (tristan.palerm@noos.fr)?
> 
> Thanks a lot.

 

here

----------

## tristure

Thanks (keszenem?!?   :Confused:  )

There are several differences between yours and mine.

Your config is preemptible-disabled, on mine it is enabled. Maybe I should try without preemption. Even if I doubt it would change anything.

I'm so desperate I think I'll try that.

In general setup, too, we have several differences but for options I don't know at all (POSIX-MQUEUE for instance, which is disabled on mine, or IK_CONFIG which is disabled on yours).

Do you happen to know what the cryptographic options (at the end) are here for? For instance on my config md5 option is disabled, but k3b still calculates md5 sums to check things?!?

Well, seems I'm in for another kernel compilation night and some other screwed CDs...   :Confused: 

It's a pity, I would really like to stick with nitro4 which works amazingly on my box otherwise. Well, actually, I can still stick with it since no other kernel gives me good results with cd-burning 

 :Laughing:  .

----------

## tristure

I compiled another kernel, with preemption disabled, and some other options changed to make them closer to your config.

No improvement. I still get unusable CDs.

It's beginning to seriously get on my nerves, I have tested many kernels, changed a lot of options and still no luck.  :Mad: 

And the cost of all my screwed CDs is beginning to look frightening.

Now I have to boot Knoppix whenever I want to burn a CD, it's insane!   :Evil or Very Mad: 

Any help or other ideas GREATLY appreciated, I'm feeling quite desperate on this issue now.

----------

## Maxwell

By the look of the dmesg it looks like kernel config problems, maybe something in the "ATA/IDE..." section. Verify the chipset chosen.

It it gives you problems, try genkernel.   :Smile: 

P.S.: Remeber that you don't need scsi.

----------

## tristure

Actually I use genkernel...

I don't know how to compile my kernel myself.

And the only time I tried it would fail, so...

I use menuconfig though.

Yes I think I could try a "bloated" kernel, enabling as many options as I could, in the PCI section for instance.

Thanks for the suggestion.

----------

## Jengu

If you know what hardware you have, compiling a kernal is fairly easy. If compiling a kernel by hand has failed in the past, post a thread with the error you get.

----------

## Illissius

 *tristure wrote:*   

> I compiled another kernel, with preemption disabled, and some other options changed to make them closer to your config.
> 
> No improvement. I still get unusable CDs.
> 
> It's beginning to seriously get on my nerves, I have tested many kernels, changed a lot of options and still no luck. 
> ...

 

Well, can't really help with the actual issue, but I use CDRWs to test with myself.

----------

## tristure

 :Shocked: 

Hadn't even thought of it...

 :Confused: 

I must be some kind of dumbass...  :Rolling Eyes: 

----------

## tpf80

I too have the same issue, it happened, of course when I wanted to download an ISO to install gentoo on my x86 laptop.

I am currently on amd64

K3b will show that the cd is burnt ok, but the Md5 does not match and the cd is unuable. K3b Can however erase CDRW media fine.

I also tried running the test function before burning the cd, and the test showed that the burn should work. At first I thought that it was the fact that I had K3b from ~amd64, so I downgraded to the stable version and deps, and got the same results.

Aftre all of the problems with k3b I tried a few other cd software packages to no avail. All gave the same results, so I believe that there must be some kindof problem with an underlying library. 

I know for a fact that my hardware is working fine, as I am typing this from my windows partition >.< after burning the gentoo cdr that I need.

------------------------------Update-------------------------------------

I have also emerged nero and have the same exact problem as k3b. Although nero-linux seems to be more verbose about the sectors that are bad on the cd when it checks, pretty much the same exact result. Nero reports that the cd is burned ok, and then when I mount it or put it in another computer, then it does not work.

I'm wondering what libraries/functions are shared between k3b and nero. Perhaps that will narrow down what the problem could be...

----------

