Print View

Making Your IDE CD Burner Work On FreeBSD
Created: 06/15/2005


General Information

Many people using or wanting to use FreeBSD are not clued on to the fact that, by default, CD burning does not work on either 4.x or 5.x.  This tutorial was designed to help users get their IDE CD Writing devices working under FreeBSD 5.

Requirements

  1. IDE CD Writer
  2. FreeBSD 5.x
  3. Root Access
  4. Sources Installed
First off, please make sure your bios is detecting your CD-RW.  This is very important to know.  If it shows up, you can proceed.  Under FreeBSD, CD Writers use SCSI interface modules much like the SCSI emulation in Linux was back before 2.6.  Generally the SCSI emulated method has better failsafe ability, so this is not a bad thing for FreeBSD to still be using.  The drawback is the standard kernel is missing a module which is necessary to use the device.  The generic configs also lack this line.

Now that you are booted into your BSD box, please login as root.
#
#
#
cd /usr/src/sys/i386/conf
cp GENERIC HOSTNAME
nano -w HOSTNAME
Under SCSI peripherals, make sure the following matches:
device          scbus           # SCSI bus (required for SCSI)
device          ch              # SCSI media changers
device          da              # Direct Access (disks)
device          sa              # Sequential Access (tape etc)
device          cd              # CD
device          pass            # Passthrough device (direct SCSI access)
device          ses             # SCSI Environmental Services (and SAF-TE)
device          atapicam
Save the file and exit.
# nano -w /etc/devfs.conf
Add the following:
perm    acd0    0666
link    acd0    cdrom
perm    pass0   0666
perm    cd0     0666
perm    xpt0    0666

# nano -w /etc/rc.conf
Add the following to the bottom:
devd_enable="YES"

#
#
#
#
#
#
cd /usr/ports/sysutils/cdrdao
make
make install
make clean
cd /usr/local/bin
chmod u+s cdrdao
I recommend using k3b for burning, it's easy to use and efficient.
#
#
#
#
cd /usr/ports/sysutils/k3b
make
make install
make clean
You're done.  Reboot and start k3b, it should ask you how fast your writer is and you should be able to burn cd's.

Author: James Cornell
unixpenguin2004 at earthlink dot net



9 Comments

Posted by rhyous on September 21, 2005 at 2:04:09 pm EEST

I appreciate all guides.  I am not complaining about this guide, but I want to mention that my IDE Burner works by default in 5.x (I started with 5.0 and am on 5-Stable) with a base install simply using burncd.


Posted by francisco on September 21, 2005 at 2:04:09 pm EEST

I agree with rhyous.
The guide would be much more helpfull if it mentioned that programs that use SCSI or SCSI layers don't work by default.. I have always been able to burn CDs with burncd.


Posted by unixpenguin2004 on September 21, 2005 at 2:04:09 pm EEST

Hello.  My 40x IDE didn't work by default.  It might have been devd permissions for regular users that might had fixed it, and maybe doing all this wasn't necessary.  It might help those with 4.x though.


Posted by ecksii on September 21, 2005 at 2:04:09 pm EEST

Good article. My comment is just an FYI. ATAPI CD-RW drives are supported through the burncd command (man burncd for more information) This works on both 4.x and 5.x. DVD Drives will burn CD-R and CD-RW with burncd but to burn a DVD you need the SCSI subsytem as described in this article. Also many Linux programs for burning CD's are really just front ends for command line SCSI CD-Burning tools. If you want to use one of these, and k3b is one of them, you also require the scsi CD subsystem.


Posted by Rotaman on September 21, 2005 at 2:04:09 pm EEST

Hi. I've tried the above steps. K3b still does not recognize my cd/dvd drive.. I'm using a HP DV1139 laptop,  and am completely new to freebsd...


Posted by gunhed on August 18, 2006 at 1:16:11 pm EEST

Really a good article, but one point is missing. It's the "devfs.conf" thing:
You must check which "pass" your cd-writer uses -> "camcontrol devlist" and double-check if it's really pass0 (mine is on pass2).
If you add the corresponding "pass" argument to your devfs.conf you're set after reboot. For immediate access use "chmod 0666 /dev/passX" where X is your pass-number (and of course the other devices mentioned in devfs.conf).
After _that_ k3b should ask you (as normal user, not only as root) for the speed of your cd-writer.
-> referring to FreeBSD6.1 installation


Posted by mk2 on October 08, 2006 at 12:12:29 am EEST

After following ALL advice above, I have to add in
/boot/loader.conf the line :

atapicam_load="YES"

Save, Reboot, and k3b on my box is OK!

I try :
dhcppc0# cdrecord -scanbus
Cdrecord-Clone 2.01 (i386-unknown-freebsd6.1) Copyright (C) 1995-2004 Jörg Schilling
Using libscg version 'schily-0.8'.
scsibus0:
        0,0,0     0) *
        0,1,0     1) 'DVDRW   ' 'IDE 16X         ' 'A07F' 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) *

(My box is an Intel P4 2GHz 512M RAM. FreeBSD-6.1)


Posted by rhyous on March 08, 2007 at 5:32:59 am EET

Who thinks we should throw this in it's own guide or just update this one?

I just built a new computer and followed the info here to get my devices detected in k3b:

1. I have to add this line to /boot/loader.conf:

atapicam_load="YES"

2. Then I use the following /etc/devfs.conf file:

# Commonly used by many ports
link    acd0    cdrom
link    acd1    cdrom1

# Set permission needed for k3b
perm    pass0   0660
perm    pass1   0660
perm    acd0    0660
perm    acd1    0660
perm    cd0     0660
perm    cd1     0660
perm    cdrom   0660
perm    cdrom1  0660
perm    xpt0    0660


3. Add the user to the operators group.

pw user mod myusername -G wheel,operator

4. Reboot

Device should now be seen and have read write permissions as the user in k3b.


Posted by Saigon.Zogg on April 14, 2008 at 7:42:00 am EEST

<Freebsd 6.3>

Well. . . cdrecord reports 1,1,0. And camcontrol reports pass0,cd0. However, dmesg reports the following:

acd0: FAILURE - INQUIRY ILLEGAL REQUEST asc=0x24 ascq=0x00
acd0: FAILURE - READ_BIG ILLEGAL REQUEST asc=0x64 ascq=0x00
(cd0:ata1:0:1:0): READ(10). CDB: 28 0 0 0 0 0 0 0 2 0
(cd0:ata1:0:1:0): CAM Status: SCSI Status Error
(cd0:ata1:0:1:0): SCSI Status: Check Condition
(cd0:ata1:0:1:0): ILLEGAL REQUEST asc:64,0
(cd0:ata1:0:1:0): Illegal mode for this track
(cd0:ata1:0:1:0): Unretryable error
(cd0:ata1:0:1:0): cddone: got error 0x6 back

It's an older PlexWriter CDRW (PX-W2410A). I've used it before on Freebsd 4.11 & 5.3 with great success. Any ideas?

-Thanks :-)


Copyright 2003 - 2008 BSD Guides.  All rights reserved.

About | Terms of Use | Privacy | Contact