Got usb drive, what are these files?
Got this usb drive thing to work, I think, and when I mount it there is a file called " Devices " and a directory created, " 001 ". what are these and what do I do with them? if I open up the 001 directory there are 3 other directories " 001 002 006 " I cant seem to copy anything to or from the usb drive, it just ends up in the mount point I created by following a tutorial on LQ.
|
What tutorial did you follow?
Out of the box, if all is well the following should work: "mount /dev/sda1 /mnt/foo" foo being the mount point you created under the /mnt directory. After making changes (adding removing files) you need to "umount /mnt/foo" USB storage devices are treated as SCSI, if you have other SCSI devices (hard drives) then your pen drive will most likely not be /dev/sda1, but another sd* device. I'm not sure about the contents of your pen drive, it could be improper mounting, it could be just the pendrive has contents on it from the factory. |
You didn't indicate which distro and version that you are using. Often the hotplug system will automatically mount the usb drive.
For example, for SuSE linux, a partition will be created under /media and mounted automatically. One problem is that there won't be normal entry for it looking at the mount command output or the fstab table. The entry in /etc/fstab for it is a generic one that might look like this: usbfs /proc/bus/usb usbfs noauto 0 0 I'm not sure if you could for example include a 'uid=' option for this, and if the autofs system would pick it up. Part of the problem is that there are two ways that user devices are handled in linux. You might want to read through the man 8 hotplug page, as well as the file /usr/share/doc/packages/hotplug/README if it exists on your system. Also, there may be a hotplug service that will list mounted devices. For SuSE /usr/sbin/rchotplug For Mandrake and others try 'service hotplug --help' for options. Also read through the /etc/sysconfig/hotplug file. This file will tell you whether subfs is used or something else. |
I am using slackware 10 and kernel 2.6
I cant find the tutorial, but its here somewhere on LQ I have read around and I think I was doing it wrong but now I tried the way I found and it still does not work. I do this: mount -t vfat /dev/sda1 /mnt/flashdrive and I get a message that says mount: wrong fs type, bad option, bad superblock on /dev/sda1, or too many mounted file systems I have seen a file called fstab and have this line: /dev/sda1 /mnt/flashdrive auto noauto,owner,users 0 0 ? What else could I try |
Try just "mount /mnt/flashdrive" and see what happens.
Typically I don't choose a fstype, I just use auto. You're fstab config is configured to use auto, so just stick with that. |
After reading through all kinds of stuff about USB and fstab I have tried auto, vfat and all kinds of other filesystems but nothing is working. I keep getting that same error message. I have tried mount /mnt/flashdrive and that does not work either :( What else can I try? When I reboot into windows the usb drive works fine.
|
Quote:
Is there anything on the drive yet...? Have you tried looking for any files on /mnt/flashdrive ls -l /mnt/flashdrive See if you can give us some output from ther terminal to see what is actually on your system: fdisk -l mount cat /etc/fstab KC |
When you plug the pen, wait one minute or two and them see the output of the dmesg comand.
If when you mount you have that great amount of folders is because the pen is mounted with usbfs, it is preferrable to use auto instead. [EDIT]I'm using the same Slackware and Kernel and my pens work fine. |
When I do ls -l /mnt/flashdrive it just says " total 0 "
When I do fdisk -l it says this, for the flashdrive: " Device Boot Start End Blocks Id System /dev/sda1 * 1 500 31982+ 1 FAT12" Mount /dev/hda1 on / type reiserfs (rw) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) usbfs on /proc/bus/usb type usbfs (rw) cat /etc/fstab /dev/hda1 / reiserfs defaults 1 1 /dev/cdrom /mnt/cdrom iso9660 noauto,owner,users,ro 0 0 /dev/cdrom1 /mnt/cdrom1 iso9660 noauto,owner,users 0 0 /dev/dvd /mnt/dvd auto noauto,owner,users 0 0 /dev/fd0 /mnt/floppy auto noauto,owner 0 0 /dev/sda1 /mnt/flashdrive auto noauto,owner,users 0 0 /dev/sda2 /mnt/flashdrive auto noauto,owner,users 0 0 /dev/sda3 /mnt/flashdrive auto noauto,owner,users 0 0 /dev/sda4 /mnt/flashdrive auto noauto,owner,users 0 0 devpts /dev/pts devpts gid=5,mode=620 0 0 proc /proc proc defaults 0 0 dmesg usb 1-4.1: new full speed USB device using ehci_hcd and address 3 Initializing USB Mass Storage driver... scsi0 : SCSI emulation for USB Mass Storage devices usbcore: registered new driver usb-storage USB Mass Storage support registered. usb-storage: device found at 3 usb-storage: waiting for device to settle before scanning Vendor: USB Mass Model: Storage Device Rev: Type: Direct-Access ANSI SCSI revision: 02 SCSI device sda: 64000 512-byte hdwr sectors (33 MB) sda: Write Protect is off sda: Mode Sense: 37 00 00 08 sda: assuming drive cache: write through SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI device sda: 64000 512-byte hdwr sectors (33 MB) sda: Write Protect is off sda: Mode Sense: 37 00 00 08 sda: assuming drive cache: write through sda: sda1 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 Attached scsi removable disk sda at scsi0, channel 0, id 0, lun 0 Attached scsi generic sg0 at scsi0, channel 0, id 0, lun 0, type 0 usb-storage: device scan complete SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 FAT: invalid media value (0x22) VFS: Can't find a valid FAT filesystem on dev sda1. SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 FAT: invalid media value (0x22) VFS: Can't find a valid FAT filesystem on dev sda1. SCSI error: host 0 id 0 lun 0 return code = 8000002 Sense class 7, sense error 0, extended sense 0 There are some error messages above but I dont know what they are? Thanks for any help, I hope I can use this thing, I just bought it. |
Are you able to mount /dev/sda2, /dev/sda3, /dev/sda4?
Your fstab indicates 3 other partitions. I've seen where the first partition is very small and not used on usb key drives. How many partitions show up in windows? Are there other partitions indicated by the root command: fdisk -l /dev/sda |
No, When I try other sda2,3,4 I get " Does not exist "
This is output of fdisk -l /dev/sda and when i do this the light on the flashdrive flashes, It seems like I am so close to getting this to work but why wont it mount? Disk /dev/sda: 32 MB, 32768000 bytes 8 heads, 16 sectors/track, 500 cylinders Units = cylinders of 128 * 512 = 65536 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 500 31982+ 1 FAT12 THANKS!! |
What model of thumb drive is it?
I had similar problems with one (Apacer handy something or other) I used that was pre-formatted for windows until I used cfdisk to reformat it to vfat. IIRC it was showing up with 4 partitions, but cfdisk complained that the partitions were over-writing each other or something like that. I deleted the partitions one by one, and then wrote a new partition to use the whole drive and it was fine between Linux boxes but every time I plugged it into a Win box Windows would complain it wasn't formatted, and of course offer to format it :( I gave it away |
The files you are looking at are files from the boot partition. I know the ones you're talking about but I'm not sure what they do. Have you checked the drive size? It may be a lot smaller than you think...
BTW I overwrote mine when trying to install Lilo and it did no harm. See if the other partition mount (sda2, sda3 etc...) |
FAT12???? what did you use to partition the drive?
KC |
Quote:
Btw, if you connect more flashdrives, you problaby will have sdb1, sdc1... and not sda1,sda2... ----------------- Quote:
|
All times are GMT -5. The time now is 03:01 PM. |