how to use cdrecord
Roland Smith
rsmith at xs4all.nl
Sun Mar 14 09:08:57 UTC 2010
On Sun, Mar 14, 2010 at 11:47:35AM +0800, Aiza wrote:
> Chris Hill wrote:
> > On Sun, 14 Mar 2010, Aiza wrote:
> >
> > [snip]
> >> tried cdrecord -v speed=2 dev=acd0 blank=fast
> >> gives this error "Open by devname not supported on this OS.
> >>
> >> What device am i to use?
> >
> > cdrecord wants to see your ATA burner as a SCSI device, so you'd use
> > cdrecord dev=1,0,0 ...
> > The numbers after dev= depend on where your burner is; find it using
> > cdrecord -scanbus
> >
> > HTH.
> >
> cdrecord -scanbus gives a error. Invalid argument. Camiocommand ioctl
> failed, can not open scsi driver
You need SCSI emulation for your burner in your kernel. Specifically, you need
to recompile your kernel with the following devices in its configuration file:
device atapicam # emulate ATAPI devices as SCSI ditto via CAM
# needs CAM to be present (scbus & pass)
# SCSI peripherals
device scbus # SCSI bus (required for SCSI)
device da # Direct Access (disks)
device cd # CD
device pass # Passthrough device (direct SCSI access)
See the manual pages atapicam(4), scbus(4), cd(4) and pass(4).
It could be that these devices are also available as modules, but I've always
build a custom kernel, so I don't know about that. The manual pages don't say
that they are available as modules, so I'm inclined to say they are not.
After rebuilding the kernel, which you'll find documented in Chapter 8 of the
Handbook, you also need to give your user-id write access to the right
devices. I have done that by creating a group "cdrom", to which I've added my
user-id (with 'pw groupmod -m'). Then I've put the following lines in my
/etc/devfs.conf:
# Give members of group cdrom access to the CD/DVD-ROM and DVD+RW via the
# SCSI interface
own xpt0 root:cdrom
perm xpt0 0660
own cd0 root:cdrom
perm cd0 0660
own cd1 root:cdrom
perm cd1 0660
link cd1 cdrom
link cd1 dvd
Since I've got both a burner and a regular DVD player in my machine, you see
two cd devices but only one xpt device.
Additionally, the following has been added to my standard ruleset in /etc/devfs.rules:
[slackbox=10]
add path 'pass*' mode 0660 group cdrom
And in /etc/rc.conf the following is added;
devfs_system_ruleset="slackbox"
I've put the pass device in devfs.rules because it will attach to every SCSI
device that attaches to the system, _even if they are added after booting_
like e.g. USB disks used with the da(4) driver.
Hope this helps.
Roland
--
R.F.Smith http://www.xs4all.nl/~rsmith/
[plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated]
pgp: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 (KeyID: C321A725)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20100314/18628dc3/attachment.pgp
More information about the freebsd-questions
mailing list