From owner-freebsd-questions@FreeBSD.ORG Sun Mar 14 09:08:57 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75FF0106566B for ; Sun, 14 Mar 2010 09:08:57 +0000 (UTC) (envelope-from rsmith@xs4all.nl) Received: from smtp-vbr13.xs4all.nl (smtp-vbr13.xs4all.nl [194.109.24.33]) by mx1.freebsd.org (Postfix) with ESMTP id 094078FC0A for ; Sun, 14 Mar 2010 09:08:56 +0000 (UTC) Received: from slackbox.erewhon.net (slackbox.xs4all.nl [213.84.242.160]) by smtp-vbr13.xs4all.nl (8.13.8/8.13.8) with ESMTP id o2E98nUT099797; Sun, 14 Mar 2010 10:08:51 +0100 (CET) (envelope-from rsmith@xs4all.nl) Received: by slackbox.erewhon.net (Postfix, from userid 1001) id AC004BAA9; Sun, 14 Mar 2010 10:08:48 +0100 (CET) Date: Sun, 14 Mar 2010 10:08:48 +0100 From: Roland Smith To: Aiza Message-ID: <20100314090848.GA9037@slackbox.erewhon.net> References: <4B9C3DFB.7010307@comclark.com> <4B9C5C57.6060800@comclark.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5vNYLRcllDrimb99" Content-Disposition: inline In-Reply-To: <4B9C5C57.6060800@comclark.com> X-GPG-Fingerprint: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 X-GPG-Key: http://www.xs4all.nl/~rsmith/pubkey.txt X-GPG-Notice: If this message is not signed, don't assume I sent it! User-Agent: Mutt/1.5.20 (2009-06-14) X-Virus-Scanned: by XS4ALL Virus Scanner Cc: FreeBSD Questions Subject: Re: how to use cdrecord X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Mar 2010 09:08:57 -0000 --5vNYLRcllDrimb99 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Mar 14, 2010 at 11:47:35AM +0800, Aiza wrote: > Chris Hill wrote: > > On Sun, 14 Mar 2010, Aiza wrote: > >=20 > > [snip] > >> tried cdrecord -v speed=3D2 dev=3Dacd0 blank=3Dfast > >> gives this error "Open by devname not supported on this OS. > >> > >> What device am i to use? > >=20 > > cdrecord wants to see your ATA burner as a SCSI device, so you'd use > > cdrecord dev=3D1,0,0 ... > > The numbers after dev=3D depend on where your burner is; find it using > > cdrecord -scanbus > >=20 > > HTH. > >=20 > cdrecord -scanbus gives a error. Invalid argument. Camiocommand ioctl=20 > failed, can not open scsi driver You need SCSI emulation for your burner in your kernel. Specifically, you n= eed to recompile your kernel with the following devices in its configuration fi= le: device atapicam # emulate ATAPI devices as SCSI ditto v= ia 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 acces= s) 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 alwa= ys build a custom kernel, so I don't know about that. The manual pages don't s= ay 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 t= he 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 t= he # 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/d= evfs.rules: [slackbox=3D10] add path 'pass*' mode 0660 group cdrom And in /etc/rc.conf the following is added; devfs_system_ruleset=3D"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 --=20 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) --5vNYLRcllDrimb99 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkucp6AACgkQEnfvsMMhpyW+tgCfQTVW5VLqI636SJ0TPQlySzJ8 KHMAoKBVAfA1GV+KNEt+xOtDn7lw6XGM =fUY8 -----END PGP SIGNATURE----- --5vNYLRcllDrimb99--