LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 01-28-2011, 04:33 PM   #1
babagau
LQ Newbie
 
Registered: Jun 2010
Location: Volos, Greece
Distribution: Puredyne
Posts: 15

Rep: Reputation: 0
external usb drive superblock issue


The usb hard-drive (has one fat32 partition) was recognized properly in Linux last time and so is in windoseXP, I also did chkdsk with auto-fix bad sectors enabled and returned no errors. but now in Linux:

(~) % dmesg |tail
[ 25.125169] scsi4 : SCSI emulation for USB Mass Storage devices
[ 25.135685] usbcore: registered new interface driver usb-storage
[ 25.135695] USB Mass Storage support registered.
[ 25.136157] usb-storage: device found at 3
[ 25.136161] usb-storage: waiting for device to settle before scanning
[ 30.137407] usb-storage: device scan complete
[ 30.138742] scsi 4:0:0:0: Direct-Access USB TO I DE/SATA Device 0009 PQ: 0 ANSI: 0
[ 30.142406] sd 4:0:0:0: Attached scsi generic sg3 type 0
[ 30.151039] sd 4:0:0:0: [sdc] Attached SCSI disk
[ 134.861724] FAT: unable to read boot sector

(~) % sudo mount -t vfat /dev/sdc /mnt/external
mount: /dev/sdc: can't read superblock

(~) % fsck.vfat /dev/sdc
dosfsck 3.0.3, 18 May 2009, FAT32, LFN
Got 0 bytes instead of 512 at 0

(~) % sudo badblocks /dev/sdc
badblocks: invalid starting block (0): must be less than 0

(~) % fdisk -l /dev/sdc prints nothing

Testdisk utility will also not list the partition at all. Please note that in /dev there is only /dev/sdc no sdc1 or anything. Anyway to mount the partition without formatting it and losing the data? Can I somehow use dd or mkfs.vfat, affecting only the superblock? In the end I will burn them to dvd in windoze, what can I do?

Last edited by babagau; 01-28-2011 at 04:37 PM.
 
Old 01-29-2011, 09:26 AM   #2
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,267

Rep: Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540
I don't think it recognized it. Look at this one

Quote:
usb 1-1: new high speed USB device using ehci_hcd and address 4
usb 1-1: New USB device found, idVendor=0951, idProduct=1607
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: DataTraveler 2.0
usb 1-1: Manufacturer: Kingston
usb 1-1: SerialNumber: 001372982A06A921B6420241
Initializing USB Mass Storage driver...
scsi2 : usb-storage 1-1:1.0
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
scsi 2:0:0:0: Direct-Access Kingston DataTraveler 2.0 1.00 PQ: 0 ANSI: 2
sd 2:0:0:0: Attached scsi generic sg1 type 0
sd 2:0:0:0: [sdb] 15695872 512-byte logical blocks: (8.03 GB/7.48 GiB)
sd 2:0:0:0: [sdb] Write Protect is off
sd 2:0:0:0: [sdb] Mode Sense: 23 00 00 00
sd 2:0:0:0: [sdb] Assuming drive cache: write through
sd 2:0:0:0: [sdb] Assuming drive cache: write through
sdb: sdb1
sd 2:0:0:0: [sdb] Assuming drive cache: write through
sd 2:0:0:0: [sdb] Attached SCSI removable disk

See this 'sdb: sdb1' line? That's where it recognizes a partition. Only then can I mount sdb1. Try plugging it in, let it settle and run

dmesg |tail -n 30

Last edited by business_kid; 01-29-2011 at 09:27 AM.
 
1 members found this post helpful.
Old 01-31-2011, 04:19 PM   #3
babagau
LQ Newbie
 
Registered: Jun 2010
Location: Volos, Greece
Distribution: Puredyne
Posts: 15

Original Poster
Rep: Reputation: 0
ah, indeed, you are right, it only recognized the device (sdc), not the partition, which would have been sdc1.

(edit: or so I thought! With my oggplayer,
dmesg | tail
[15239.498733] sd 4:0:0:0: Attached scsi generic sg3 type 0
[15239.500783] sd 4:0:0:0: [sdc] 7683072 512-byte logical blocks: (3.93 GB/3.66 GiB)
[15239.501659] sd 4:0:0:0: [sdc] Write Protect is off
[15239.501670] sd 4:0:0:0: [sdc] Mode Sense: 04 00 00 00
[15239.501675] sd 4:0:0:0: [sdc] Assuming drive cache: write through
[15239.510848] sd 4:0:0:0: [sdc] Assuming drive cache: write through
[15239.510865] sdc:

So a partition can also be just sdx when there is only one partition in a device.
I'll have a look at this article when I have time. http://www.linuxjournal.com/article/8366

thanks a lot!

Last edited by babagau; 01-31-2011 at 05:37 PM. Reason: learned sth more
 
Old 02-06-2011, 07:06 PM   #4
babagau
LQ Newbie
 
Registered: Jun 2010
Location: Volos, Greece
Distribution: Puredyne
Posts: 15

Original Poster
Rep: Reputation: 0
now for some reason, there is nothing in dmesg. I plug the device in and nothing happens. I have no idea what changed since then. I have hotplug and sd_mod built in the kernel and there are noumerous CONFIG_SCSI =m =y in /boot/config-2.6.31-9-rt whereas my oggplayer is recognised fine with just a "locale utf8 case sensitive filesystem" warning that doesn't seem to be a problem. But the oggplayer isn't recognized in other ubuntu and windoze (only the folders are displayed, not contents). I keep on the problems.
 
Old 02-07-2011, 02:33 AM   #5
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,267

Rep: Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540
Yes, a partition can be the whole usb drive. AFAIK only windows does that.
sdc:
I would read that line this way - that there may be an sdc partition, or there may be sdc with no partitions.

Can you access it?
 
Old 02-08-2011, 06:43 PM   #6
babagau
LQ Newbie
 
Registered: Jun 2010
Location: Volos, Greece
Distribution: Puredyne
Posts: 15

Original Poster
Rep: Reputation: 0
I can access my oggplayer, but my usb-drive not yet. However, in my old puppy linux pc, the usb-drive is mounted apart from sometimes when the device appears in dmesg, but the node /dev/sd* isn't created. In that case, I reconnect the device and it is mounted. The relevant(?) modules loaded in puppy pc are usbhid usb-storage uhci-hcd and usbcore. In my main pc, running puredyne (a multimedia production distro based on xubuntu9.10) the modules loaded are fat, vfat, usbhid, usb-storage, whereas usbcore, sd_mod, hotplug and uhci_hcd are built in the kernel (2.6.31-9) and it keeps not appearing in dmesg (of course the cable is connected and the dev lit). It should be a matter of modules, don't you think so? Update, by modprobing nls_iso558859-1 and nls_utf8 (maybe not needed) the device appears in dmesg and I am back where I started... I plan to check which modules are loaded in puppy pc, nls and usb relevant and probe them at puredyne.

Last edited by babagau; 02-08-2011 at 07:33 PM. Reason: i was wrong / updates
 
Old 02-09-2011, 03:13 AM   #7
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,267

Rep: Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540
Try it somewhere else, or try another drive in your box. I had puredyne here somewhwere but it didn't have a usb problem that I remember.
 
Old 02-13-2011, 04:09 AM   #8
babagau
LQ Newbie
 
Registered: Jun 2010
Location: Volos, Greece
Distribution: Puredyne
Posts: 15

Original Poster
Rep: Reputation: 0
The difference with the old puppy linux pc is that it "finds" the usb drive with uhci_hcd (usb 1.0) loaded as module, (not built in kernel), whereas in the puredyne pc it's with ehci_hcd (usb2.0). I booted from puppy live cd in the puredyne pc and still the device isn't detected. Both modules uhci-hcd and ehci-hcd were loaded. I rmmmod ehci-hcd and reconnected device, still didn' t help. Anyway...
 
Old 02-14-2011, 02:50 AM   #9
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,267

Rep: Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540Reputation: 540
put this line into a file /etc/modprobe.d/usb.conf

install uhci-hdc /sbin/modprobe ehci-hcd; /sbin/modprobe uhci-hcd

THEN try it
 
  


Reply

Tags
invalid, superblock, usb


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
usb external HD issue: reset high speed USB device using ehci_hcd gstath Slackware 4 08-18-2010 01:35 AM
USB drive bad superblock dtmbmw325i Linux - Hardware 7 09-20-2009 09:51 AM
FreeBSD7 - USB Drive with important data: Bad Superblock rautamiekka *BSD 7 07-05-2008 12:51 PM
weird issue with a 500GB USB external drive cyberpuerka Linux - Hardware 6 05-11-2005 11:08 AM
bad superblock when trying to mount a USB hard drive shubb Linux - Hardware 4 04-29-2005 12:00 AM


All times are GMT -5. The time now is 01:36 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration