LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   USB 4gig drive (https://www.linuxquestions.org/questions/linux-newbie-8/usb-4gig-drive-604499/)

Taysider 12-04-2007 03:16 PM

USB 4gig drive
 
I know i should have unmounted it first but....being fairly new i forgot and just pulled it out, now my 4gig shows 8meg!
I ran dmesg and it sees both 4gig and 8meg but does not come up on desktop. I even put it in my friends Xp to try to format it but it can't, although i can see and open it in explorer.
I've tried to mount it ...no luck.
Any ideas before i throw it in the bin and put it down to the learning curve.

pljvaldez 12-04-2007 03:24 PM

Try using testdisk to fix the partition table. Beyond that, I'd try shredding the drive (shred -f -n=1 /dev/sdxx -- of course use the right device -- shred will overwrite the data block by block). Then try to reformat it with GParted or fdisk.

Taysider 12-04-2007 03:34 PM

Hi pljvaldez,

Tried the testdisk...no luck only seeing 8mg
shred coming up with the following

shred: =1: invalid number of passes

Dave.

pljvaldez 12-04-2007 03:40 PM

Sorry, it should be shred -f -n 1 /dev/sdxx without the equal sign.

As for testdisk, did you run through trying to recover the partition table?

Taysider 12-04-2007 04:10 PM

pljvaldez

testdrive coming back with:
Disk /dev/sdf - 8388 KB / 8192 KiB - CHS 1024 1 16
Analyse cylinder 6/1023: 00%

and shred saying
shred: /dev/sdf: fdatasync failed: Input/output error

pljvaldez 12-04-2007 04:19 PM

Hmmm. You can try dd directly. dd if=/dev/zero of=/dev/sdf bs=512 count=1 which should overwrite the drive with zeros.

You can also try using dosfsck -a /dev/sdf. It's a bit like running scandisk on the drive.

jesseruu 12-04-2007 11:28 PM

hi,

Thats what i think could have happend to my USB,
it used to be 1 gig now it under 50 mb.
I can not remember ever unmounting it : (


All times are GMT -5. The time now is 10:28 PM.