# CD/DVD writing problems

## hoerbe

Hi Gentooers,

I recently bought the Samsung TS-H552 DVD+-R/RW device. I emerged dvdrtools, dvd+rw-tools and k3b. First everithing went fine. I burned CD-R and DVD-R. But now, I have no idea why, I'm not able to burn any media anymore!

Look at this example:

```

aw@blizz aw $ dvd+rw-format /dev/sr0

* DVD±RW/-RAM format utility by <appro@fy.chalmers.se>, version 4.10.

* 4.7GB DVD+RW media detected.

* formatting 92.3/

aw@blizz aw $ growisofs -Z /dev/sr0=image.iso

Executing 'builtin_dd if=image.iso of=/dev/sr0 obs=32k seek=0'

/dev/sr0: "Current Write Speed" is 4.1x1385KBps.

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         0/4694835200 ( 0.0%) @0x, remaining ??:??

         ...

```

Then my System freezes. If I open the DVD tray...

```

:-( unable to WRITE@LBA=0h: Input/output error

:-( write failed: Input/output error

aw@blizz movies $ 

```

this happens and the system is not deadlocked any more. But I cannot open the tray anymore. Now cdrecord -scanbus reports no device.

If I try to burn a CD-R with cdrecord or k3b an error like "no media found" occures. Unfortunately I cannot post this error message because my tray has a DVD in and is blocked now.

I can mount medias without any problem.

Did my device broke down or what? Any ideas?

Thanks for any reply.

----------

## hoerbe

oh, here is my partial dmesg output...

 *Quote:*   

> 
> 
> ...
> 
> devfs_mk_dev: could not append to parent for vcc/a7
> ...

 

I'll recompile my kernel with "Use DMA only for disks" and will post any results...

----------

## russianpirate

i wouldnt do that cause cdroms with pio r very slow

btw if ur using 2.6, do not select scsi unless u need for something other than cdrom cause 2.6 has writing support in it

did you enable VFAT support in kernel?

also, make sure that nothing else is using the cdrom (vmware,..)

----------

## hoerbe

Thanks for your quick reply.

Yes, I'm using 2.6 and enabled VFAT.

Some Questions...

Why do I need VFAT for burning?

Can I burn DVD's without the scsi-emu? 

I need scsi-emu for external harddrives and usb-memory-sticks, right?

I've installed the gnome desktop for the first time. Gnome runs some processes I'm not familiar with and so I don't know if they are using my cdrom eg. dbus-daemon-1, udevd, hald, gnome-vfs-daemon. What about magicdev?

I enabled "Use DMA only for disks" now and it works. If there is another solution I would be happy to hear about it. Burning uses 25-50% of my CPU capacity now...

----------

## cynric

I forget the exact reasoning, but with kernel 2.6 you do [should] not need scsi-emu for writing or for dvd/cdroms in general; not sure about harddrives, but I'm assuming the same goes.

----------

## Scratalacha

Yes, the 2.6 kernel has ellminated the need for SCSI-emulation for burning CD/DVD. However, if you wish to use usb thumb drives you need to enable generic SCSI support in your kernel.

Try using hdparm to change your drive to UDMA instead of PIO, it will make a huge difference.

----------

## hoerbe

OK - I switched back to dma. Anyway burning without dma does not work anymore. It only worked a couple of times?!?

that happens if I try to burn a CD-R as user with cdrecord:

```

cdrecord: No write mode specified.

cdrecord: Asuming -tao mode.

cdrecord: Future versions of cdrecord may have different drive dependent defaults.

cdrecord: Continuing in 5 seconds...

Cdrecord-Clone 2.01.01a01 (i686-pc-linux-gnu) Copyright (C) 1995-2004 Jörg Schilling

cdrecord: Warning: Running on Linux-2.6.10-gentoo-r6

cdrecord: There are unsettled issues with Linux-2.5 and newer.

cdrecord: If you have unexpected problems, please try Linux-2.4 or Solaris.

TOC Type: 1 = CD-ROM

scsidev: '/dev/hdc'

devname: '/dev/hdc'

scsibus: -2 target: -2 lun: -2

Warning: Open by 'devname' is unintentional and not supported.

Linux sg driver version: 3.5.27

Using libscg version 'schily-0.8'.

SCSI buffer size: 64512

cdrecord: Cannot allocate memory. Cannot get SCSI I/O buffer.

```

and that as root:

```

cdrecord: No write mode specified.

cdrecord: Asuming -tao mode.

cdrecord: Future versions of cdrecord may have different drive dependent defaults.

cdrecord: Continuing in 5 seconds...

Cdrecord-Clone 2.01.01a01 (i686-pc-linux-gnu) Copyright (C) 1995-2004 Jörg Schilling

cdrecord: Warning: Running on Linux-2.6.10-gentoo-r6

cdrecord: There are unsettled issues with Linux-2.5 and newer.

cdrecord: If you have unexpected problems, please try Linux-2.4 or Solaris.

TOC Type: 1 = CD-ROM

scsidev: '/dev/hdc'

devname: '/dev/hdc'

scsibus: -2 target: -2 lun: -2

Warning: Open by 'devname' is unintentional and not supported.

Linux sg driver version: 3.5.27

Using libscg version 'schily-0.8'.

SCSI buffer size: 64512

atapi: 1

Device type    : Removable CD-ROM

Version        : 0

Response Format: 2

Capabilities   : 

Vendor_info    : 'TSSTcorp'

Identifikation : 'CD/DVDW TS-H552B'

Revision       : 'TS04'

Device seems to be: Generic mmc2 DVD-R/DVD-RW.

Current: 0x0000

Profile: 0x002B 

Profile: 0x001B 

Profile: 0x001A 

Profile: 0x0014 

Profile: 0x0013 

Profile: 0x0011 

Profile: 0x0010 

Profile: 0x000A 

Profile: 0x0009 

Profile: 0x0008 

cdrecord: This version of cdrecord does not include DVD-R/DVD-RW support code.

cdrecord: If you need DVD-R/DVD-RW support, ask the Author for cdrecord-ProDVD.

cdrecord: Free test versions and free keys for personal use are at ftp://ftp.berlios.de/pub/cdrecord/ProDVD/

Using generic SCSI-3/mmc   CD-R/CD-RW driver (mmc_cdr).

Driver flags   : MMC-3 SWABAUDIO BURNFREE 

Supported modes: TAO PACKET SAO SAO/R96P SAO/R96R RAW/R16 RAW/R96P RAW/R96R

Drive buf size : 1678336 = 1639 KB

FIFO size      : 4194304 = 4096 KB

Track 01: data     1 MB        

Total size:        1 MB (00:09.97) = 748 sectors

Lout start:        2 MB (00:11/73) = 748 sectors

cdrecord: Success. test unit ready: scsi sendcmd: no error

CDB:  00 00 00 00 00 00

status: 0x2 (CHECK CONDITION)

Sense Bytes: 70 00 02 00 00 00 00 0A 00 00 00 00 3A 01 00 00

Sense Key: 0x2 Not Ready, Segment 0

Sense Code: 0x3A Qual 0x01 (medium not present - tray closed) Fru 0x0

Sense flags: Blk 0 (not valid) 

cmd finished after 0.000s timeout 40s

cdrecord: No disk / Wrong disk!

```

Writing resp. copy files to a udf DVD+RW works very slow.

I'haven't tried it with growisofs with the new setting yet.

----------

## boroshan

 *Scratalacha wrote:*   

> Yes, the 2.6 kernel has ellminated the need for SCSI-emulation for burning CD/DVD. However, if you wish to use usb thumb drives you need to enable generic SCSI support in your kernel.
> 
> Try using hdparm to change your drive to UDMA instead of PIO, it will make a huge difference.

 

Got the same problem. I checked my config and found I was indeed running SCSI emulation. I've turned that off and ide/atapi access on. I'l report back as soon as the compile is done

I also have a USB keydrive. Does that rely on SCSI emulation?. Never mind, I'll try that too...

----------

## boroshan

Right! I removed SCSI emulation and SCSI CDROM support from the kernel, and made sure that ATAPI/IDE CDROM was enabled. Accordingly, the kernel recognises the dvd writer as an IDE device. It then announces that it's passing hdc to the SCSI IDE emulation software.

Which of course I don't have, having just removed it. Result: no cd/dvd drive of any description. /dev/hdc is not a block device. /dev/cdrom is nonexistent.

I don't have time to sort this out this right now; (my morning was going to be spent doing some long overdue burns  :Sad: . Any advice or suggestions would be very welcome.

----------

## boroshan

I did one last search base upon the info I just gained: The problem ws that I still had 

```
hdc=scsi
```

 in my kernel params. Once I removed that my dvd burner re-appeared and is currently burning away like a good 'un.

Hope this helps someone

----------

