LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-12-2005, 07:30 PM   #1
Garibaldi3489
Member
 
Registered: Oct 2004
Posts: 172

Rep: Reputation: 30
Flash Drive Problems


I have my Lexar USB Flash drive in fstab as:
/dev/sdb1 /mnt/usb vfat users,defaults,noauto 0 0
But the only time I can access it is when I have it in when I boot. Why is that? If I try just popping it in later once i have loaded linux already or using another flash drive it gives me this error:
root@Pavilion:/home/andrew# mount /dev/sdb1 /mnt/usb
mount: /dev/sdb1 is not a valid block device

Why is it not a valid block? Do I have to think to myself each time before i boot up linux if I want to use my flash or not? Is there a better way to do this?
 
Old 01-12-2005, 08:05 PM   #2
JockVSJock
Senior Member
 
Registered: Jan 2004
Posts: 1,420
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
Not to steal the thread, but I'm having the same problems with my little thumbdrive. I could have swore that I've mounted this before in Slackware.


This is what /etc/fstab looks like

Code:
 
[cmmiller@phoenix-/mnt}$ cat /etc/fstab
/dev/hda1        /                ext3        defaults         1   1
/dev/cdrom       /mnt/cdrom       iso9660     noauto,owner,ro  0   0
/dev/fd0         /mnt/floppy      auto        noauto,owner     0   0
devpts           /dev/pts         devpts      gid=5,mode=620   0   0
proc             /proc            proc        defaults         0   0
/dev/sda4        /mnt/zip         vfat        noauto,owner,ro  0   0
/dev/sdb1        /mnt/t           vfat        noauto,owner,ro  0   0

This is what the mount command tells me

Code:
 
[cmmiller@phoenix-/mnt}$ mount
/dev/hda1 on / type ext3 (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
proc on /proc type proc (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda4 on /mnt/zip type vfat (rw)
When pulling the thumbdrive in, it looks like it automatically gets detected, light comes on in the thumbdrive.

/var/log/messages tells this story

Code:
 
root@phoenix:~# cat /var/log/messages | grep usb
Jan  9 17:59:14 phoenix kernel: usb.c: registered new driver usbdevfs
Jan  9 17:59:14 phoenix kernel: usb.c: registered new driver hub
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: $Revision: 1.275 $ time 18:40:47 Sep  2 2003
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: High bandwidth mode enabled
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: v1.275:USB Universal Host Controller Interface driver
Jan  9 17:59:14 phoenix kernel: usb.c: deregistering driver usbdevfs
Jan  9 17:59:14 phoenix kernel: usb.c: deregistering driver hub
Jan  9 17:59:14 phoenix kernel: usb.c: registered new driver usbdevfs
Jan  9 17:59:14 phoenix kernel: usb.c: registered new driver hub
Jan  9 17:59:14 phoenix kernel: usb.c: registered new driver usb-storage
Jan  9 17:59:14 phoenix kernel: usb-ohci.c: USB OHCI at membase 0xcc247000, IRQ 3
Jan  9 17:59:14 phoenix kernel: usb-ohci.c: usb-00:01.2, Silicon Integrated Systems [SiS] USB 1.0 Controller
Jan  9 17:59:14 phoenix kernel: usb.c: new USB bus registered, assigned bus number 1
Jan  9 17:59:14 phoenix kernel: usb-ohci.c: USB OHCI at membase 0xcc249000, IRQ 3
Jan  9 17:59:14 phoenix kernel: usb-ohci.c: usb-00:01.3, Silicon Integrated Systems [SiS] USB 1.0 Controller (#2)
Jan  9 17:59:14 phoenix kernel: usb.c: new USB bus registered, assigned bus number 2
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: $Revision: 1.275 $ time 18:40:47 Sep  2 2003
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: High bandwidth mode enabled
Jan  9 17:59:14 phoenix kernel: usb-uhci.c: v1.275:USB Universal Host Controller Interface driver

Not sure what I'm doing wrong here.

thanks
 
Old 01-12-2005, 08:14 PM   #3
Darklion
LQ Newbie
 
Registered: Nov 2004
Posts: 15

Rep: Reputation: 0
Generally speaking, I don't bother putting my flash drive into /etc/fstab. When I want to use it, I just type

mount -t vfat /dev/sda1 /mnt/usb

I suspect (not being a long-time Linux user, that's about as confident as I get) that the problem is that you aren't specifying the "-t vfat" when you try mounting it after booting. The reason it's recognized at boot time is probably because the fstab entry has the correct file system type.
 
Old 01-12-2005, 08:30 PM   #4
Garibaldi3489
Member
 
Registered: Oct 2004
Posts: 172

Original Poster
Rep: Reputation: 30
that sounds like a good idea, it makes sense. Unfortunally it didn't work:
Quote:
mount -t vfat /dev/sdb1 /mnt/usb
mount: /dev/sdb1 is not a valid block device
same problem.

Quote:
Not to steal the thread, but I'm having the same problems with my little thumbdrive. I could have swore that I've mounted this before in Slackware.
Don't worry about it, I'm happy to hear that someone else is having the same problem!
 
Old 01-12-2005, 08:39 PM   #5
JrLz
Member
 
Registered: Mar 2004
Location: Jakarta
Posts: 164

Rep: Reputation: 30
My flash worked great, and I did something wrong until
I got the same problem with you guys.............
I reinstalled usbutility from slackware package disk
and it works well now.
 
Old 01-12-2005, 09:06 PM   #6
JockVSJock
Senior Member
 
Registered: Jan 2004
Posts: 1,420
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
When trying to mount with the following command

Code:
 
mount -t vaft /dev/sdb1 /mn/t
I get the following output

Code:
 
root@phoenix:/mnt# mount -t vfat /dev/sdb1 /mnt/t
mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
       missing codepage or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so
 
Old 01-13-2005, 09:33 PM   #7
Garibaldi3489
Member
 
Registered: Oct 2004
Posts: 172

Original Poster
Rep: Reputation: 30
I've had that error too before. I wonder why?
 
Old 01-14-2005, 04:34 AM   #8
brancalessio
LQ Newbie
 
Registered: Aug 2004
Posts: 24

Rep: Reputation: 0
/dev/sda1 /mnt/usbpen vfat rw,user,noauto 0 0

This is my line in fstab (probably you should drop the default in yours). The error may be caused by uncorrect hardware probing (did you try to remove it and then plug it again?).

Bye!
 
Old 01-14-2005, 08:19 PM   #9
Garibaldi3489
Member
 
Registered: Oct 2004
Posts: 172

Original Poster
Rep: Reputation: 30
Quote:
This is my line in fstab (probably you should drop the default in yours). The error may be caused by uncorrect hardware probing (did you try to remove it and then plug it again?).
Yeah I tried that, it still wouldn't work though.
 
Old 01-15-2005, 12:01 AM   #10
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
Plug it in, wait a few seconds and then run:
fdisk -l
to see if it is showing up.
 
Old 01-15-2005, 08:22 AM   #11
JockVSJock
Senior Member
 
Registered: Jan 2004
Posts: 1,420
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
When running fdisk -l, this is the output

Code:
 
root@phoenix:~# fdisk -l

Disk /dev/sda: 250 MB, 250640384 bytes
64 heads, 32 sectors/track, 239 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda4   *           1         239      244720    6  FAT16

Disk /dev/sdb: 131 MB, 131072000 bytes
5 heads, 50 sectors/track, 1024 cylinders
Units = cylinders of 250 * 512 = 128000 bytes

This doesn't look like a partition table
Probably you selected the wrong device.

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   ?     7479086     8153844    84344761   69  Unknown
Partition 1 has different physical/logical beginnings (non-Linux?):
     phys=(68, 13, 10) logical=(7479085, 2, 16)
Partition 1 has different physical/logical endings:
     phys=(288, 115, 43) logical=(8153843, 2, 37)
Partition 1 does not end on cylinder boundary.
/dev/sdb2   ?     6806078    14285604   934940732+  73  Unknown
Partition 2 has different physical/logical beginnings (non-Linux?):
     phys=(371, 114, 37) logical=(6806077, 4, 32)
Partition 2 has different physical/logical endings:
     phys=(366, 32, 33) logical=(14285603, 3, 46)
Partition 2 does not end on cylinder boundary.
/dev/sdb3   ?          11          11           0   74  Unknown
Partition 3 has different physical/logical beginnings (non-Linux?):
     phys=(371, 114, 37) logical=(10, 1, 24)
Partition 3 has different physical/logical endings:
     phys=(372, 97, 50) logical=(10, 1, 23)
Partition 3 does not end on cylinder boundary.
/dev/sdb4               1    13740454  1717556736    0  Empty
Partition 4 has different physical/logical beginnings (non-Linux?):
     phys=(0, 0, 0) logical=(0, 0, 1)
Partition 4 has different physical/logical endings:
     phys=(0, 0, 0) logical=(13740453, 4, 22)
Partition 4 does not end on cylinder boundary.

Partition table entries are not in disk order

Disk /dev/sdb4: 1758.7 GB, 1758778097664 bytes
5 heads, 50 sectors/track, 13740453 cylinders
Units = cylinders of 250 * 512 = 128000 bytes

This doesn't look like a partition table
Probably you selected the wrong device.

     Device Boot      Start         End      Blocks   Id  System
/dev/sdb4p1   ?     7479086     8153844    84344761   69  Unknown
Partition 1 does not end on cylinder boundary.
/dev/sdb4p2   ?     6806078    14285604   934940732+  73  Unknown
Partition 2 does not end on cylinder boundary.
/dev/sdb4p3   ?          11          11           0   74  Unknown
Partition 3 does not end on cylinder boundary.
/dev/sdb4p4               1    13740454  1717556736    0  Empty
Partition 4 does not end on cylinder boundary.

Partition table entries are not in disk order

Disk /dev/hda: 20.4 GB, 20490559488 bytes
255 heads, 63 sectors/track, 2491 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/hda1   *           1        2310    18555043+  83  Linux
/dev/hda2            2311        2491     1453882+  82  Linux swap
sda4 has mounted a zip drive

sdb1 is where I try to mount my thumbdrive, it is ouputting some very odd errors about being non-linux...
 
Old 01-15-2005, 11:18 PM   #12
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
Looks like you need to run fdisk on sda and create some valid partitions. Then format them so they can be mounted.
 
Old 01-16-2005, 07:36 AM   #13
JockVSJock
Senior Member
 
Registered: Jan 2004
Posts: 1,420
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
How could that be?

My Zip drive I never had to format, just create a mount point in /mnt, modify the kernel, and fstab and it was on.

My thumbdrive on my Knoppix laptop, I'll I have to do is put it in the usb drive, modify fstab and it works too.

Never had to use fdisk on either storage device, so that is very hard to believe.
 
Old 01-16-2005, 08:56 AM   #14
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
This very same drive? The reason I say it is because your partitions aren't valid according to fdisk. It shows 8 partitions, is this correct?
Some of these devices actually have an empty partition table, they are just formatted.
 
Old 01-16-2005, 07:52 PM   #15
JockVSJock
Senior Member
 
Registered: Jan 2004
Posts: 1,420
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
Thanks for the replies...

But, if I fdisk my thumbdrive, I'll blow away any data on there that I need.

This is very odd, because again, I can mount it under Knoppix with no problems, and r/w too.
 
  


Reply


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
Problems mounting/unmounting flash USB drive LordSurvivoR Linux - Hardware 1 07-12-2005 11:19 PM
Flash Drive dudeguy9001 Linux - Hardware 1 12-31-2004 07:13 PM
USB flash drive problems in FC3. mr_segfault Fedora 2 11-17-2004 01:51 AM
IRQ conflict when external drive/flash-drive is put to use Nightfrost Linux - Hardware 0 10-22-2004 04:15 AM
Problems with sound, when playing flash files. Flash plug-in installed. Mistreated Linux - Software 2 09-02-2004 02:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:27 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration