LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-09-2004, 03:28 PM   #1
iskrem
LQ Newbie
 
Registered: Nov 2004
Location: Norway
Distribution: Gentoo
Posts: 25

Rep: Reputation: 15
Unable to mount USB-stick


I have a problem mounting my Creative Muvo TX MP3-player/USB-stick. I am running udev and dmesg express that the device is probed:

Code:
  Type:   Direct-Access                      ANSI SCSI revision: 02
SCSI device sdb: 499968 512-byte hdwr sectors (256 MB)
sdb: Write Protect is off
sdb: Mode Sense: 03 00 00 00
sdb: assuming drive cache: write through
 sdb: sdb1
Attached scsi removable disk sdb at scsi4, channel 0, id 0, lun 0
Attached scsi generic sg1 at scsi4, channel 0, id 0, lun 0,  type 0
USB Mass Storage device found at 5
fdisk -l gives this output:
Code:
Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          31      249956+   6  FAT16
And while trying to mount it, I am getting the following problems. It really says that /dev/sdb1 doesn't exist:

Code:
# mount -t msdos /dev/sdb1 /mnt/muvo
mount: special device /dev/sdb1 does not exist
Code:
# mount /dev/sdb1 /mnt/muvo
mount: special device /dev/sdb1 does not exist
I know I have a module for fat16. I don't understand that I recieve this error message:
Code:
# mount /dev/sdb1 -t fat16 /mnt/muvo
mount: fs type fat16 not supported by kernel

I have tried reformatting, repartioning etc. Any help would be appreciated and if there is any information that is needed in order to answer this question, please let me now. There could be a very silly solution that I haven't thought of. I would be glad to hear it all.

Edit: sdaX was suppose to be sdbX

Last edited by iskrem; 12-11-2004 at 02:49 AM.
 
Old 12-09-2004, 04:15 PM   #2
netstv
Member
 
Registered: May 2004
Location: Martinez, CA
Distribution: Ubuntu
Posts: 38

Rep: Reputation: 15
I'm not sure why you are trying /dev/sda instead of /dev/sdb. It seems to me that the dmesg told it as /dev/sdb.

What I would do is try sfdisk instead of fdisk. So what happens if you type:

/sbin/sfdisk -l /dev/sdb

and same for

/sbin/sfdisk -l /dev/sda

that is a -l (EL). This will just show the partitions from the device.

Post back what that puts up.
 
Old 12-09-2004, 07:13 PM   #3
SlackerLX
Senior Member
 
Registered: Dec 2004
Location: Herzliyya, Israel
Distribution: SuSE 10.1; Testing Distros
Posts: 1,832

Rep: Reputation: 47
Cool

you have been using wrong syntacsis.


Follow this :
mount -t vfat /dev/sda1 /mnt/"your directory"
 
Old 12-11-2004, 03:18 AM   #4
iskrem
LQ Newbie
 
Registered: Nov 2004
Location: Norway
Distribution: Gentoo
Posts: 25

Original Poster
Rep: Reputation: 15
First of all thank for taking time to answer my question. It is greatly appreciated.

Quote:
Originally posted by netstv
I'm not sure why you are trying /dev/sda instead of /dev/sdb. It seems to me that the dmesg told it as /dev/sdb.
Sorry, I tried to manipulate the output from dmesg, so I could rationalize the problem. The usb stick is really at /dev/sdb1.
Maybe it wasn't a good idea to alter the output. I have corrected the output according to what it really is. So the stick is on /dev/sdb(1)

Quote:
Originally posted by netstv

What I would do is try sfdisk instead of fdisk. So what happens if you type:

/sbin/sfdisk -l /dev/sdb
/sbin/sfdisk -l /dev/sda
I have reformated the unit, so I really don't have any partitions on it anymore. So, if we start from scratch and troubleshoot my steps, I hope we can find a solution.
When I reformat the unit you can see the result of this command.

I make a partition at /dev/sdb
Code:
# fdisk /dev/sdb
Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-1008, default 1): 1
Last cylinder or +size or +sizeM or +sizeK (1-1008, default 1008): 1008

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.

Syncing disks.
Listing the partitions
Code:
# sfdisk -l /dev/sdb

Disk /dev/sdb: 1008 cylinders, 8 heads, 62 sectors/track
Units = cylinders of 253952 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/sdb1          0+   1007    1008-    249953   83  Linux
/dev/sdb2          0       -       0          0    0  Empty
/dev/sdb3          0       -       0          0    0  Empty
/dev/sdb4          0       -       0          0    0  Empty
Trying to make a vfat file system doesn't work.
Code:
# mkfs -t vfat /dev/sdb1
mkfs.vfat 2.8 (28 Feb 2001)
/dev/sdb1: No such file or directory
Trying to mount the usb stick regardless of file system:
Code:
# mount /dev/sdb1 /mnt/flash
mount: special device /dev/sdb1 does not exist
This however works:
Code:
# mount /dev/sdb /mnt/flash
I get a listing of the usb sticks contents. However I am not able to copy files to the stick (it doesn't appear there). But I am able to write a file to disk
using ex. vim in the current /mnt/flash directory.
Code:
# cd /mnt/flash
# dir
lost+found
Trying to format usb-stick to vfat doesn't work either
Code:
# umount /mnt/flash
# mkfs.vfat /dev/sdb
mkfs.vfat 2.8 (28 Feb 2001)
mkfs.vfat: Will not try to make file system on '/dev/sdb'
Code:
# mkfs.vfat /dev/sdb1
mkfs.vfat 2.8 (28 Feb 2001)
/dev/sdb1: No such file or directory
Code:
# mount /dev/sdb /mnt/flash
# mkfs -t vfat /mnt/flash
mkfs.vfat 2.8 (28 Feb 2001)
mkfs.vfat: unable to open /mnt/flash
Strange. Again, thanks a lot for taking time to troubleshoot my issue.
 
Old 12-11-2004, 09:54 AM   #5
iskrem
LQ Newbie
 
Registered: Nov 2004
Location: Norway
Distribution: Gentoo
Posts: 25

Original Poster
Rep: Reputation: 15
Not even this work:

Code:
# /sbin/sfdisk -l /dev/sdb

Disk /dev/sdb: 1008 cylinders, 8 heads, 62 sectors/track
Units = cylinders of 253952 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/sdb1          0+   1007    1008-    249953   83  Linux
/dev/sdb2          0       -       0          0    0  Empty
/dev/sdb3          0       -       0          0    0  Empty
/dev/sdb4          0       -       0          0    0  Empty
Code:
# mkfs -t ext3 /dev/sdb1
mke2fs 1.35 (28-Feb-2004)
Could not stat /dev/sdb1 --- No such file or directory

The device apparently does not exist; did you specify it correctly?
 
Old 12-13-2004, 08:54 AM   #6
netstv
Member
 
Registered: May 2004
Location: Martinez, CA
Distribution: Ubuntu
Posts: 38

Rep: Reputation: 15
When you did mount /dev/sdb /mnt/flash did it take a really long time?

Because I have seen that, but it was primarily because my kernel was compiled for the wrong processor.

What happens when you do cat /proc/partitions ? My guess is you are going to only see sdb. You should see sdb1
 
Old 12-13-2004, 09:06 AM   #7
oneandoneis2
Senior Member
 
Registered: Nov 2003
Location: London, England
Distribution: Ubuntu
Posts: 1,460

Rep: Reputation: 48
Have you looked at the /dev directory to make sure it actually has a /dev/sdb1 and it's permissions make it accessible?

Because when I was trying to get my PDA working, I got a message saying it had attached the device to /dev/ttyUSB1 and all was well - only there was no ttyUSB1!

I created it manually using mknod, and it worked just fine after that.

Last edited by oneandoneis2; 12-13-2004 at 09:07 AM.
 
Old 12-13-2004, 10:06 AM   #8
steve1401
Member
 
Registered: May 2003
Location: UK
Distribution: Debian
Posts: 73

Rep: Reputation: 15
This is what worked for me, I've allowed for you 'sdb' device...

Plug in your memory stick and (as root);

mkdir /mnt/mem

mount -t vfat /dev/sdb1 /mnt/mem

If this works, put this into /etc/fstab;
/dev/sdb1 /mnt/mem vfat rw,users 0 0

Does this help? Normaly the devise is /dev/sda1, try this as well???

Steve
 
Old 12-13-2004, 04:15 PM   #9
iskrem
LQ Newbie
 
Registered: Nov 2004
Location: Norway
Distribution: Gentoo
Posts: 25

Original Poster
Rep: Reputation: 15
I think I found a solution to the problem today. The problem was the following: /dev/sdb1 was symlinked to "win". I suspect that Wine has done this. I removed the symlink and readded /dev/sdb1 using mknod. It was however a bit tricky to know the syntax of the mknod command. After some googling I figured that the syntax could be the following:

Code:
mknod /dev/sdb b 8 16
mknod /dev/sdb1 b 8 17
mknod /dev/sdb2 b 8 18
But the USB-stick is still acting kind of buggy. Even if I have a FAT filesystem it appears as Linux. If I format it as ext3 it still appears as Linux. This might be correct, though.

Code:
sfdisk -l /dev/sdb

Disk /dev/sdb: 1008 cylinders, 8 heads, 62 sectors/track
Units = cylinders of 253952 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/sdb1          0+   1007    1008-    249953   83  Linux
/dev/sdb2          0       -       0          0    0  Empty
/dev/sdb3          0       -       0          0    0  Empty
/dev/sdb4          0       -       0          0    0  Empty
Thanks for all help. I hope this resolved the issue.
 
Old 12-13-2004, 04:23 PM   #10
netstv
Member
 
Registered: May 2004
Location: Martinez, CA
Distribution: Ubuntu
Posts: 38

Rep: Reputation: 15
Right so your main problem is resolved. Now you need to setup the parition as a vfat or whatever DOS type partition you want. I don't know too much about the DOS partition stuff.

I have a script that runs sfdisk and tells is "L" as the third parameter which is Linux. I believe there is a DOS type. But that's all you need to do ....

-netstv
 
Old 12-14-2004, 08:15 AM   #11
Winno
Member
 
Registered: Sep 2003
Location: Australia
Distribution: Fedora Core 3 / Mandrake 10.1 / Gentoo 2005.0
Posts: 100

Rep: Reputation: 15
When you partition using *fdisk, you can set the type ID (eg fat 16, linux) of a partition. At the fdisk prompt, typing t allows you to select an ID. After entering the partition number, you can list the codes by typing L. In your case, you'd probably want 'e W95 FAT16 (LBA)', so type 'e'. If that doesn't work, try '6 FAT16'. Then try formatting with mkfs.vfat.

The thing is, there maybe some ID confusion when mounting. If a partition is ID'd as Linux, it should be an ext2/3/etc FS.
 
Old 12-17-2004, 09:22 AM   #12
iskrem
LQ Newbie
 
Registered: Nov 2004
Location: Norway
Distribution: Gentoo
Posts: 25

Original Poster
Rep: Reputation: 15
Thanks a lot. I wasn't aware of this "ID" issue.
I will do some further research on that subject

Thanks a lot for all help!
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Unable to mount the USB Stick reply2vinay Linux - Hardware 2 08-24-2005 11:21 AM
USB stick - unable to umount Artik Debian 1 05-18-2005 12:29 PM
mount/umount usb stick - PQI Intelligent Stick 2.0 sandbag Linux - Software 5 05-06-2005 11:12 AM
Unable to use new USB memory stick erraticassassin Slackware 4 02-13-2005 12:46 PM
How to mount usb stick yotamk Debian 6 11-21-2004 12:46 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:08 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