From owner-freebsd-questions@FreeBSD.ORG Sat Jan 7 05:17:54 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 51CA816A41F for ; Sat, 7 Jan 2006 05:17:54 +0000 (GMT) (envelope-from teilhk@crosswinds.net) Received: from cwpro1.crosswinds.net (cwpro1.crosswinds.net [69.28.227.134]) by mx1.FreeBSD.org (Postfix) with ESMTP id C7EEB43D45 for ; Sat, 7 Jan 2006 05:17:53 +0000 (GMT) (envelope-from teilhk@crosswinds.net) Received: from [201.127.10.40] (helo=fortunato) by cwpro1.crosswinds.net with smtp (Exim 4.60 (FreeBSD)) (envelope-from ) id 1Ev6Se-000IxX-Cz for freebsd-questions@freebsd.org; Sat, 07 Jan 2006 00:17:52 -0500 Message-ID: <009601c61349$b2fd4180$210110ac@fortunato> From: "Teilhard Knight" To: "FreeBDS" References: <00fd01c6123e$eb4110a0$210110ac@fortunato> <20060105221957.GA1050@flame.pc> <000c01c61287$718563d0$210110ac@fortunato> <20060106121246.GA1056@flame.pc> Date: Fri, 6 Jan 2006 23:17:47 -0600 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - cwpro1.crosswinds.net X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [0 0] / [26 6] X-AntiAbuse: Sender Address Domain - crosswinds.net X-Source: X-Source-Args: X-Source-Dir: Subject: Re: Flash Disk 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: Sat, 07 Jan 2006 05:17:54 -0000 > Hi, > > Please don't remote the list from the recipients of the message, unless > the reply contains confidential material that you don't wish to disclose > to all the subscribers of the list. By keeping the list, you ensure > that other subscribers may reply too in case I'm wrong about something, > and you make it possible for future readers who find the thread in the > archives to read all the relevant material. I am aware of the importance that the discussions take place in the list. It, I confess, happens with my newsreader that if I just hit: "reply", the address entered in the reply is the sender's address, and I have sent many messages that way for not correcting it. But invariably I have realized the mistake and copy and paste my reply to the list again. So, in that case the person I am replying to receives two messages, one in the list and one private. I have no account of having replied only to the recipient. > On 2006-01-06 00:07, Teilhard Knight wrote: >>> When I plug my USB JetFlash disk, the following appears in >>> /var/log/messages (and the system console, but I mostly use X11 >>> these days): >>> >>> umass0: USB Flash Disk, rev 2.00/2.00, addr 2 >>> da0 at umass-sim0 bus 0 target 0 lun 0 >>> da0: Removable Direct Access SCSI-2 device >>> da0: 1.000MB/s transfers >>> da0: 250MB (512000 512 byte sectors: 64H 32S/T 250C) >> >> I get something similar too. The Device Node is created all right. > > Cool! :o) >>> When you plug the USB flash disk in, /dev/da0 (or another daX >>> device) is automatically created. If the flash disk already has >>> partitions (they usually come with a single FAT partition), >>> you'll also see da0s1 or something similar: >>> >>> # ls -l /dev/da* >>> crw-r----- 1 root operator - 4, 44 Oct 16 17:38 /dev/da0 >> >> Yes, I also get something similar to this. > > That's nice. It means that the kernel has recognized the flash disk as > a "block device" and the CAM layer of the kernel has created a 'direct > access' disk device for it -- much like it does for SCSI disks. :o) >>> If you see only da0, it's possible that the 'raw disk' is >>> formatted using FAT, without a real BIOS-style partition, which >>> means that you should be able to 'mount' it with something like: >>> >>> # /sbin/mount_msdosfs /dev/da0 /mnt >> >> I do not only see da0 above and this command results in: "mount_msdosfs: >> /dev/da0: Invalid argument" > > The flash disk is not formatted, so you'll have to create a filesystem > on it. I did this for mine, using fdisk(8) and bsdlabel(8), as > described in the following post of my old weblog: > > > http://keramida.serverhive.com/weblog/archives/2004-10-16/using-a-usb-20-flash-mini-disk-on-freebsd The disk was formatted all right. The problem I had is that I was trying to mount /dev/da0, instead of /dev/da0s1. > Enabling USB 2.X will also increase the access speed of the flash disk a > lot, so you may want to read this too: > > > http://keramida.serverhive.com/weblog/archives/2005-06-23/usb-2x-support-in-freebsd I only have USB 2.0 in my computer. Actually I would like to have at least one port 1.1 for some old devices. >> You told me how to mount my flash disk in case the command "ls -l >> /dev/da0" results incomplete or I have the disk raw formatted. But >> what should I do if I get all similar to what you get? In other words, >> how do you mount your flash disk? > > If you successfully mount the disk once, using the mount(8) and the > related utilities (mount_msdosfs, etc), then you can add a line in your > ``/etc/fstab'' file to make things easier the next time. My USB disk > doesn't have slices these days (just a UFS filesystem on it) so the > relevant line from fstab is: > > /dev/da1a /mnt/jflash ufs rw,noauto,noexec,nosuid 0 0 Yes, I have written a line similar to this in /etc/fstab, and I now just hit: "mount /mnt/Ant". Ant is the label of my flash disk. I very much appreciate your feedback. Teilhard.