Here's a small pointer on howto burn DVD-R discs with growisofs, which is of
course part of dvd+rw-tools, see
homepage : http://fy.chalmers.se/~appro/linux/DVD+RW/
download : http://fy.chalmers.se/~appro/linux/DVD+RW/tools/
These tools work perfectly together with OSS DVD :
http://crashrecovery.org/oss-dvd.html
I created some extra RPMS for Mandrake, RedHat, Fedora and SuSE. More are to
follow. Also checkout the k3b burning program on http://www.k3b.org/
Burning a DVD iso-image :
=========================
1. dvd+rw-tools :
-----------------
Using growisofs from the dvd+rw-tools its fairly easy. To use growisofs
to write a pre-mastered ISO-image to a DVD+R or DVD-R record-able :
# growisofs -dvd-compat -Z /dev/scd2=mdk92.iso
# growisofs -dvd-compat -Z /dev/hdc=mdk92.iso
The pre-mastered ISO-image is of course typically created with mkisofs
version 2.00 or higher.
2. cdrtools-ossdvd :
--------------------
With ossdvd cdrecord the same operation is also fairly easy. Burning a
single track and closing the DVD disc :
burning DVD-R and DVD-RW :
A: # cdrecord -v dev=2,0,0 driveropts=burnfree -dao mdk92.iso
B: # cdrecord -v dev=ATAPI:0,0,0 driveropts=burnfree -dao mdk92.iso
C: # cdrecord -v dev=ATA:1,0,0 driveropts=burnfree -dao mdk92.iso
Sometimes its better to drop the burning speed from autodetect
(like 16x to 8x) by using the speed option :
A: # cdrecord -v dev=2,0,0 driveropts=burnfree speed=8 -dao mdk92.iso
B: # cdrecord -v dev=ATAPI:0,0,0 driveropts=burnfree speed=8 -dao mdk92.iso
C: # cdrecord -v dev=ATA:1,0,0 driveropts=burnfree speed=8 -dao mdk92.iso
formatting DVD-RW :
A: # cdrecord -v dev=2,0,0 blank=fast (try blank=help)
B: # cdrecord -v dev=ATAPI:0,0,0 blank=fast
C: # cdrecord -v dev=ATA:1,0,0 blank=fast
burning DVD+RW :
A: # cdrecord -v dev=2,0,0 driveropts=burnfree mdk92.iso
B: # cdrecord -v dev=ATAPI:0,0,0 driveropts=burnfree mdk92.iso
C: # cdrecord -v dev=ATA:1,0,0 driveropts=burnfree mdk92.iso
formatting DVD+RW :
A: # cdrecord -v dev=2,0,0 -format (only needed once,
B: # cdrecord -v dev=ATAPI:0,0,0 -format after purchasing a
C: # cdrecord -v dev=ATA:1,0,0 -format new DVD+RW disc )
burning DVD+R DL :
A: # cdrecord -v dev=2,0,0 driveropts=burnfree mdk92.iso
B: # cdrecord -v dev=ATAPI:0,0,0 driveropts=burnfree mdk92.iso
C: # cdrecord -v dev=ATA:1,0,0 driveropts=burnfree mdk92.iso
Check below how to retrieve which device name to use.
Reading a DVD iso-image :
=========================
A: # readcd -v dev=2,0,0 f=mdk92.iso
B: # readcd -v dev=ATAPI:0,0,0 f=mdk92.iso
C: # readcd -v dev=ATA:1,0,0 f=mdk92.iso
Check below how to retrieve which device name to use.
readcd is typically a component from the cdrtools package. Make sure
you use cdrtools 2.0x, preferably from the OSS DVD project or
the readcd which comes with cdrecord-prodvd.
The preferred method for reading and burning DVD is of course method A,
next choose method C, and as last resort use method B. When using Method
B it seems DMA cannot be used during reading/burning. here's the
warning message from cdrtools-2.01a32.tar.bz2 :
scsidev: 'ATAPI:0,0,0'
devname: 'ATAPI'
scsibus: 0 target: 0 lun: 0
Warning: Using ATA Packet interface.
Warning: The related Linux kernel interface code seems to be unmaintained.
Warning: There is absolutely NO DMA, operations thus are slow.
I disagree here though : DMA not available results rather in a high system
load, and possibly slower buffering, but a fast burning speed is still
achieved. Your IDE/ATAPI devices are just inefficient operated.
Creating a bootable isolinux DVD Installation Boot iso-image :
==============================================================
#!/bin/sh
cd /mnt/dvdrip/
/usr/bin/mkisofs -o /mnt/dvdrip/mdk92.iso \
-b isolinux/isolinux.bin -c isolinux/boot.cat \
-no-emul-boot -boot-load-size 4 -boot-info-table \
-hide-joliet-trans-tbl \
-l -r -L -J -V "Mandrake 9.2 i586 DVD" -P "STOCK-2003102001" \
-p "stock" -A "Mandrake 9.2 i586 DVD" "/mnt/dvdrip/i586"
echo " Done!"
exit 0
As of mkisofs version 2.01a32 and higher versions the above script needs
to be adjusted into the following :
#!/bin/sh
/usr/bin/mkisofs -o /mnt/data/mdk100-amd64.iso \
-b isolinux/isolinux.bin -c isolinux/boot.cat \
-no-emul-boot -boot-load-size 4 -boot-info-table \
-hide-joliet-trans-tbl -hide-rr-moved -allow-leading-dots \
-l -r -J -V "Mandrake 10.0 AMD64 DVD" -publisher "STOCK-2004093001" \
-p "stock" -A "Mandrake 10.0 AMD64 DVD" "/mnt/data/mdk100"
echo " Done!"
exit 0
Checking which cdrecord devices are available :
===============================================
method A: ide-scsi or e.g. adaptec-scsi using Linux sg transport :
------------------------------------------------------------------
# cdrecord -scanbus
Cdrecord-Clone 2.01a18 (i686-pc-linux-gnu) Copyright (C) 1995-2003 Jörg Schilling
NOTE: this is OSS DVD extensions for cdrtools and thus may have bugs
related to DVD issues that are not present in the original cdrtools. For
more information see http://crashrecovery.org/oss-dvd.html. The original
cdrtools author should not be bothered with problems in this version.
Linux sg driver version: 3.1.25
Using libscg version 'schily-0.7'
scsibus1:
1,0,0 100) *
1,1,0 101) *
1,2,0 102) *
1,3,0 103) 'PLEXTOR ' 'CD-ROM PX-40TS ' '1.13' Removable CD-ROM
1,4,0 104) 'PLEXTOR ' 'CD-R PX-W1210S' '1.00' Removable CD-ROM
1,5,0 105) *
1,6,0 106) *
1,7,0 107) *
scsibus2:
2,0,0 200) 'PIONEER ' 'DVD-RW DVR-107D' '1.05' Removable CD-ROM
2,1,0 201) 'PIONEER ' 'DVD-RW DVR-105 ' '1.30' Removable CD-ROM
2,2,0 202) *
2,3,0 203) *
2,4,0 204) *
2,5,0 205) *
2,6,0 206) *
2,7,0 207) *
method A: burn command :
# cdrecord -v dev=2,0,0 driveropts=burnfree -dao mdk92.iso
method B: ATA Packet specific SCSI transport omitting linux sg transport :
--------------------------------------------------------------------------
# cdrecord dev=ATAPI -scanbus
Cdrecord-Clone 2.01a27 (i686-pc-linux-gnu) Copyright (C) 1995-2004 Jörg Schilling
NOTE: this is OSS DVD extensions for cdrtools and thus may have bugs
related to DVD issues that are not present in the original cdrtools. For
more information see http://crashrecovery.org/oss-dvd.html. The original
cdrtools author should not be bothered with problems in this version.
scsidev: 'ATAPI'
devname: 'ATAPI'
scsibus: -2 target: -2 lun: -2
Warning: Using ATA Packet interface.
Warning: The related libscg interface code is in pre alpha.
Warning: There may be fatal problems.
Using libscg version 'schily-0.8'.
scsibus0:
0,0,0 0) 'PIONEER ' 'DVD-RW DVR-105 ' '1.30' Removable CD-ROM
0,1,0 1) *
0,2,0 2) *
0,3,0 3) *
0,4,0 4) *
0,5,0 5) *
0,6,0 6) *
0,7,0 7) *
method B: burn command :
# cdrecord -v dev=ATAPI:0,0,0 driveropts=burnfree -dao mdk100.iso
method C: ATA Packet specific SCSI transport using scsi-linux-sg interface:
---------------------------------------------------------------------------
# cdrecord dev=ATA -scanbus
Cdrecord-Clone 2.01a27 (i686-pc-linux-gnu) Copyright (C) 1995-2004 Jörg Schilling
NOTE: this is OSS DVD extensions for cdrtools and thus may have bugs
related to DVD issues that are not present in the original cdrtools. For
more information see http://crashrecovery.org/oss-dvd.html. The original
cdrtools author should not be bothered with problems in this version.
scsidev: 'ATA'
devname: 'ATA'
scsibus: -2 target: -2 lun: -2
Warning: Using badly designed ATAPI via /dev/hd* interface.
Linux sg driver version: 3.5.27
Using libscg version 'schily-0.8'.
cdrecord: Warning: using inofficial libscg transport code version (schily -
Red Hat-scsi-linux-sg.c-1.80-RH '@(#)scsi-linux-sg.c 1.80 04/03/08
Copyright 1997 J. Schilling').
scsibus1:
1,0,0 100) 'PIONEER ' 'DVD-RW DVR-105 ' '1.30' Removable CD-ROM
1,1,0 101) *
1,2,0 102) *
1,3,0 103) *
1,4,0 104) *
1,5,0 105) *
1,6,0 106) *
1,7,0 107) *
method C: burn command :
# cdrecord -v dev=ATA:1,0,0 driveropts=burnfree -dao mdk100.iso
Schilling's philosophy of naming devices inside cdrecord : dev=b,t,l
====================================================================
To resume my experience, with Schilling's philosophy of naming
devices inside cdrecord :
There are the following backend drivers inside cdrecord :
sg : Generic transport independent SCSI
pg : SCSI transport for ATAPI over Parallel Port
ATA : ATA Packet specific SCSI transport
(device = ATAPI:x,y,z , but seldom used )
ATA : ATA Packet specific SCSI transport using sg interface
(device = ATA:x,y,z , used in almost all Linux PC's )
RSCSI : Remote SCSI
In full :
[jackson:stock]:(~)$ cdrecord dev=help
Cdrecord-Clone 2.01.01a01 (x86_64-unknown-linux-gnu) Copyright (C) 1995-2004
Jörg Schilling
NOTE: this is OSS DVD extensions for cdrtools and thus may have bugs
related to DVD issues that are not present in the original cdrtools. For
more information see http://crashrecovery.org/oss-dvd.html. The original
cdrtools author should not be bothered with problems in this version.
Supported SCSI transports for this platform:
Transport name: sg
Transport descr.: Generic transport independent SCSI
Transp. layer ind.:
Target specifier: bus,target,lun
Target example: 1,2,0
SCSI Bus scanning: supported
Open via UNIX device: not supported
Transport name: pg
Transport descr.: SCSI transport for ATAPI over Parallel Port
Transp. layer ind.:
Target specifier: bus,target,lun
Target example: 1,2,0
SCSI Bus scanning: supported
Open via UNIX device: not supported
Transport name: ATA
Transport descr.: ATA Packet specific SCSI transport
Transp. layer ind.: ATAPI:
Target specifier: bus,target,lun
Target example: ATAPI:1,2,0
SCSI Bus scanning: supported
Open via UNIX device: not supported
Transport name: ATA
Transport descr.: ATA Packet specific SCSI transport using sg interface
Transp. layer ind.: ATA:
Target specifier: bus,target,lun
Target example: 1,2,0
SCSI Bus scanning: supported
Open via UNIX device: not supported
Transport name: RSCSI
Transport descr.: Remote SCSI
Transp. layer ind.: REMOTE:
Target specifier: rscsi@host:bus,target,lun
Target example: REMOTE:rscsi@host:1,2,0
SCSI Bus scanning: supported
Open via UNIX device: not supported
[jackson:stock]:(~)$
In this way cdrecord can query for drives using the SCSI Bus scanning
protocol. First select your backend driver, ie. dev=ATA, and next run
your scan :
[jackson:stock]:(~)$ cdrecord dev=ATA -scanbus
Cdrecord-Clone 2.01.01a01 (x86_64-unknown-linux-gnu) Copyright (C) 1995-2004
Jörg Schilling
NOTE: this is OSS DVD extensions for cdrtools and thus may have bugs
related to DVD issues that are not present in the original cdrtools. For
more information see http://crashrecovery.org/oss-dvd.html. The original
cdrtools author should not be bothered with problems in this version.
scsidev: 'ATA'
devname: 'ATA'
scsibus: -2 target: -2 lun: -2
Linux sg driver version: 3.5.27
Using libscg version 'schily-0.8'.
scsibus0:
0,0,0 0) 'PIONEER ' 'DVD-RW DVR-107D' '1.05' Removable CD-ROM
0,1,0 1) 'PIONEER ' 'DVD-RW DVR-109 ' '1.57' Removable CD-ROM
0,2,0 2) *
0,3,0 3) *
0,4,0 4) *
0,5,0 5) *
0,6,0 6) *
0,7,0 7) *
scsibus1:
1,0,0 100) '_NEC ' 'DVD_RW ND-2510A ' '2.18' Removable CD-ROM
1,1,0 101) '_NEC ' 'DVD_RW ND-3540A ' '1.01' Removable CD-ROM
1,2,0 102) *
1,3,0 103) *
1,4,0 104) *
1,5,0 105) *
1,6,0 106) *
1,7,0 107) *
Schilling's approach to the device naming is inherited from the SCSI
device naming scheme :
[jackson:stock]:(~)$ cat /proc/scsi/scsi
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: ATA Model: ST3120026AS Rev: 3.18
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi1 Channel: 00 Id: 00 Lun: 00
Vendor: ATA Model: ST3120026AS Rev: 3.18
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi2 Channel: 00 Id: 00 Lun: 00
Vendor: ATA Model: ST3200822AS Rev: 3.01
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi3 Channel: 00 Id: 00 Lun: 00
Vendor: ATA Model: ST3200822AS Rev: 3.01
Type: Direct-Access ANSI SCSI revision: 05
[jackson:stock]:(~)$
In the above -scanbus listing we identity :
'_NEC ' 'DVD_RW ND-3540A ' '1.01' Removable CD-ROM = ATA:1,1,0
which means : from the ATA backend driver, we take controller=1
(secondary ide channel) device-ID=1 (slave drive) and lun=0. The lun=0
thing is of course a bogus naming here. But i can live with that. Once
Schilling has translated the communication in a scsi method, he can
blindly attach his libscsi and libscg.
And besides, burners which have a real SCSI backend in hardware, i.e.
using the backend driver dev=sg, still have worked flawless for me
here, without having to worry about Linux kernel versions. The burning
with cdrecord is still, as of today, best implemented using the dev=sg
driver.
In effect, Schilling has made it as its default backend driver. Which
means that dev=sg:0,1,0 is in short default notation, omitting the
default sg backend, written as dev=0,1,0. Which means we use scsi host
scsi0 (i.e. the 1st scsi_hostadapter which is initiated after booting
linux), device-ID=1 and lun=0
Robert M. Stockmann
Last changed Sun Apr 20 23:50:45 CEST 2008