From owner-freebsd-scsi@FreeBSD.ORG Fri Apr 21 09:48:54 2006 Return-Path: X-Original-To: freebsd-scsi@freebsd.org Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ACB2416A401 for ; Fri, 21 Apr 2006 09:48:54 +0000 (UTC) (envelope-from jhs@flat.berklix.net) Received: from thin.berklix.org (thin.berklix.org [194.246.123.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2D17643D46 for ; Fri, 21 Apr 2006 09:48:53 +0000 (GMT) (envelope-from jhs@flat.berklix.net) Received: from js.berklix.net (p549A7571.dip.t-dialin.net [84.154.117.113]) (authenticated bits=128) by thin.berklix.org (8.12.11/8.12.11) with ESMTP id k3L9mole064191; Fri, 21 Apr 2006 11:48:51 +0200 (CEST) (envelope-from jhs@flat.berklix.net) Received: from fire.jhs.private (fire.jhs.private [192.168.91.41]) by js.berklix.net (8.12.11/8.12.11) with ESMTP id k3L9mm3o050898; Fri, 21 Apr 2006 11:48:49 +0200 (CEST) (envelope-from jhs@flat.berklix.net) Received: from fire.jhs.private (localhost.jhs.private [127.0.0.1]) by fire.jhs.private (8.13.1/8.13.1) with ESMTP id k3L9nclw002552; Fri, 21 Apr 2006 11:49:38 +0200 (CEST) (envelope-from jhs@fire.jhs.private) Received: (from jhs@localhost) by fire.jhs.private (8.13.1/8.13.1/Submit) id k3L9nbDu002551; Fri, 21 Apr 2006 11:49:37 +0200 (CEST) (envelope-from jhs) Date: Fri, 21 Apr 2006 11:49:37 +0200 (CEST) Message-Id: <200604210949.k3L9nbDu002551@fire.jhs.private> To: freebsd-scsi@freebsd.org From: "Julian Stacey" Organization: http://berklix.com Munich Unix, BSD, Internet Consultancy Fcc: sent-mail User-agent: EXMH http://beedub.com/exmh/ on FreeBSD http://freebsd.org X-URL: http://berklix.com/~jhs/cv/ Cc: jhs@berklix.com Subject: USB Ram Stick X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Apr 2006 09:48:54 -0000 Hi freebsd-scsi@freebsd.org My new USB, 2 Gig Sony Memory stick seems to have failed. Could I / FreeBSD have screwed the USB device command block ? Or might it be that eg the USB chip works, but the RAM is blown ? Any chance / ideas how to fix it with FreeBSD ? or should I replace it fast ? (I recall that eg real scsi disks can be set to eg 512 or 1K blocks, & then need a reformat, & wondering what else I might try ?) The rest of this mail lists what I did: On FreeBSD-6.0-RELEASE I took a friend's 2G stick containing the usual MBR with one partition allocated as aprox. 2 Gig of DOS file system, & read the entire raw stick onto hard disc. (I still have that image BTW, 2138177536 Apr 3 01:40 sony-stick-da0 , but I dont care about the data, I care about the expensive stick!) I wrote the image back to my identical stick (with dd), it wouldn't continue writing after a while, (cant remember exact message). Now /dev/da0* is just da0 , no other entries. I've tried creating a new MBR with fdisk, but failed. Ive tried creating a raw BSD FS on whole stick, & failed. I've tried copying just the first 512 bytes of the 2G image & failed. /var/log/messages: kernel: (da0:umass-sim0:0:0:0): Cannot read medium - incompatible format kernel: (da0:umass-sim0:0:0:0): Retrying Command (per Sense Data) kernel: (da0:umass-sim0:0:0:0): READ(10). CDB: 28 0 0 0 0 0 0 0 1 0 kernel: (da0:umass-sim0:0:0:0): CAM Status: SCSI Status Error kernel: (da0:umass-sim0:0:0:0): SCSI Status: Check Condition kernel: (da0:umass-sim0:0:0:0): MEDIUM ERROR asc:30,2 camcontrol modepage da0 -l 0x00 Vendor-Specific camcontrol modepage da0 -m 0x00 -b bf 01 f8 43 07 28 80 c0 07 28 00 00 00 00 34 e0 bf bf 19 ba 05 28 eb 8b 04 08 5c 9b ab 07 00 b3 07 28 01 00 00 00 80 c0 07 28 00 b3 07 28 54 e0 bf 01 f8 43 07 28 01 00 00 00 98 86 04 08 b4 e0 bf bf 51 b8 05 28 eb 8b 04 08 5c 9b ab 07 10 30 07 28 88 e0 bf bf 01 00 00 00 8c e0 bf bf 84 e0 bf bf 19 ba 05 28 7f 8c 04 08 00 b0 07 28 00 b1 07 28 00 b2 07 28 00 b3 07 28 00 b1 07 28 00 b1 07 01 6e b7 05 28 00 b3 07 28 3c cb 09 28 04 e1 bf 01 00 b3 07 28 60 e0 bf bf 04 00 00 00 04 00 00 00 d8 e0 bf bf 01 00 00 00 dc e0 bf bf 00 10 00 01 f8 43 07 28 01 00 00 00 98 86 04 08 f4 e0 bf bf 26 9a 05 28 eb 8b 04 08 5c 9b ab 07 00 b0 07 28 e4 e0 bf bf 01 00 00 00 b4 1b 08 28 14 e1 camcontrol format da0 -w You are about to REMOVE ALL DATA from the following device: pass0: Removable Direct Access SCSI-2 device pass0: Serial Number pass0: 1.000MB/s transfers Are you SURE you want to do this? (yes/no) Formatting...Format Complete disklabel -r -w -B /dev/da0 disklabel: /dev/da0 read: Input/output error disklabel -w -r da0 auto usbd -d -v -v usbd: device-attach event at 1145610707.335556000, Flash Disk, Generic: vndr=0x1043 prdct=0x8012 rlse=0x0100 clss=0x0000 subclss=0x0000 prtcl=0x0000 device names: umass0 === match attempt: umass0 usbd: Found action 'jhs Sony 2 gig' for Flash Disk, Generic at umass0 usbd: action 0: jhs Sony 2 gig vndr=0x1043 prdct=0x8012 rlse=0x0100 clss=0x0000 subclss=0x0000 prtcl=0x0000 attach='sleep 2;mount -t msdos /dev/da0s1 /usb/sony' usbd: Setting DEVNAME='umass0' usbd: Executing 'sleep 2;mount -t msdos /dev/da0s1 /usb/sony' mount_msdosfs: /dev/da0s1: No such file or directory usbd: 'sleep 2;mount -t msdos /dev/da0s1 /usb/sony' returned 71 Julian -- Julian Stacey. Consultant Unix Net & Sys. Eng., Munich. http://berklix.com Mail in Ascii, HTML=spam. Ihr Rauch = mein allergischer Kopfschmerz.