LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
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 07-01-2004, 03:59 AM   #1
hamish
Member
 
Registered: Aug 2003
Location: Edinburgh
Distribution: Server: Gentoo2004; Desktop: Ubuntu
Posts: 720

Rep: Reputation: 30
USB pen drive not mounting. /dev/sda1 not present!


Hey

I am trying to mount my pen drive however, I have run into a problem - I don't have a /dev/sda1. It was there (I mounted my girlfirend's pen drive about 3 weeks ago using it), but now it isn't. I guess I could have messed something up when I recomplied.

Important things loaded as modules, I have are:
vfat
fat
sg
usb_storage
ohci_hcd
ide_scsi
sr_mod
scsi_mod

In fstab, I have:
/dev/sda1 /mnt/usb auto noauto,user 0 0

Here is /dev stuff:

#ls /dev/s*
/dev/sequencer /dev/sequencer2 /dev/sg0 /dev/sg1 /dev/sr0 /dev/stderr /dev/stdin /dev/stdout

/dev/scsi:
host0 host1

/dev/sg:
c0b0t0u0 c1b0t0u0

/dev/shm:

/dev/snd:
controlC0 pcmC0D0c pcmC0D0p pcmC0D1c pcmC0D2p seq timer

/dev/sound:
adsp audio dsp mixer sequencer sequencer2

/dev/sr:
c0b0t0u0

When I try mounting any of the sr or sg devices, I'm told that it isn't a block device! Same goes for the /dev/scsi stuff. /dev/sr0 is my writable CD drive.

Eg:
root@archimedes hamish # mount -t vfat /dev/sg1 /mnt/usb/
mount: /dev/sg1 is not a block device

Here is my messages when I insert the pen drive:
root@archimedes hamish # tail /var/log/messages
Jul 1 09:58:51 archimedes [<c011ead7>] sys_gettimeofday+0x27/0xb0
Jul 1 09:58:51 archimedes [<c010917b>] syscall_call+0x7/0xb
Jul 1 09:58:51 archimedes
Jul 1 09:58:51 archimedes usb 1-1: new full speed USB device using address 5
Jul 1 09:58:51 archimedes scsi4 : SCSI emulation for USB Mass Storage devices
Jul 1 09:58:51 archimedes Vendor: Kingston Model: DataTraveler 2.0 Rev: 4.10
Jul 1 09:58:51 archimedes Type: Direct-Access ANSI SCSI revision: 02
Jul 1 09:58:51 archimedes Attached scsi generic sg1 at scsi4, channel 0, id 0, lun 0, type 0
Jul 1 09:58:51 archimedes WARNING: USB Mass Storage data integrity not assured
Jul 1 09:58:51 archimedes USB Mass Storage device found at 5

This says that /dev/sg1 is the device! But I'm told that it isn't a block device!

I have tested the drive in another linux and it worked fine.

Any suggestions?? PLease!

Hamish
 
Old 07-01-2004, 07:50 AM   #2
max85nitro
LQ Newbie
 
Registered: Jul 2004
Location: Toronto, ON
Distribution: Debian Sarge
Posts: 8

Rep: Reputation: 0
I know this sounds weird, but try mounting it as /dev/sda, if you do not have an sda drive. On my other computer, I DO have an sda drive, and in that case the usb key should be mounted as sdb. More keys would be mounted as sdc, sdd, etc. This is probably because of the way SCSI works.
 
Old 07-01-2004, 08:18 AM   #3
hamish
Member
 
Registered: Aug 2003
Location: Edinburgh
Distribution: Server: Gentoo2004; Desktop: Ubuntu
Posts: 720

Original Poster
Rep: Reputation: 30
Hey!

Thanks for the help, however, the problem is that I don't actually have a /dev/sda file at all! This is really bugging me.

I have the same problem when I started using my cd-writer. That is, unless the modules doe scsi emulation wwere loaded, the /dev/cdrom device didn't exist. I feel that this is the same problem I'm having here! However, I can't figure it out. All the modules are loaded!

Hamish
 
Old 07-05-2004, 02:00 PM   #4
M3Freak
LQ Newbie
 
Registered: Apr 2003
Posts: 5

Rep: Reputation: 0
USB memory keys are mass storage devices, so they don't come with partitions. This means when a USB key is mounted in Linux, it's mounted as a scsi device under /dev/sda, /dev/sdb etc. The actual device number depends on how your particular system is configured.

I've only been able to mount USB keys as /dev/sdb on my laptop. I've never been able to specify a partition (e.g. /dev/sdb1), but that makes sense since the USB key doesn't have any partitions on it.

Check out this How-To: http://www.systemsaligned.com/learn/howto/hwtusbkey. The How-To should help you to mount your USB memory key using autofs (instead of defining it in the fstab file, where removable devices really shouldn't be anyway). There are also useful links at the end of the How-To.

HTH,

Kanwar
 
Old 07-07-2004, 02:27 PM   #5
hamish
Member
 
Registered: Aug 2003
Location: Edinburgh
Distribution: Server: Gentoo2004; Desktop: Ubuntu
Posts: 720

Original Poster
Rep: Reputation: 30
Hey Kanwar,

thanks for that link. It has some good things on it.

The only problem is that I don't every have a /dev/sda file! This is really bugging! I'm sure that I've got all the right modules installed.

Any suggestions why a device would register? I already pointed out about the fact that my scsi emulated CD drive didn't work because of modules. But I think I have installed all of them.

Thanks
Hamish
 
Old 07-07-2004, 03:03 PM   #6
M3Freak
LQ Newbie
 
Registered: Apr 2003
Posts: 5

Rep: Reputation: 0
When I plug in a USB memory key, my system has these modules loaded:

floppy
sg
usb_storage
sd_mod
scsi_mod
fat
vfat
uhci_hcd

You said you have these loaded:

vfat
fat
sg
usb_storage
ohci_hcd
ide_scsi
sr_mod
scsi_mod

I appear to have a few different modules loaded. Try loading the additional modules as well, and see if that fixes your problem.

Also, try to mount the drive at /mnt/usb with just "/dev/sg". Finally, make sure that /mnt/usb exists.

Good luck,

Kanwar
 
Old 07-07-2004, 03:32 PM   #7
hamish
Member
 
Registered: Aug 2003
Location: Edinburgh
Distribution: Server: Gentoo2004; Desktop: Ubuntu
Posts: 720

Original Poster
Rep: Reputation: 30
Fixed!

Thank you for your list of modules. It was the sd_mod one which was missing. I was sure that it was a module problem. Thank you again.

Hamish
 
Old 03-17-2005, 10:14 PM   #8
bobshaffer2
LQ Newbie
 
Registered: Mar 2005
Location: Ohio
Distribution: Several (Gentoo, Red Hat/Fedora, HP-UX, Helix)
Posts: 26

Rep: Reputation: 17
How to make sd_mod load by itself

I had the same problem and solved it with the same solution (loading sd_mod).

What I would like to know is what I have to do to get this to load automatically when I plug in my USB storage devices.
 
Old 01-11-2010, 04:32 AM   #9
joshisarang
LQ Newbie
 
Registered: Oct 2009
Posts: 3

Rep: Reputation: 0
hw to m ount pendrive in fedora 10

hello friend

anybody help to how can i mount pendrive in fedora 10
 
Old 01-11-2010, 08:25 PM   #10
bobshaffer2
LQ Newbie
 
Registered: Mar 2005
Location: Ohio
Distribution: Several (Gentoo, Red Hat/Fedora, HP-UX, Helix)
Posts: 26

Rep: Reputation: 17
Quote:
Originally Posted by joshisarang View Post
hello friend

anybody help to how can i mount pendrive in fedora 10
These days it is fairly trivial usually. Most people use KDE or Gnome Desktops, and the file browsing programs (konqueror and nautilus?) have some mechanism for seeing the available USB storage devices, mounting and unmounting them, etc. You can still mount them from the command line (as root) and they would be /dev/sdXn (where X is some letter like a,b,c,d and n is the partition, or maybe if it has no partition table the device /dev/sdX could be mounted).

Now if your pendrive has NTFS on it (do they ever have that?) then you probably need to make sure you have FUSE configured in the kernel and you have ntfs-3g (I think that's the name) installed in order to be able to mount it and have any useful write access. If it has FAT32 you will need to have the software package for vfat installed. (idk what it's called in FC)

If you're looking to put your root filesystem on such a drive, you usually need to create a partition table and set up an initrd image and all that, and I'm not sure how you do that on FC any more (maybe mkinitrd, but check the documentation for FC to be sure about how). You're probably not trying to do this anyway, but I figured I'd throw the info in anyway since, like I said, the mounting of a pendrive is usually really simple with HAL and everything being so commonly used.

Anyway, you shouldn't have any trouble as long as the pendrive is recognized. Most of them are picked up by the generic usb-storage driver, and most cameras and other devices like that are too. If you can't find the device listed in the file browser with your other removable media stuff, take a look at the output of the dmesg command right after you plug it in, and it should give you some clue as to what's going on.
 
  


Reply



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
Mounting a USB pen drive in Fedora Core 1 mrde50garfield Linux - Hardware 2 07-26-2010 01:14 AM
Mounting usb pen drive file permssions problems linuxmandrake Debian 1 10-10-2005 07:21 PM
USB drive... /dev/sda1 does not exist! Lord Zoltar Linux - Hardware 48 05-15-2005 11:55 AM
mounting usb pen drive; ntfs problem ShamitSoneji Fedora 20 12-01-2004 02:19 AM
USB Pen Drive, /dev/sda1 is not a valid block device Aeiri Linux - Hardware 3 08-13-2004 10:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 08:30 PM.

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