This site is currently
Under Construction
...soon to be...

OpenBSD Burning a CD-RW

Last updated: 2009-06-31

===

Refer: http://www.openbsd101.com/tipstricks.html#tt15

To create the ISO image files that are being used in the following CD burning examples you will need to have the cdrtools package installed.

So, remotely install the i386 cdrtools package:
# pkg_add -v ftp://ftp.openbsd.org/pub/OpenBSD/4.4/packages/i386/cdrtools-2.01p1.tgz

1st Method

The following method uses the cdio command, which comes with the base installation of OBSD.

What follows is an example of burning the home directories to a CD-RW

* step 1 - Create an ISO image of the information targeted for the CD-RW
* step 2 - Blank the CD-RW disk
* step 3 - Burn the ISO image to the blank CD-RW

1. Next make an ISO image of the home directories:
# mkisofs -v -l -L -r -J -R -o /root/backup.iso /home/

2. Now blank the CD-RW disk:
# cdio blank

3. And finally burn the ISO image to the blank CD-RW:
# cdio tao /root/backup.iso

2nd Method

The following method uses the cdrecord command, which comes with the cdrtools package.

What follows is an example of burning the home directories to a CD-RW

* step 1 - Create an ISO image of the information targeted for the CD-RW
* step 2 - Blank the CD-RW disk
* step 3 - Burn the ISO image to the blank CD-RW

1. Next make an ISO image of the home directories:
# mkisofs -v -l -L -r -J -R -o /root/backup.iso /home/

2. Now blank the CD-RW disk:
# cdrecord -blank fast dev=/dev/cd0c

3. And finally burn the ISO image to the blank CD-RW:
# cdrecord -v dev=/dev/cd0c /root/backup.iso

How to figure out what device node is associated to the CD burner

I have a Memorex CD burner, so I will search dmesg output to see if the kernel has recognized my burner and to find out what device node the burner has been associated to.

Greping dmesg output:

# dmesg | grep Memorex
cd0 at scsibus0 targ 0 lun 0: <Memorex, 48MAX 244816AJ, KWH8> SCSI0 5/cdrom removable

From the dmesg output you can see that the device node cd0 has been associated to the Memorex burner.

Mounting the CD burner

* step 1 - Create a CD-ROM directory
* step 2 - Mount the CD filesystem

1. Create a CD-ROM directory:
# mkdir /mnt/cdrom

2. Mounting the CD filesystem:
# mount /dev/cd0c /mnt/cdrom/