Results 1 to 10 of 15
Recently my father got some rather cheap 256MB USB-sticks ... but we never really came to use them since once my father formatted them (old habit) they ceased to work.
...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 01-16-2007 #1Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Corrupted USB stick - recovery of the stick (not the content) possible?
Recently my father got some rather cheap 256MB USB-sticks ... but we never really came to use them since once my father formatted them (old habit) they ceased to work.
The device and its size is correctly recognized under Linux, but no matter what i do nothing is making any difference when i want to use it for files. Some examples of what i have tried:
* Create a new partition table (single primary and mixed pri./extended) => changes just aren't saved or whatever ... the sticks are the same as before.
* Directly formatted the /dev/sdX device with all sorts of filesystems. -> No mounting possible
* "dd"-ed the contend of a similar-sized USB-stick over a corrupt one.
I think i tried some other things as well, but i just couldn't remember then :-/ I'm kinda giving up on figuring out a way to make them work again. Maybe you guys have some tips?
Werner
I've attached some debug output below:
Code:$ parted /dev/sda GNU Parted 1.7.1 Using /dev/sda Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) print Error: Unable to open /dev/sda - unrecognised disk label.
Code:$ fdisk /dev/sda Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only, until you decide to write them. After that, of course, the previous content won't be recoverable. Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): n Command action e extended p primary partition (1-4) e Partition number (1-4): 1 First cylinder (1-1015, default 1): Using default value 1 Last cylinder or +size or +sizeM or +sizeK (1-1015, default 1015): Using default value 1015 Command (m for help): p Disk /dev/sda: 262 MB, 262144000 bytes 9 heads, 56 sectors/track, 1015 cylinders Units = cylinders of 504 * 512 = 258048 bytes Device Boot Start End Blocks Id System /dev/sda1 1 1015 255752 5 Extended Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. Syncing disks. $ fdisk /dev/sda Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only, until you decide to write them. After that, of course, the previous content won't be recoverable. Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help):
Code:$ udevinfo -a -p `udevinfo -q path -n /dev/sda` Udevinfo starts with the device specified by the devpath and then walks up the chain of parent devices. It prints for every device found, all possible attributes in the udev rules key format. A rule to match, can be composed by the attributes of the device and the attributes from one single parent device. looking at device '/block/sda': KERNEL=="sda" SUBSYSTEM=="block" DRIVER=="" ATTR{stat}==" 31 101 622 720 123 0 10395 13036 0 6708 13756" ATTR{size}=="512000" ATTR{removable}=="1" ATTR{range}=="16" ATTR{dev}=="8:0" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1/1-2/1-2:1.0/host4/target4:0:0/4:0:0:0': KERNELS=="4:0:0:0" SUBSYSTEMS=="scsi" DRIVERS=="sd" ATTRS{ioerr_cnt}=="0x3" ATTRS{iodone_cnt}=="0xb4" ATTRS{iorequest_cnt}=="0xb4" ATTRS{iocounterbits}=="32" ATTRS{timeout}=="30" ATTRS{state}=="running" ATTRS{rev}=="2.00" ATTRS{model}=="USB Flash Drive " ATTRS{vendor}=="MSM " ATTRS{scsi_level}=="3" ATTRS{type}=="0" ATTRS{queue_type}=="none" ATTRS{queue_depth}=="1" ATTRS{device_blocked}=="0" ATTRS{max_sectors}=="240" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1/1-2/1-2:1.0/host4/target4:0:0': KERNELS=="target4:0:0" SUBSYSTEMS=="" DRIVERS=="" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1/1-2/1-2:1.0/host4': KERNELS=="host4" SUBSYSTEMS=="" DRIVERS=="" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1/1-2/1-2:1.0': KERNELS=="1-2:1.0" SUBSYSTEMS=="usb" DRIVERS=="usb-storage" ATTRS{modalias}=="usb:v0EA0p2168d0200dc00dsc00dp00ic08isc06ip50" ATTRS{bInterfaceProtocol}=="50" ATTRS{bInterfaceSubClass}=="06" ATTRS{bInterfaceClass}=="08" ATTRS{bNumEndpoints}=="03" ATTRS{bAlternateSetting}==" 0" ATTRS{bInterfaceNumber}=="00" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1/1-2': KERNELS=="1-2" SUBSYSTEMS=="usb" DRIVERS=="usb" ATTRS{configuration}=="" ATTRS{serial}=="64F5423A2566009C" ATTRS{product}=="Flash Disk " ATTRS{manufacturer}=="USB " ATTRS{maxchild}=="0" ATTRS{version}==" 2.00" ATTRS{devnum}=="6" ATTRS{speed}=="12" ATTRS{bMaxPacketSize0}=="64" ATTRS{bNumConfigurations}=="1" ATTRS{bDeviceProtocol}=="00" ATTRS{bDeviceSubClass}=="00" ATTRS{bDeviceClass}=="00" ATTRS{bcdDevice}=="0200" ATTRS{idProduct}=="2168" ATTRS{idVendor}=="0ea0" ATTRS{bMaxPower}=="200mA" ATTRS{bmAttributes}=="80" ATTRS{bConfigurationValue}=="1" ATTRS{bNumInterfaces}==" 1" looking at parent device '/devices/pci0000:00/0000:00:07.4/usb1': KERNELS=="usb1" SUBSYSTEMS=="usb" DRIVERS=="usb" ATTRS{configuration}=="" ATTRS{serial}=="0000:00:07.4" ATTRS{product}=="OHCI Host Controller" ATTRS{manufacturer}=="Linux 2.6.17-1-k7 ohci_hcd" ATTRS{maxchild}=="4" ATTRS{version}==" 1.10" ATTRS{devnum}=="1" ATTRS{speed}=="12" ATTRS{bMaxPacketSize0}=="64" ATTRS{bNumConfigurations}=="1" ATTRS{bDeviceProtocol}=="00" ATTRS{bDeviceSubClass}=="00" ATTRS{bDeviceClass}=="09" ATTRS{bcdDevice}=="0206" ATTRS{idProduct}=="0000" ATTRS{idVendor}=="0000" ATTRS{bMaxPower}==" 0mA" ATTRS{bmAttributes}=="c0" ATTRS{bConfigurationValue}=="1" ATTRS{bNumInterfaces}==" 1" looking at parent device '/devices/pci0000:00/0000:00:07.4': KERNELS=="0000:00:07.4" SUBSYSTEMS=="pci" DRIVERS=="ohci_hcd" ATTRS{modalias}=="pci:v00001022d0000740Csv00000000sd00000000bc0Csc03i10" ATTRS{local_cpus}=="ff" ATTRS{irq}=="9" ATTRS{class}=="0x0c0310" ATTRS{subsystem_device}=="0x0000" ATTRS{subsystem_vendor}=="0x0000" ATTRS{device}=="0x740c" ATTRS{vendor}=="0x1022" looking at parent device '/devices/pci0000:00': KERNELS=="pci0000:00" SUBSYSTEMS=="" DRIVERS==""
- 01-17-2007 #2Linux User
- Join Date
- Jan 2007
- Location
- cleveland
- Posts
- 468
looking at yr fdisk report, what's with this "5"?
/dev/sda1 1 1015 255752 >5< Extended
suggest to try c (fat32 LBA) or 83 (linux): then
either format w/ dos, of mkfs w/ linuxthe sun is new every day (heraclitus)
- 01-17-2007 #3Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Actually it doesn't really matter what type of partition I choose or how many of them i create ... the outcome (bad (or empty) partition table after reboot and/or re-insert of the stick) is the same. So the mkfs.XXX afterwards does not work for /dev/sdaXX since the partition(s) do not exist. And formatting the whole device /dev/sda is no working as well :-/
EDIT: I forgot to mention that in the fdisk example above I tried to create an extended 'e' (thus the number 5 instead of primary 1-4) partition - doing the same with a primary 'p' partition gives the same output.
EDIT2 - Oh BTW: when exactly is the partition table actually written on the stick .. after re-insert of the stick or after a reboot (which i doubt).
I'll re-check this tip nonetheless. Thanks for replying.
My hope is that the sticks are not permanently damaged, but this hope is fading fast
Werner
- 01-17-2007 #4Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Ok, just to get sure i just tried the same thing with a primary partition, but as I mentioned above there is no change.
Has nobody had similar problems yet?
Thanks again,
Werner
Code:$ fdisk /dev/sda Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only, until you decide to write them. After that, of course, the previous content won't be recoverable. Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-1015, default 1): Using default value 1 Last cylinder or +size or +sizeM or +sizeK (1-1015, default 1015): Using default value 1015 Command (m for help): p Disk /dev/sda: 262 MB, 262144000 bytes 9 heads, 56 sectors/track, 1015 cylinders Units = cylinders of 504 * 512 = 258048 bytes Device Boot Start End Blocks Id System /dev/sda1 1 1015 255752 83 Linux Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. Syncing disks. #### Removed and inserted stick #### $ fdisk /dev/sda Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only, until you decide to write them. After that, of course, the previous content won't be recoverable. Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): p Disk /dev/sda: 262 MB, 262144000 bytes 9 heads, 56 sectors/track, 1015 cylinders Units = cylinders of 504 * 512 = 258048 bytes Device Boot Start End Blocks Id System Command (m for help): quit
- 02-08-2007 #5Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Sorry for bumping this thread, but I'm kinda lost ...since I last posted I searched wherever I could and nobody even seem to have a similar problem .. not to mention a solution. So I bump this just one more time before giving up.
Werner
- 02-12-2007 #6Just Joined!
- Join Date
- Nov 2006
- Posts
- 12
I have the same problem! But I know what caused mine. I was trying to use my usb stick to install xbox linux on my xbox. Now the file system in fatx and I don know how to recover the stick.
- 02-13-2007 #7Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
More detail would be nice ... Right now it doesn't need to the same problem, you still might be able to reformat the file system of the stick (partitions or the whole device) with vfat, ext2 or whatever you like. I won't promise it will work, but if you didn't try it yet it might just solve your problem. Use qtparted or gparted if you are not familiar with all those commandline tools.
Originally Posted by bozla
If this works it is in no way similar to my problem btw. except that it is a usb stick as well.
Werner
PS: And if by "recover" you mean the files on the stick this thread is the wrongest place to post it ... you would need to have a fatx enabled kernel(-module) for mounting I think.
- 02-14-2007 #8Just Joined!
- Join Date
- Nov 2006
- Posts
- 12
Originally Posted by Hoehrer
Yeah, your right. I´ve managed to solve it but in a round about way. For some reason, my computer wouldn´t format it (using fdisk or windows) but i managed to reformat it on another windows machine. Go figure?!
- 02-14-2007 #9Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Good to hear you had no bigger problems
Originally Posted by bozla 
Small tip, out of experience ... you could test if the filesystem is faulty (I suspect it isn't in your case, but just in case) by taking some big files, making checksums, copy them on the stick (use as many files as you need to fill the stick), copy them back and make checksums again ... it's not the best way of doing this, but you can quickly see if everything worked out correctly. If there are corrupted files afterwards you can't count on using the stick without losing data.
You could use e.g. "badblocks" or something similar on the device as well just to get sure
Werner
- 12-21-2007 #10Just Joined!
- Join Date
- Jan 2007
- Posts
- 11
Sorry to resurrect this thread, but I finally had some time again to look into my 3 usb sticks and finally pried open one of them ('twas easier and less destructive than I first thought) to have a look at the chips they use.
I've found 2 chips labelled "Hynix HY27UFO81G2" (seems to be a 1Gbit = 128MB chip resulting in an overall of 256MB as stated on the cover of the sticks) and a controller chip OTi OTI002168. At least ow i know these "noname" sticks at least seem to have the correct hardware inside.
Both type of chips seem to be very common, but unfortunately I still can't find a way to make them work :-/
Werner


Reply With Quote
