From owner-freebsd-geom@FreeBSD.ORG Thu May 22 20:09:11 2008 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 277EF10656B3 for ; Thu, 22 May 2008 20:09:11 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 023828FC1D for ; Thu, 22 May 2008 20:09:10 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 3FCB21A92DC; Thu, 22 May 2008 12:51:39 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id pVDIvkhBrsJZ; Thu, 22 May 2008 12:51:38 -0700 (PDT) Received: from iago.office.miralink.com (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id E44CE1A92D9; Thu, 22 May 2008 12:51:38 -0700 (PDT) Message-ID: <4835CED9.8090901@miralink.com> Date: Thu, 22 May 2008 12:51:53 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.14 (X11/20080501) MIME-Version: 1.0 To: Marauder References: <48357420.5689.0089.0@pi.avalonnetworks.us> In-Reply-To: <48357420.5689.0089.0@pi.avalonnetworks.us> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-geom@freebsd.org Subject: Re: Unable to write to drive X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 May 2008 20:09:11 -0000 Marauder wrote: > Hi all, > > I have a problem that is driving me crazy. Hopefully I'm submitting this question to the correct place. > > My problem is... I have opened the drive /dev/ad0 with open("/dev/ad0", O_WRONLY) and it return's a valid file descriptor. The I attempt to write using the file descriptor returned. The write fails with errno=22 (EINVAL) > > I have attempted to first open /dev/io with READ/WRITE access to see if that help's. No luck > I have attempted to lock the section of the drive I would like to write to with lockf. No luck > > If anybody has any idea's or suggestions I would greatly appreciate them. > > Thanx > > > _______________________________________________ > freebsd-geom@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-geom > To unsubscribe, send any mail to "freebsd-geom-unsubscribe@freebsd.org" > Is the disk /dev/ad0 in any kind of geom based device? That would keep you from writing I think. Also, have you tried "O_RDWR" as well? -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199