I am trying to mount a FAT32 partition in CentOS. I'm following the instructions on this page: http://www.linuxforum.com/linux_tutorials/14/1.php
This is the line I put into /etc/fstab /dev/hda /mnt/windows vfat users,owner,rw,umask=000 0 0
And this is the error I get: [root@localhost mnt]# mount -a mount: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
What is the cause of this error?
For reference, this is the output of fsisk: [root@localhost mnt]# fdisk -l
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
Disk /dev/hdb: 30.7 GB, 30738677760 bytes 255 heads, 63 sectors/track, 3737 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hdb1 * 1 3644 29270398+ 83 Linux /dev/hdb2 3645 3737 747022+ f W95 Ext'd (LBA)
Dave
On Mon, Aug 29, 2005 at 10:57:03PM +0900, Dave Gutteridge enlightened us:
I am trying to mount a FAT32 partition in CentOS. I'm following the instructions on this page: http://www.linuxforum.com/linux_tutorials/14/1.php
This is the line I put into /etc/fstab /dev/hda /mnt/windows vfat users,owner,rw,umask=000 0 0
And this is the error I get: [root@localhost mnt]# mount -a mount: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
What is the cause of this error?
It doesn't appear that owner is a valid option for fat filesystems. Try removing that option and see if that fixes your problem.
Matt
On Mon, 2005-08-29 at 22:57 +0900, Dave Gutteridge wrote:
I am trying to mount a FAT32 partition in CentOS. I'm following the instructions on this page: http://www.linuxforum.com/linux_tutorials/14/1.php
This is the line I put into /etc/fstab /dev/hda /mnt/windows vfat users,owner,rw,umask=000 0 0
And this is the error I get: [root@localhost mnt]# mount -a mount: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
What is the cause of this error?
For reference, this is the output of fsisk: [root@localhost mnt]# fdisk -l
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
Disk /dev/hdb: 30.7 GB, 30738677760 bytes 255 heads, 63 sectors/track, 3737 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hdb1 * 1 3644 29270398+ 83 Linux /dev/hdb2 3645 3737 747022+ f W95 Ext'd (LBA)
Dave-
You are trying to mount /dev/hda, but you need to be using /dev/hda1.
Try this on /etc/fstab that worked for me /dev/hda /mnt/windows vfat auto,rw,umask=0 0 0
--- Dave Gutteridge dave@tokyocomedy.com wrote:
I am trying to mount a FAT32 partition in CentOS. I'm following the instructions on this page: http://www.linuxforum.com/linux_tutorials/14/1.php
This is the line I put into /etc/fstab /dev/hda /mnt/windows vfat
users,owner,rw,umask=000 0 0
And this is the error I get: [root@localhost mnt]# mount -a mount: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
What is the cause of this error?
For reference, this is the output of fsisk: [root@localhost mnt]# fdisk -l
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
Disk /dev/hdb: 30.7 GB, 30738677760 bytes 255 heads, 63 sectors/track, 3737 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hdb1 * 1 3644 29270398+ 83 Linux /dev/hdb2 3645 3737 747022+ f W95 Ext'd (LBA)
Dave _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
__________________________________________________________ Find your next car at http://autos.yahoo.ca
Thank you for the advice. I've tried: /dev/hda /mnt/windows vfat auto,rw,umask=0 0 0 ...and: /dev/hda1 /mnt/windows vfat auto,rw,umask=0 0 0 ... in my /etc/fstab file, and I still get this error: mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
Is there any other possible cause?
Dave
On Mon, 2005-08-29 at 22:57 +0900, Dave Gutteridge wrote:
I am trying to mount a FAT32 partition in CentOS. I'm following the instructions on this page: http://www.linuxforum.com/linux_tutorials/14/1.php
This is the line I put into /etc/fstab /dev/hda /mnt/windows vfat users,owner,rw,umask=000 0 0
And this is the error I get: [root@localhost mnt]# mount -a mount: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
What is the cause of this error?
For reference, this is the output of fsisk: [root@localhost mnt]# fdisk -l
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
Dave,
Try:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2
Adjust uid and gid for the user you want to have full access (see /etc/passwd entry), or omit for read-all write-root. [Be sure /mnt/windows exists.]
Disk /dev/hdb: 30.7 GB, 30738677760 bytes 255 heads, 63 sectors/track, 3737 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hdb1 * 1 3644 29270398+ 83 Linux /dev/hdb2 3645 3737 747022+ f W95 Ext'd (LBA)
OT, but looks like /dev/hdb2 has no extended partitions. It's a pretty small percentage of the disk, so may be a don't-care. Could make it swap as you don't seem to have any. If you want:
# fdisk /dev/hdb
Command (m for help): t Partition number (1-4): 2 Hex code (type L to list codes): 82 Changed system type of partition 1 to 82 (Linux swap)
Command (m for help): w
# mkswap /dev/hdb2
Put the following in /etc/fstab:
/dev/hdb2 swap swap defaults 0 0
# free # swapon -a # free
Phil
Whoah! Totally scary and not good. I tried this:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2
And then I tried "mount -a". It returned not errors, so figured it worked. I went to the Nautilus file browser, and saw that the 30 GB FAT32 HD had an icon. I clicked to open it, but it gave an error similar to before.
I figured I'd reboot, to make sure that the whole system was caught up on the new settings.
But...
When I rebooted, somewhere alon the way, it started saying things like "file XXX is nnnn bytes, truncating to n2n2n2n2 bytes..." It was going through my FAT32 HD and truncating files!
What is up with that?
Not knowing what else to do, I hard reset the machine. I rebooted into Windows, and sure enough some files on the FAT32 disk were corrupted.
So then I had to boot back into CentOS without it messing with my files. After some trial and error, I found that if I booted with the rghb quiet option off, I could hit ctrl+C and stop it from truncating too many files (but still some!).
This is totally undesirable. I have data on that hard drive I can't afford to lose. I want to access it with CentOS, not destroy it.
What's going on?
Dave
On Tue, 2005-08-30 at 01:55 +0900, Dave Gutteridge wrote:
Whoah! Totally scary and not good. I tried this:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2
And then I tried "mount -a". It returned not errors, so figured it worked. I went to the Nautilus file browser, and saw that the 30 GB FAT32 HD had an icon. I clicked to open it, but it gave an error similar to before.
I figured I'd reboot, to make sure that the whole system was caught up on the new settings.
But...
When I rebooted, somewhere alon the way, it started saying things like "file XXX is nnnn bytes, truncating to n2n2n2n2 bytes..." It was going through my FAT32 HD and truncating files!
What is up with that?
Not knowing what else to do, I hard reset the machine. I rebooted into Windows, and sure enough some files on the FAT32 disk were corrupted.
So then I had to boot back into CentOS without it messing with my files. After some trial and error, I found that if I booted with the rghb quiet option off, I could hit ctrl+C and stop it from truncating too many files (but still some!).
This is totally undesirable. I have data on that hard drive I can't afford to lose. I want to access it with CentOS, not destroy it.
What's going on?
---- man fstab
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2 ^ ^ really really bad idea -------------------------------------|-|
filesystem does not need to be dumped (field 5) and not need fsck'ing (field 6) - it is vfat right?
they should be 0's
Craig
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2 ^ ^ really really bad idea -------------------------------------|-|
If you say so. Did I mention I was a newbie? I'm a newbie. I only put in the 1 and 2 because that's what another guy on this list told me to do. I have no idea what they mean.
filesystem does not need to be dumped (field 5) and not need fsck'ing (field 6) - it is vfat right?
If vfat is the same as fat32, then yes.
I'm a little scared to go ahead with this, because I don't want to lose any more data. If I change the last two numbers, will I at least be safe from having Linux try and make changes to the hard drive?
Dave
Dave Gutteridge wrote:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2 ^ ^ really really bad idea -------------------------------------|-|
If you say so. Did I mention I was a newbie? I'm a newbie. I only put in the 1 and 2 because that's what another guy on this list told me to do. I have no idea what they mean.
filesystem does not need to be dumped (field 5) and not need fsck'ing (field 6) - it is vfat right?
If vfat is the same as fat32, then yes.
I'm a little scared to go ahead with this, because I don't want to lose any more data. If I change the last two numbers, will I at least be safe from having Linux try and make changes to the hard drive?
Dave
Hello, Dave -
man fstab:
"The sixth field, (fs_passno), is used by the fsck(8) program to determine the order in which filesystem checks are done at reboot time. The root filesystem should be specified with a fs_passno of 1, and other filesystems should have a fs_passno of 2. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to utilize parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked."
You wouldn't want to fsck a vfat drive. I've never done it before. I don't even know if it's *possible*, even if there was a way to force it. Hope that helps.
Thanks -dant
On Mon, 2005-08-29 at 11:18 -0600, dan.trainor wrote:
Dave Gutteridge wrote:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2 ^ ^ really really bad idea -------------------------------------|-|
If you say so. Did I mention I was a newbie? I'm a newbie. I only put in the 1 and 2 because that's what another guy on this list told me to do. I have no idea what they mean.
filesystem does not need to be dumped (field 5) and not need fsck'ing (field 6) - it is vfat right?
If vfat is the same as fat32, then yes.
I'm a little scared to go ahead with this, because I don't want to lose any more data. If I change the last two numbers, will I at least be safe from having Linux try and make changes to the hard drive?
Dave
Hello, Dave -
man fstab:
"The sixth field, (fs_passno), is used by the fsck(8) program to determine the order in which filesystem checks are done at reboot time. The root filesystem should be specified with a fs_passno of 1, and other filesystems should have a fs_passno of 2. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to utilize parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked."
You wouldn't want to fsck a vfat drive. I've never done it before. I don't even know if it's *possible*, even if there was a way to force it. Hope that helps.
It is certainly possible, and that's how it works on my system (thus the sample fstab line); however, should have noted that dosfsck is alpha. Works-for-me but YMMV. Sorry 'bout that Dave.
# fsck /dev/hda2 fsck 1.35 (28-Feb-2004) dosfsck 2.8, 28 Feb 2001, FAT32, LFN Warning: FAT32 support is still ALPHA. /dev/hda2: 39084 files, 1281584/4094597 clusters # rpm -qif `which dosfsck` Name : dosfstools Relocations: (not relocatable) Version : 2.8 Vendor: CentOS Release : 15 Build Date: Mon 21 Feb 2005 07:17:49 PM EST Install Date: Sat 18 Jun 2005 09:25:02 PM EDT Build Host: bhrama.build.karan.org Group : Applications/System Source RPM: dosfstools-2.8-15.src.rpm Size : 69390 License: GPL Signature : DSA/SHA1, Sat 26 Feb 2005 03:34:40 PM EST, Key ID a53d0bab443e1821 Packager : Karanbir Singh kbsingh@centos.org Summary : Utilities for making and checking MS-DOS FAT filesystems on Linux. Description : The dosfstools package includes the mkdosfs and dosfsck utilities, which respectively make and check MS-DOS FAT filesystems on hard drives or on floppies.
Phil
On Tue, 2005-08-30 at 02:08 +0900, Dave Gutteridge wrote:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2 ^ ^ really really bad idea -------------------------------------|-|
If you say so. Did I mention I was a newbie? I'm a newbie. I only put in the 1 and 2 because that's what another guy on this list told me to do. I have no idea what they mean.
filesystem does not need to be dumped (field 5) and not need fsck'ing (field 6) - it is vfat right?
If vfat is the same as fat32, then yes.
I'm a little scared to go ahead with this, because I don't want to lose any more data. If I change the last two numbers, will I at least be safe from having Linux try and make changes to the hard drive?
---- Well you are asking something that I have never tried (and clearly won't at this stage) but I would have expected that the fsck subroutine should have recognized that it was a vfat partition and simply aborted rather than try to repair it - but evidently, it was trying to be helpful and repair the damaged filesystem. ;-)
I apologize for whomever told you to put the '1 2' for the fifth/sixth fields in fstab for a vfat partition. That probably wasn't a very good idea.
As for being scared...you are mounting as rw which means read/write. You could mount ro (read only) but of course, then you couldn't write stuff to it.
Craig
Okay, the current /etc/fstab file has this entry in it: /dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 0 0
When I run "mount -a", I get no errors.
But when go to the /mnt/windows directory at the command line, it's empty.
In Nautilus, I get an icon for the new drive, but if I click on it, I get that same error as before: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
I had no trouble before with CentOS detecting and using a Fat32 external hard drive, connected by firewire. Why is this drive behaving differently?
Dave
On Tue, 2005-08-30 at 11:08 +0900, Dave Gutteridge wrote:
Okay, the current /etc/fstab file has this entry in it: /dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 0 0
When I run "mount -a", I get no errors.
But when go to the /mnt/windows directory at the command line, it's empty.
In Nautilus, I get an icon for the new drive, but if I click on it, I get that same error as before: wrong fs type, bad option, bad superblock on /dev/hda, or too many mounted file systems
I had no trouble before with CentOS detecting and using a Fat32 external hard drive, connected by firewire. Why is this drive behaving differently?
---- possibilities:
- mount is not made by same user doing cd /mnt/windows - mount is not made by same user running gnome/nautilus - mount references /dev/hda1 but hard drive has different device assignment
dmesg| less #check to see if the drive is assigned a different letter df -h shows mounted filesystems and usage are you user 512? are you running mount as yourself and not root? has the drive been fixed with scandisk/checkdisk since the assault by linux fsck?
short answer, it shouldn't make a difference being connected via internal IDE or external firewire except as external firewire, it would be assigned something more like /dev/sda instead of /dev/hda
Craig
Thanks for following up.
possibilities:
- mount is not made by same user doing cd /mnt/windows
I edited /etc/fstab as root, and ran the mount -a command as root. But I have a regular user account "dave" for day to day use. But whether I am accessing /mnt/windows as root or as dave, it comes up empty.
- mount is not made by same user running gnome/nautilus
This is the case. Root is mounting the drive, and dave is running gnome/nautilus. But I'm a little confused. Only root has the permission to edit /etc/fstab or run the mount command, so how would dave access these functions? In any case, as mentioned, even root finds the directory empty.
- mount references /dev/hda1 but hard drive has different device
assignment
I assumed it was /dev/hda1 because this is what fdisk told me:
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
dmesg| less #check to see if the drive is assigned a different letter
This came up with a bunch of stuff. Is this what I'm looking for?: hda: max request size: 128KiB hda: 58633344 sectors (30020 MB) w/2048KiB Cache, CHS=58168/16/63, UDMA(66) hda: cache flushes not supported hda: hda1
df -h shows mounted filesystems and usage
[root@localhost ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/hdb1 28G 20G 6.6G 76% / none 125M 0 125M 0% /dev/shm
are you user 512?
I don't know. But I want any user of this computer - in other words, me, regardless of what permissions setting or log in account I happen to be using - to access the drive.
are you running mount as yourself and not root?
This is what happens if I do: [dave@localhost ~]$ mount -a mount: only root can do that As mentioned before, I was doing all the configurations as root, because I assumed I had to be root in order to be mucking about with the drives and whatnot.
has the drive been fixed with scandisk/checkdisk since the assault by linux fsck?
Heh heh... "assault". I like that. Anyway... I think so. I ran Windows, and it immediately complained about the disk and ran scandisk which seemed to have worked as Windows could read the files okay, or at least run the programs associated with those files. A lot of files got "assaulted", so at this point I can't be 100% sure that they've all been corrected. But from a Windows world point of view the disk has been scanned and corrected.
short answer, it shouldn't make a difference being connected via internal IDE or external firewire except as external firewire, it would be assigned something more like /dev/sda instead of /dev/hda
Okay, good to know it's not a connection issue, and more likely a settings issue.
Dave
On Tue, 2005-08-30 at 11:56 +0900, Dave Gutteridge wrote:
Thanks for following up.
possibilities:
- mount is not made by same user doing cd /mnt/windows
I edited /etc/fstab as root, and ran the mount -a command as root. But I have a regular user account "dave" for day to day use. But whether I am accessing /mnt/windows as root or as dave, it comes up empty.
- mount is not made by same user running gnome/nautilus
This is the case. Root is mounting the drive, and dave is running gnome/nautilus. But I'm a little confused. Only root has the permission to edit /etc/fstab or run the mount command, so how would dave access these functions? In any case, as mentioned, even root finds the directory empty.
- mount references /dev/hda1 but hard drive has different device
assignment
I assumed it was /dev/hda1 because this is what fdisk told me:
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
dmesg| less #check to see if the drive is assigned a different letter
This came up with a bunch of stuff. Is this what I'm looking for?: hda: max request size: 128KiB hda: 58633344 sectors (30020 MB) w/2048KiB Cache, CHS=58168/16/63, UDMA(66) hda: cache flushes not supported hda: hda1
df -h shows mounted filesystems and usage
[root@localhost ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/hdb1 28G 20G 6.6G 76% / none 125M 0 125M 0% /dev/shm
are you user 512?
I don't know. But I want any user of this computer - in other words, me, regardless of what permissions setting or log in account I happen to be using - to access the drive.
are you running mount as yourself and not root?
This is what happens if I do: [dave@localhost ~]$ mount -a mount: only root can do that As mentioned before, I was doing all the configurations as root, because I assumed I had to be root in order to be mucking about with the drives and whatnot.
has the drive been fixed with scandisk/checkdisk since the assault by linux fsck?
Heh heh... "assault". I like that. Anyway... I think so. I ran Windows, and it immediately complained about the disk and ran scandisk which seemed to have worked as Windows could read the files okay, or at least run the programs associated with those files. A lot of files got "assaulted", so at this point I can't be 100% sure that they've all been corrected. But from a Windows world point of view the disk has been scanned and corrected.
short answer, it shouldn't make a difference being connected via internal IDE or external firewire except as external firewire, it would be assigned something more like /dev/sda instead of /dev/hda
Okay, good to know it's not a connection issue, and more likely a settings issue.
Dave-
Rather than editing /etc/fstab and adding a lot of mount flags to the mix, start with the basics. Can you do the following as root:
mount -t vfat /dev/hda1 /mnt/windows
If yes, then it is a matter of working out the proper flags. If not, then the file system could be corrupt. When you try the mount command above, do you see any errors in /var/log/messages or dmesg output?
Rather than editing /etc/fstab and adding a lot of mount flags to the mix, start with the basics. Can you do the following as root: mount -t vfat /dev/hda1 /mnt/windows
[root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
If yes, then it is a matter of working out the proper flags. If not, then the file system could be corrupt. When you try the mount command above, do you see any errors in /var/log/messages or dmesg output?
This is in /var/log/messages: Aug 30 19:16:50 localhost kernel: FAT: invalid first entry of FAT (0xffffff8 != 0x1) Aug 30 19:16:50 localhost kernel: VFS: Can't find a valid FAT filesystem on dev hda1.
So it thinks it's not a valid FAT system. It seems to work okay in Windows... is there a possibility that there are different kinds of FAT32?
Dave
On Tue, 2005-08-30 at 19:21 +0900, Dave Gutteridge wrote:
Rather than editing /etc/fstab and adding a lot of mount flags to the mix, start with the basics. Can you do the following as root: mount -t vfat /dev/hda1 /mnt/windows
[root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
If yes, then it is a matter of working out the proper flags. If not, then the file system could be corrupt. When you try the mount command above, do you see any errors in /var/log/messages or dmesg output?
This is in /var/log/messages: Aug 30 19:16:50 localhost kernel: FAT: invalid first entry of FAT (0xffffff8 != 0x1) Aug 30 19:16:50 localhost kernel: VFS: Can't find a valid FAT filesystem on dev hda1.
So it thinks it's not a valid FAT system. It seems to work okay in Windows... is there a possibility that there are different kinds of FAT32?
Dave
Is this a Windows partition? If so, I would boot in Windows XP an make sure you can read the partition in Windows and run chkdsk on it via Windows XP to start with.
if it's XP it's a NTFS
Johnny Hughes wrote:
On Tue, 2005-08-30 at 19:21 +0900, Dave Gutteridge wrote:
Rather than editing /etc/fstab and adding a lot of mount flags to the mix, start with the basics. Can you do the following as root: mount -t vfat /dev/hda1 /mnt/windows
[root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
If yes, then it is a matter of working out the proper flags. If not, then the file system could be corrupt. When you try the mount command above, do you see any errors in /var/log/messages or dmesg output?
This is in /var/log/messages: Aug 30 19:16:50 localhost kernel: FAT: invalid first entry of FAT (0xffffff8 != 0x1) Aug 30 19:16:50 localhost kernel: VFS: Can't find a valid FAT filesystem on dev hda1.
So it thinks it's not a valid FAT system. It seems to work okay in Windows... is there a possibility that there are different kinds of FAT32?
Dave
Is this a Windows partition? If so, I would boot in Windows XP an make sure you can read the partition in Windows and run chkdsk on it via Windows XP to start with.
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
On Tue, 2005-08-30 at 23:30 +1200, Tom wrote:
if it's XP it's a NTFS
<snip>
It is possible to create either an NTFS or FAT32 partition in Windows XP.
The fdisk output in this case shows that it is FAT32 and not NTFS
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
Johnny Hughes wrote:
On Tue, 2005-08-30 at 23:30 +1200, Tom wrote:
if it's XP it's a NTFS
<snip>
It is possible to create either an NTFS or FAT32 partition in Windows XP.
The fdisk output in this case shows that it is FAT32 and not NTFS
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
shows how much I know about windows :)
BTW sorry for top posting before
The partition has Windows XP on it, and it boots fine and as far as I can tell operates without any problems. I don't think that drive has any intrinsic errors on it. I've run chkdisk and scandisk and defragmented the drive, and I don't know what else I can do in Windows to make sure the drive is okay. All indications are that it's alright.
I there anything else I can do Linux-side to mount this partition?
Dave
On Wed, 2005-08-31 at 01:04 +0900, Dave Gutteridge wrote:
The partition has Windows XP on it, and it boots fine and as far as I can tell operates without any problems. I don't think that drive has any intrinsic errors on it. I've run chkdisk and scandisk and defragmented the drive, and I don't know what else I can do in Windows to make sure the drive is okay. All indications are that it's alright.
I there anything else I can do Linux-side to mount this partition?
---- let's assume that it isn't mounted...(if mounted, 'umount /dev/hda1')
fdisk -l /dev/hda
does fdisk agree that it's a Fat volume? What type?
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
Craig
does fdisk agree that it's a Fat volume? What type?
umount: /dev/hda1: not mounted [root@localhost ~]# fdisk -l /dev/hda
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
I tried exactly as they said, and got the same error anyway: [root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
Dave
On Wed, 2005-08-31 at 01:43 +0900, Dave Gutteridge wrote:
does fdisk agree that it's a Fat volume? What type?
umount: /dev/hda1: not mounted [root@localhost ~]# fdisk -l /dev/hda
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
I tried exactly as they said, and got the same error anyway: [root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
Dave-
Did you try installing/booting the centosplus kernel as Johnny suggested? It might be worth giving it a shot. It could be an issue of linux seeing the drive geometry differently than windows. I must admit it is pretty odd. This usually just works.
Does XP have anything interesting to say about the partition?
On Wed, 2005-08-31 at 01:43 +0900, Dave Gutteridge wrote:
does fdisk agree that it's a Fat volume? What type?
umount: /dev/hda1: not mounted [root@localhost ~]# fdisk -l /dev/hda
Disk /dev/hda: 30.0 GB, 30020272128 bytes 255 heads, 63 sectors/track, 3649 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/hda1 * 1 3649 29310561 c W95 FAT32 (LBA)
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
I tried exactly as they said, and got the same error anyway: [root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
---- try without '-t vfat' and it will attempt to figure out the type by itself.
This is a dual-boot machine and boots into Windows from hda1?
does Windows -> Start -> Settings -> Control Panels -> Administrative Options -> Event Viewer -> System logs report anything on hard drive?
Craig
On Wed, 31 Aug 2005 at 1:43am, Dave Gutteridge wrote
does fdisk agree that it's a Fat volume? What type?
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
I tried exactly as they said, and got the same error anyway: [root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
Are you *sure* that the FS on that partition is FAT32? If this is your WinXP C: drive, I strongly suspect that it's NTFS. For that you'll need the centosplus kernel, and you'd need to 'mount -t ntfs /dev/hda1 /mnt/windows'.
On Tue, 2005-08-30 at 13:12 -0400, Joshua Baker-LePain wrote:
On Wed, 31 Aug 2005 at 1:43am, Dave Gutteridge wrote
does fdisk agree that it's a Fat volume? What type?
and I sort of agree with someone else's previous suggestion to see if you can mount it from command line first before trying to mount via fstab.
I tried exactly as they said, and got the same error anyway: [root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
Are you *sure* that the FS on that partition is FAT32? If this is your WinXP C: drive, I strongly suspect that it's NTFS. For that you'll need the centosplus kernel, and you'd need to 'mount -t ntfs /dev/hda1 /mnt/windows'.
On WinXP, go to:
Start -> Control Panel -> Administrative Tools -> Computer Management
Then click on "Disk Management"
Look at the drive and Partition in question.
What is the type? If it is "Dynamic" and not "Basic" ... you have to use the CentOS Plus kernel to mount it.
Also, you can see the "File System" in this area ... is it FAT32 for that partition?
Thanks, Johnny Hughes
I've almost got this solved.
To make a long story of experimentation short, using the check disk utility inside Windows XP was not sufficient for ensuring the partition was in working order. I had to use my trusty Win98 boot disk, and run scandisk from there, where it fixed something to do with the directory structure. And then I went back to XP and ran checkdisk, where it then found cross linked files to repair. Not that I know what a cross linked file is, but my suspicion is that this all had something to do with the assault that Linux performed on my disk when I tried to mount the drive with the wrong settings.
So where I'm at now is that I can mount the drive from the command line like so: [root@localhost ~]# mount /dev/hda1 /mnt/windows ... but only the root user can see it.
I want to be able to make it so that any user (which is almost always me, but sometimes I'm root, sometimes I'm just a user with the account "dave") can access the drive, and that it comes up in Gnome/Nautilus on boot.
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
This also only seems to give root access. "dave" can not access the drive, and it does not show up in Gnome/Nautilus.
In this thread I got a lot of different variations on what that line should read, so I'm not sure which is the best for my situation.
How do I ensure universal read/write access to the disk for all users on my computer?
Dave
On Wednesday 31 August 2005 22:10, Dave Gutteridge wrote:
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
How do I ensure universal read/write access to the disk for all users on my computer?
I currently use: /dev/hda8 /home/lowen/data vfat uid=500,gid=500 0 0
for a vfat partition. I also have given uid 500, gid 500 access to the mount point; is /mt/windows accessible to uid 512, gid 1002?
On Thu, 2005-09-01 at 11:10 +0900, Dave Gutteridge wrote:
I've almost got this solved.
To make a long story of experimentation short, using the check disk utility inside Windows XP was not sufficient for ensuring the partition was in working order. I had to use my trusty Win98 boot disk, and run scandisk from there, where it fixed something to do with the directory structure. And then I went back to XP and ran checkdisk, where it then found cross linked files to repair. Not that I know what a cross linked file is, but my suspicion is that this all had something to do with the assault that Linux performed on my disk when I tried to mount the drive with the wrong settings.
So where I'm at now is that I can mount the drive from the command line like so: [root@localhost ~]# mount /dev/hda1 /mnt/windows ... but only the root user can see it.
I want to be able to make it so that any user (which is almost always me, but sometimes I'm root, sometimes I'm just a user with the account "dave") can access the drive, and that it comes up in Gnome/Nautilus on boot.
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
This also only seems to give root access. "dave" can not access the drive, and it does not show up in Gnome/Nautilus.
In this thread I got a lot of different variations on what that line should read, so I'm not sure which is the best for my situation.
How do I ensure universal read/write access to the disk for all users on my computer?
Dave-
Since you mounted the drive as root, it is owned by root. You'll need to do some setup work to get the windows partition mounted so non-root users can access it. You can do it one of a few ways:
1) add something in /etc/fstab like
/dev/hda1 /mnt/windows vfat rw,gid=windows,umask=002 0 0
where windows is a group whose members you want to have read/write access to the partition. everything will be owned by root, but the group writes will be allowed by way of the umask setting.
2) or you can use consolehelper to allow people logged in on your machine the ability to mount and have access to the partition.
in /etc/fstab
/dev/hda1 /mnt/windows vfat noauto,user 0 0
in /etc/security/console.perms
add something like these 2 lines
<win>=/dev/hda1 /mnt/windows
<console> 0600 <win> 0660 root.disk
This should allow the person logged in on the console the rights to do a mount /mnt/windows and then have unfettered access. Of course, if another person logged in later, they wouldn't have access unless the first person unmounted the partition.
It all kind of depends on how you want to handle it. I'm sure there are other options out there.
On Thu, 2005-09-01 at 11:10 +0900, Dave Gutteridge wrote: ...
So where I'm at now is that I can mount the drive from the command line like so: [root@localhost ~]# mount /dev/hda1 /mnt/windows ... but only the root user can see it.
I want to be able to make it so that any user (which is almost always me, but sometimes I'm root, sometimes I'm just a user with the account "dave") can access the drive, and that it comes up in Gnome/Nautilus on boot.
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
Looks like you didn't read my original message thoroughly...
On Mon, 2005-08-29 at 11:55 -0400, Phil Schaffner wrote: ...
Try:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2
Adjust uid and gid for the user you want to have full access (see /etc/passwd entry), or omit for read-all write-root. [Be sure /mnt/windows exists.]
uid=512 and gid=1002 are almost certainly not those for user "dave" in /etc/passwd - more likely 500:500 as a guess. [And yes, 0 0 at the end, not 1 2 unless you want to be assaulted again by ALPHA dosfsck.]
$ grep prs /etc/passwd prs:x:512:1002:Phil Schaffner:/home/prs:/bin/bash
See what "grep dave /etc/passwd" returns and fix up /etc/fstab accordingly.
Phil
Phil Schaffner wrote:
On Thu, 2005-09-01 at 11:10 +0900, Dave Gutteridge wrote: ...
So where I'm at now is that I can mount the drive from the command line like so: [root@localhost ~]# mount /dev/hda1 /mnt/windows ... but only the root user can see it.
I want to be able to make it so that any user (which is almost always me, but sometimes I'm root, sometimes I'm just a user with the account "dave") can access the drive, and that it comes up in Gnome/Nautilus on boot.
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
Looks like you didn't read my original message thoroughly...
On Mon, 2005-08-29 at 11:55 -0400, Phil Schaffner wrote: ...
Try:
/dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 1 2
Adjust uid and gid for the user you want to have full access (see /etc/passwd entry), or omit for read-all write-root. [Be sure /mnt/windows exists.]
uid=512 and gid=1002 are almost certainly not those for user "dave" in /etc/passwd - more likely 500:500 as a guess. [And yes, 0 0 at the end, not 1 2 unless you want to be assaulted again by ALPHA dosfsck.]
$ grep prs /etc/passwd prs:x:512:1002:Phil Schaffner:/home/prs:/bin/bash
See what "grep dave /etc/passwd" returns and fix up /etc/fstab accordingly.
Phil
Could try:
/dev/hda1 /mnt/windows vfat rw,noauto,users 0 0
if you want it accessible for all users ....
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On Thu, Sep 01, 2005 at 11:10:04AM +0900, Dave Gutteridge wrote:
I've almost got this solved.
To make a long story of experimentation short, using the check disk utility inside Windows XP was not sufficient for ensuring the partition was in working order. I had to use my trusty Win98 boot disk, and run scandisk from there, where it fixed something to do with the directory structure. And then I went back to XP and ran checkdisk, where it then found cross linked files to repair. Not that I know what a cross linked file is, but my suspicion is that this all had something to do with the assault that Linux performed on my disk when I tried to mount the drive with the wrong settings.
So where I'm at now is that I can mount the drive from the command line like so: [root@localhost ~]# mount /dev/hda1 /mnt/windows ... but only the root user can see it.
I want to be able to make it so that any user (which is almost always me, but sometimes I'm root, sometimes I'm just a user with the account "dave") can access the drive, and that it comes up in Gnome/Nautilus on boot.
Here is what I currently have in /etc/fstab: /dev/hda1 /mnt/windows vfat rw,uid=512,gid=1002 0 0
Try adding umask=0
[]s
- -- Rodrigo Barbosa rodrigob@suespammers.org "Quid quid Latine dictum sit, altum viditur" "Be excellent to each other ..." - Bill & Ted (Wyld Stallyns)
On Tue, 2005-08-30 at 06:27 -0500, Johnny Hughes wrote:
On Tue, 2005-08-30 at 19:21 +0900, Dave Gutteridge wrote:
Rather than editing /etc/fstab and adding a lot of mount flags to the mix, start with the basics. Can you do the following as root: mount -t vfat /dev/hda1 /mnt/windows
[root@localhost ~]# mount -t vfat /dev/hda1 /mnt/windows mount: wrong fs type, bad option, bad superblock on /dev/hda1, or too many mounted file systems
If yes, then it is a matter of working out the proper flags. If not, then the file system could be corrupt. When you try the mount command above, do you see any errors in /var/log/messages or dmesg output?
This is in /var/log/messages: Aug 30 19:16:50 localhost kernel: FAT: invalid first entry of FAT (0xffffff8 != 0x1) Aug 30 19:16:50 localhost kernel: VFS: Can't find a valid FAT filesystem on dev hda1.
So it thinks it's not a valid FAT system. It seems to work okay in Windows... is there a possibility that there are different kinds of FAT32?
Dave
Is this a Windows partition? If so, I would boot in Windows XP an make sure you can read the partition in Windows and run chkdsk on it via Windows XP to start with.
Windows also has Dynamic disk partitioning, which the normal 2.6 Linux kernel does not support. If that disk is a Dynamic partition, you may need to use the CentOS Plus ( http://mirror.centos.org/centos/4/centosplus/ ) kernel to use that partition. I have never had to do this with FAT32, but it is a possibility.
On Tue, 2005-08-30 at 11:08 +0900, Dave Gutteridge wrote:
Okay, the current /etc/fstab file has this entry in it: /dev/hda1 /mnt/windows vfat rw,noauto,user,uid=512,gid=1002 0 0
When I run "mount -a", I get no errors.
But when go to the /mnt/windows directory at the command line, it's empty.
noauto tells mount -a to ignore it. Also, you should remove user if you're specifying uid and gid.