I use ThinkPad T60 with Slackware 12.1. Recently I observed strange behavior of DVD/CD-RW drive in my laptop. When I run the command to write data or audio disk everything works well but in result sometimes I obtain recorded disk and sometimes an empty one. If the drive doesn't write the disk it remains intact despite of the output of cdrecord or cdrdao which suggests that data or audio was written on the disk. Sometimes I need to write the same data on the same disk for a few times before I gain properly written disk.
To write data I use the command:
cdrecord -v dev=/dev/cdrw1 speed=12 image.iso
To write audio I use the command:
cdrdao write --device ATA:0,0,0 --driver generic-mmc --buffers 128 --speed 12 toc-file
On listing 1. I show the output of cdrecord and on listing 2. the output of cdrdao. These outputs look the same when drive writes disk successfully as well as when it doesn't write disk at all.
Listing 1.
Code:
cdrecord: No write mode specified.
cdrecord: Asuming -sao mode.
cdrecord: If your drive does not accept -sao, try -tao.
cdrecord: Future versions of cdrecord may have different drive dependent defaults.
Cdrecord-ProDVD-ProBD-Clone 2.01.01a38 (i686-pc-linux-gnu) Copyright (C) 1995-2008 Jörg Schilling
TOC Type: 1 = CD-ROM
cdrecord: Operation not permitted. Warning: Cannot raise RLIMIT_MEMLOCK limits.cdrecord: Cannot allocate memory. WARNING: Cannot do mlockall(2).
cdrecord: WARNING: This causes a high risk for buffer underruns.
cdrecord: Operation not permitted. WARNING: Cannot set RR-scheduler
cdrecord: Permission denied. WARNING: Cannot set priority using setpriority().
cdrecord: WARNING: This causes a high risk for buffer underruns.
scsidev: '/dev/cdrw1'
devname: '/dev/cdrw1'
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.9'.
SCSI buffer size: 64512
atapi: 1
Device type : Removable CD-ROM
Version : 0
Response Format: 2
Capabilities :
Vendor_info : 'HL-DT-ST'
Identifikation : 'DVDRAM GSA-4083N'
Revision : '1.08'
Device seems to be: Generic mmc2 DVD-R/DVD-RW/DVD-RAM.
Current: CD-R
Profile: DVD-RAM
Profile: DVD-R sequential recording
Profile: DVD-R/DL sequential recording
Profile: DVD-R/DL layer jump recording
Profile: DVD-RW sequential recording
Profile: DVD-RW restricted overwrite
Profile: DVD+RW
Profile: DVD+R
Profile: DVD+R/DL
Profile: DVD-ROM
Profile: CD-R (current)
Profile: CD-RW
Profile: CD-ROM
Profile: Removable Disk
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 LAYER_JUMP
Drive buf size : 1053696 = 1029 KB
Drive pbuf size: 1966080 = 1920 KB
FIFO size : 4194304 = 4096 KB
Track 01: data 660 MB
Total size: 759 MB (75:11.85) = 338389 sectors
Lout start: 759 MB (75:13/64) = 338389 sectors
Current Secsize: 2048
ATIP info from disk:
Indicated writing power: 4
Disk Is not unrestricted
Disk Is not erasable
Disk sub type: Medium Type A, high Beta category (A+) (3)
ATIP start of lead in: -11077 (97:34/23)
ATIP start of lead out: 359848 (79:59/73)
Disk type: Long strategy type (Cyanine, AZO or similar)
Manuf. index: 11
Manufacturer: Mitsubishi Chemical Corporation
Capacity Blklen/Sparesz. Format-type Type
0 2048 0x00 No Media Present or Unknown Capacity
Blocks total: 359848 Blocks current: 359848 Blocks remaining: 21459
cdrecord: Operation not permitted. WARNING: Cannot set RR-scheduler
cdrecord: Permission denied. WARNING: Cannot set priority using setpriority().
cdrecord: WARNING: This causes a high risk for buffer underruns.
Starting to write CD/DVD/BD at speed 10 in real SAO mode for single session.
Last chance to quit, starting real write 0 seconds. Operation starts.
Waiting for reader process to fill input buffer ... input buffer ready.
BURN-Free is OFF.
Performing OPC...
Sending CUE sheet...
cdrecord: WARNING: Drive returns wrong startsec (0) using -150
Writing pregap for track 1 at -150
Starting new track at sector: 0
Track 01: 660 of 660 MB written (fifo 100%) [buf 99%] 10.7x.
Track 01: Total bytes read/written: 693020672/693020672 (338389 sectors).
Writing time: 474.156s
Average write speed 9.5x.
Min drive buffer fill was 99%
Fixating...
Fixating time: 9.506s
cdrecord: fifo had 10916 puts and 10916 gets.
cdrecord: fifo was 0 times empty and 10797 times full, min fill was 89%.
Listing 2.
Code:
Cdrdao version 1.2.1 - (C) Andreas Mueller <andreas@daneb.de>
SCSI interface library - (C) Joerg Schilling
Paranoia DAE library - (C) Monty
Check http://cdrdao.sourceforge.net/drives.html#dt for current driver tables.
Format converter enabled for extensions: mp3 ogg
Using libscg version 'schily-0.8'
Using libscg transport code version 'schily-scsi-linux-sg.c-1.83'
ATA:0,0,0: HL-DT-ST DVDRAM GSA-4083N Rev: 1.08
Using driver: Generic SCSI-3/MMC - Version 2.0 (options 0x0000)
Starting write at speed 10...
Pausing 10 seconds - hit CTRL-C to abort.
Process can be aborted with QUIT signal (usually CTRL-\).
Waiting for reader process
Buffer filled
Awaken, will start writing
Turning BURN-Proof on
Session format: 0
Drive accepted write parameter mode page variant 0.
Executing power calibration...
Power calibration successful.
Drive accepted cue sheet variant 0.
Writing track 01 (mode AUDIO/AUDIO )...
Wrote 34 of 34 MB (Buffers 100% 99%).
Wrote 15575 blocks. Buffer fill min 98%/max 100%.
Flushing cache...
Writing finished successfully.
Then I decided to test how that drive writes disks in multi session mode. I did a few consecutive tests. Almost each time I observed different output of cdrecord. The result was always the same: unwritten session.
To create image file I used the command:
mkisofs -r -J -D -C `cdrecord -msinfo dev=/dev/cdrw1` -M ATA:1000,0,0 -o image.iso .
To write image I used the command:
cdrecord -v dev=/dev/cdrw1 -multi speed=12 image.iso
Here are the outputs of four consecutive attempts. Listing 3. ends with some errors and ``Cannot fixate disk'' message. Listing 4. ends with some errors and fixating attempt. Listing 5. ends with ``Could not write Lead-in'' message. Listing 6. ends properly. In all four cases the session wasn't written on the disk. I always used the same command but despite of it in the third case cdrecord used sao mode instead of tao.
Listing 3.
Code:
cdrecord: No write mode specified.
cdrecord: Asuming -tao mode.
cdrecord: Future versions of cdrecord may have different drive dependent defaults.
Cdrecord-ProDVD-ProBD-Clone 2.01.01a38 (i686-pc-linux-gnu) Copyright (C) 1995-2008 Jörg Schilling
TOC Type: 3 = CD-ROM XA mode 2
scsidev: '/dev/cdrw1'
devname: '/dev/cdrw1'
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.9'.
SCSI buffer size: 64512
atapi: 1
Device type : Removable CD-ROM
Version : 0
Response Format: 2
Capabilities :
Vendor_info : 'HL-DT-ST'
Identifikation : 'DVDRAM GSA-4083N'
Revision : '1.08'
Device seems to be: Generic mmc2 DVD-R/DVD-RW/DVD-RAM.
Current: CD-RW
Profile: DVD-RAM
Profile: DVD-R sequential recording
Profile: DVD-R/DL sequential recording
Profile: DVD-R/DL layer jump recording
Profile: DVD-RW sequential recording
Profile: DVD-RW restricted overwrite
Profile: DVD+RW
Profile: DVD+R
Profile: DVD+R/DL
Profile: DVD-ROM
Profile: CD-R
Profile: CD-RW (current)
Profile: CD-ROM (current)
Profile: Removable Disk
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 LAYER_JUMP
Drive buf size : 1053696 = 1029 KB
Drive pbuf size: 1966080 = 1920 KB
Drive DMA Speed: 12980 kB/s 73x CD 9x DVD 2x BD
FIFO size : 4194304 = 4096 KB
Track 01: data 0 MB padsize: 238 KB
Total size: 0 MB (00:04.02) = 302 sectors
Lout start: 1 MB (00:06/02) = 302 sectors
Current Secsize: 2048
ATIP info from disk:
Indicated writing power: 6
Reference speed: 2
Disk Is not unrestricted
Disk Is erasable
ATIP start of lead in: -11078 (97:34/22)
ATIP start of lead out: 336075 (74:43/00)
1T speed low: 0 (reserved val 0) 1T speed high: 4
2T speed low: 0 (reserved val 5) 2T speed high: 0 (reserved val 12)
power mult factor: 3 5
recommended erase/write power: 3
A1 values: 02 3A B0
A2 values: 5C C6 26
Disk type: Phase change
Manuf. index: 11
Manufacturer: Mitsubishi Chemical Corporation
Capacity Blklen/Sparesz. Format-type Type
26408 2048 0x00 Formatted Media
Blocks total: 336075 Blocks current: 302767 Blocks remaining: 302465
Starting to write CD/DVD/BD at speed 4 in real TAO mode for multi session.
Last chance to quit, starting real write 0 seconds. Operation starts.
Waiting for reader process to fill input buffer ... input buffer ready.
BURN-Free is OFF.
Performing OPC...
Starting new track at sector: 33308
Track 05: 0 of 0 MB written.
Track 05: writing 238 KB of pad data.
Track 05: Total bytes read/written: 370688/614400 (300 sectors).
Writing time: 23.678s
Average write speed 0.2x.
Fixating...
cdrecord: Success. close track/session: scsi sendcmd: no error
CDB: 5B 00 02 00 00 00 00 00 00 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 04 00 00 00 00 10 34 10 04 90 09 01 00 00
Sense Key: 0x4 Hardware Error, Segment 0
Sense Code: 0x09 Qual 0x01 (tracking servo failure) Fru 0x0
Sense flags: Blk 0 (not valid)
cmd finished after 34.060s timeout 480s
cmd finished after 34.060s timeout 480s
cdrecord: Cannot fixate disk.
Fixating time: 34.066s
cdrecord: fifo had 6 puts and 6 gets.
cdrecord: fifo was 0 times empty and 0 times full, min fill was 100%.
Listing 4.
Code:
cdrecord: No write mode specified.
cdrecord: Asuming -tao mode.
cdrecord: Future versions of cdrecord may have different drive dependent defaults.
Cdrecord-ProDVD-ProBD-Clone 2.01.01a38 (i686-pc-linux-gnu) Copyright (C) 1995-2008 Jörg Schilling
TOC Type: 3 = CD-ROM XA mode 2
scsidev: '/dev/cdrw1'
devname: '/dev/cdrw1'
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.9'.
SCSI buffer size: 64512
atapi: 1
Device type : Removable CD-ROM
Version : 0
Response Format: 2
Capabilities :
Vendor_info : 'HL-DT-ST'
Identifikation : 'DVDRAM GSA-4083N'
Revision : '1.08'
Device seems to be: Generic mmc2 DVD-R/DVD-RW/DVD-RAM.
Current: CD-RW
Profile: DVD-RAM
Profile: DVD-R sequential recording
Profile: DVD-R/DL sequential recording
Profile: DVD-R/DL layer jump recording
Profile: DVD-RW sequential recording
Profile: DVD-RW restricted overwrite
Profile: DVD+RW
Profile: DVD+R
Profile: DVD+R/DL
Profile: DVD-ROM
Profile: CD-R
Profile: CD-RW (current)
Profile: CD-ROM (current)
Profile: Removable Disk
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 LAYER_JUMP
Drive buf size : 1053696 = 1029 KB
Drive pbuf size: 1966080 = 1920 KB
Drive DMA Speed: 13059 kB/s 74x CD 9x DVD 2x BD
FIFO size : 4194304 = 4096 KB
Track 01: data 0 MB padsize: 238 KB
Total size: 0 MB (00:04.02) = 302 sectors
Lout start: 1 MB (00:06/02) = 302 sectors
Current Secsize: 2048
ATIP info from disk:
Indicated writing power: 6
Reference speed: 2
Disk Is not unrestricted
Disk Is erasable
ATIP start of lead in: -11078 (97:34/22)
ATIP start of lead out: 336075 (74:43/00)
1T speed low: 0 (reserved val 0) 1T speed high: 4
2T speed low: 0 (reserved val 5) 2T speed high: 0 (reserved val 12)
power mult factor: 3 5
recommended erase/write power: 3
A1 values: 02 3A B0
A2 values: 5C C6 26
Disk type: Phase change
Manuf. index: 11
Manufacturer: Mitsubishi Chemical Corporation
Capacity Blklen/Sparesz. Format-type Type
26408 2048 0x00 Formatted Media
Blocks total: 336075 Blocks current: 302767 Blocks remaining: 302465
Starting to write CD/DVD/BD at speed 4 in real TAO mode for multi session.
Last chance to quit, starting real write 0 seconds. Operation starts.
Waiting for reader process to fill input buffer ... input buffer ready.
BURN-Free is OFF.
Performing OPC...
Starting new track at sector: 33308
Track 05: 0 of 0 MB written.
Track 05: writing 600 KB of pad data.
cdrecord: Success. write_g1: scsi sendcmd: no error
CDB: 2A 00 00 00 82 1C 00 00 1F 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 04 00 00 00 00 10 00 00 64 90 08 03 00 00
Sense Key: 0x4 Hardware Error, Segment 0
Sense Code: 0x08 Qual 0x03 (logical unit communication crc error (ultra-dma/32)) Fru 0x0
Sense flags: Blk 0 (not valid)
resid: 63488
cmd finished after 0.002s timeout 40s
write track pad data: error after 0 bytes
BFree: 1026 K BSize: 1029 K
Track 05: Total bytes read/written: 370688/0 (0 sectors).
Writing time: 57.201s
Average write speed 0.1x.
Fixating...
Listing 5.
Code:
cdrecord: No write mode specified.
cdrecord: Asuming -sao mode.
cdrecord: If your drive does not accept -sao, try -tao.
cdrecord: Future versions of cdrecord may have different drive dependent defaults.
Cdrecord-ProDVD-ProBD-Clone 2.01.01a38 (i686-pc-linux-gnu) Copyright (C) 1995-2008 Jörg Schilling
TOC Type: 1 = CD-ROM
scsidev: '/dev/cdrw1'
devname: '/dev/cdrw1'
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.9'.
SCSI buffer size: 64512
atapi: 1
Device type : Removable CD-ROM
Version : 0
Response Format: 2
Capabilities :
Vendor_info : 'HL-DT-ST'
Identifikation : 'DVDRAM GSA-4083N'
Revision : '1.08'
Device seems to be: Generic mmc2 DVD-R/DVD-RW/DVD-RAM.
Current: CD-RW
Profile: DVD-RAM
Profile: DVD-R sequential recording
Profile: DVD-R/DL sequential recording
Profile: DVD-R/DL layer jump recording
Profile: DVD-RW sequential recording
Profile: DVD-RW restricted overwrite
Profile: DVD+RW
Profile: DVD+R
Profile: DVD+R/DL
Profile: DVD-ROM
Profile: CD-R
Profile: CD-RW (current)
Profile: CD-ROM (current)
Profile: Removable Disk
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 LAYER_JUMP
Drive buf size : 1053696 = 1029 KB
Drive pbuf size: 1966080 = 1920 KB
Drive DMA Speed: 11968 kB/s 68x CD 8x DVD 2x BD
FIFO size : 4194304 = 4096 KB
Track 01: data 0 MB padsize: 238 KB
Total size: 0 MB (00:04.00) = 300 sectors
Lout start: 1 MB (00:06/00) = 300 sectors
Current Secsize: 2048
ATIP info from disk:
Indicated writing power: 6
Reference speed: 2
Disk Is not unrestricted
Disk Is erasable
ATIP start of lead in: -11078 (97:34/22)
ATIP start of lead out: 359849 (79:59/74)
1T speed low: 0 (reserved val 0) 1T speed high: 4
2T speed low: 0 (reserved val 5) 2T speed high: 0 (reserved val 12)
power mult factor: 3 5
recommended erase/write power: 3
A1 values: 02 3A B0
A2 values: 5C C6 26
Disk type: Phase change
Manuf. index: 11
Manufacturer: Mitsubishi Chemical Corporation
Capacity Blklen/Sparesz. Format-type Type
19206 2048 0x00 Formatted Media
Blocks total: 359849 Blocks current: 333743 Blocks remaining: 333443
Starting to write CD/DVD/BD at speed 4 in real SAO mode for single session.
Last chance to quit, starting real write 0 seconds. Operation starts.
Waiting for reader process to fill input buffer ... input buffer ready.
BURN-Free is OFF.
Performing OPC...
Sending CUE sheet...
cdrecord: CUE sheet not accepted. Retrying with minimum pregapsize = 1.
cdrecord: Success. send_cue_sheet: scsi sendcmd: no error
CDB: 5D 00 00 00 00 00 00 00 20 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 05 00 00 00 00 10 5D 34 02 90 26 00 00 00
Sense Key: 0x5 Illegal Request, Segment 0
Sense Code: 0x26 Qual 0x00 (invalid field in parameter list) Fru 0x0
Sense flags: Blk 0 (not valid)
resid: 32
cmd finished after 0.003s timeout 200s
cdrecord: CUE sheet still not accepted. Please try to write in RAW (-raw96r) mode.
cdrecord: Cannot send CUE sheet.
cdrecord: Could not write Lead-in.
Writing time: 0.051s
cdrecord: fifo had 6 puts and 0 gets.
cdrecord: fifo was 0 times empty and 0 times full, min fill was 100%.
Listing 6.
Code:
cdrecord: No write mode specified.
cdrecord: Asuming -tao mode.
cdrecord: Future versions of cdrecord may have different drive dependent defaults.
Cdrecord-ProDVD-ProBD-Clone 2.01.01a38 (i686-pc-linux-gnu) Copyright (C) 1995-2008 Jörg Schilling
TOC Type: 3 = CD-ROM XA mode 2
scsidev: '/dev/cdrw1'
devname: '/dev/cdrw1'
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.9'.
SCSI buffer size: 64512
atapi: 1
Device type : Removable CD-ROM
Version : 0
Response Format: 2
Capabilities :
Vendor_info : 'HL-DT-ST'
Identifikation : 'DVDRAM GSA-4083N'
Revision : '1.08'
Device seems to be: Generic mmc2 DVD-R/DVD-RW/DVD-RAM.
Current: CD-RW
Profile: DVD-RAM
Profile: DVD-R sequential recording
Profile: DVD-R/DL sequential recording
Profile: DVD-R/DL layer jump recording
Profile: DVD-RW sequential recording
Profile: DVD-RW restricted overwrite
Profile: DVD+RW
Profile: DVD+R
Profile: DVD+R/DL
Profile: DVD-ROM
Profile: CD-R
Profile: CD-RW (current)
Profile: CD-ROM (current)
Profile: Removable Disk
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 LAYER_JUMP
Drive buf size : 1053696 = 1029 KB
Drive pbuf size: 1966080 = 1920 KB
Drive DMA Speed: 12080 kB/s 68x CD 8x DVD 2x BD
FIFO size : 4194304 = 4096 KB
Track 01: data 0 MB padsize: 238 KB
Total size: 0 MB (00:04.02) = 302 sectors
Lout start: 1 MB (00:06/02) = 302 sectors
Current Secsize: 2048
ATIP info from disk:
Indicated writing power: 6
Reference speed: 2
Disk Is not unrestricted
Disk Is erasable
ATIP start of lead in: -11078 (97:34/22)
ATIP start of lead out: 359849 (79:59/74)
1T speed low: 0 (reserved val 0) 1T speed high: 4
2T speed low: 0 (reserved val 5) 2T speed high: 0 (reserved val 12)
power mult factor: 3 5
recommended erase/write power: 3
A1 values: 02 3A B0
A2 values: 5C C6 26
Disk type: Phase change
Manuf. index: 11
Manufacturer: Mitsubishi Chemical Corporation
Capacity Blklen/Sparesz. Format-type Type
19206 2048 0x00 Formatted Media
Blocks total: 359849 Blocks current: 333743 Blocks remaining: 333441
Starting to write CD/DVD/BD at speed 4 in real TAO mode for multi session.
Last chance to quit, starting real write 0 seconds. Operation starts.
Waiting for reader process to fill input buffer ... input buffer ready.
BURN-Free is OFF.
Performing OPC...
Starting new track at sector: 26106
Track 04: 0 of 0 MB written.
Track 04: writing 238 KB of pad data.
Track 04: Total bytes read/written: 370688/614400 (300 sectors).
Writing time: 35.721s
Average write speed 0.1x.
Fixating...
Fixating time: 41.082s
cdrecord: fifo had 6 puts and 6 gets.
cdrecord: fifo was 0 times empty and 0 times full, min fill was 100%.
I observed also some problem with reading disks. Sometimes my drive reads them and sometimes doesn't read. In such case dmesg displays messages as in Listing 7. (On my laptop /dev/hda it's DVD/CD-RW drive.)
Listing 7.
Code:
hda: irq timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hda: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hda: drive not ready for command
hda: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hda: drive not ready for command
hda: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hda: drive not ready for command
hda: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hda: drive not ready for command
hda: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
I tried my laptop with the other DVD/CD-RW drive. It worked fine -- it could read and write data, audio, and multi session disks without problems.
Does that means my original DVD/CD-RW drive is almost dead?