From owner-freebsd-questions@FreeBSD.ORG Thu Mar 26 22:22:46 2009 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 0C00F106566C for ; Thu, 26 Mar 2009 22:22:46 +0000 (UTC) (envelope-from bruce@cran.org.uk) Received: from muon.cran.org.uk (brucec-1-pt.tunnel.tserv4.nyc4.ipv6.he.net [IPv6:2001:470:1f06:c09::2]) by mx1.freebsd.org (Postfix) with ESMTP id CF94C8FC1A for ; Thu, 26 Mar 2009 22:22:45 +0000 (UTC) (envelope-from bruce@cran.org.uk) Received: from muon.cran.org.uk (localhost [127.0.0.1]) by muon.cran.org.uk (Postfix) with ESMTP id 2832719017; Thu, 26 Mar 2009 22:22:44 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on muon X-Spam-Level: X-Spam-Status: No, score=-2.6 required=8.0 tests=AWL,BAYES_00,NO_RELAYS autolearn=ham version=3.2.5 Received: from gluon.draftnet (unknown [IPv6:2a01:348:10f:0:240:f4ff:fe57:9871]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by muon.cran.org.uk (Postfix) with ESMTPSA; Thu, 26 Mar 2009 22:22:43 +0000 (GMT) Date: Thu, 26 Mar 2009 22:15:12 +0000 From: Bruce Cran To: Robert Huff Message-ID: <20090326221512.63b20c9f@gluon.draftnet> In-Reply-To: <18891.65290.334463.362126@jerusalem.litteratus.org> References: <20090326212045.GB3134@sushi.pseudo.local> <4ad871310903261456g2924d8cai6569e4cd739c1c49@mail.gmail.com> <18891.65290.334463.362126@jerusalem.litteratus.org> X-Mailer: Claws Mail 3.7.1 (GTK+ 2.14.7; i386-portbld-freebsd7.2) Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Glen Barber , freebsd-questions@freebsd.org Subject: Re: [perl] sysopen(CD, "/dev/cd0", O_RDONLY | O_NONBLOCK) fails 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: Thu, 26 Mar 2009 22:22:46 -0000 On Thu, 26 Mar 2009 18:17:46 -0400 Robert Huff wrote: >=20 > Glen Barber writes: >=20 > > > I have a perl script which seems to work fine under Linux but > > > fails on FreeBSD. The Problem is the line: > > > > > > =A0 =A0 =A0 =A0sysopen(CD, "/dev/cd0", O_RDONLY | O_NONBLOCK) > > > > > > After this line the following evaluates to true: > > > > > > =A0 =A0 =A0 =A0$! eq "No such file or directory." > > > > > =20 > > I may be wrong, but shouldn't that be '/dev/acd0' ? >=20 > /dev/cd0 =3D SCSI CD-ROM (and maybe other stuff). >=20 > I don't know if that's what the OP has, but it is a possible > value. cd0 is also what you get if you use atapicam (ATAPI is SCSI over ATA from what I remember) - for example cdrecord has traditionally used it when writing CDs. Apparently the OP has the issue both when using atapicam (/dev/cd0) and the normal ata node /dev/acd0. --=20 Bruce Cran