LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-14-2004, 11:56 PM   #1
shahab_faghihi
LQ Newbie
 
Registered: Oct 2004
Location: Iran , Tehran
Distribution: Mandreck
Posts: 4

Rep: Reputation: 0
Accessing FAT32 from linux


Hi.
On here someone ( i dont remember his/her name ) told me linux can access FAT32 drives . they should be in /mnt part , right ?
but i cant see my FAT32 Drives in my /mnt part ...
I should add that i have 2 hard disk ( both connected ) which there is a winxp on one of them & a fedora core 1.0 on the other ....
Winxp h.d.d > 2 NTFS & 1 FAT32
Fedora h.d.d > 2 ext3 & 1 Swap

with regards .
 
Old 10-15-2004, 12:44 AM   #2
ranger_nemo
Senior Member
 
Registered: Feb 2003
Location: N'rn WI -- USA
Distribution: Kubuntu 8.04, ClarkConnect 4
Posts: 1,142

Rep: Reputation: 47
Some distros will set up to access any Windows partitions they find at installation. Some don't. Read my reply to the following post for some help...
<< http://www.linuxquestions.org/questi...threadid=54672 >>

You will need to use a different /dev/ though. Internal, IDE drives are /dev/hdX . The primary master is hda, the primary slave is hdb, the secondary master is hdc, and the secondary slave is hdd. You will also need to choose the correct partition number. You can find what partitions are on the drive with the command...
fdisk -l /dev/hda

Replace the hda with the correct drive reference. It will list all the partitions on the drive, and give info about them, including filesystem type. Create whatever mount-point you want... It's just an empty directory that the partition gets mounted to.
 
Old 10-15-2004, 06:03 AM   #3
falcon79
LQ Newbie
 
Registered: Jun 2004
Posts: 15

Rep: Reputation: 0
This depends on your configuration.
Look at your /etc/fstab file: this is a mapping between devices (eg /dev/hda2) and mount points (eg /mnt/win)
Your man page can give you the fstab format.
Moreover, if you need to know what is your fat32 partition, use fdisk
After this configuration, you can freely mount any partition to any path (almost :-))
 
Old 10-15-2004, 11:13 AM   #4
coolpyrofreak
Member
 
Registered: Mar 2004
Location: Las Vegas, NV
Distribution: Arch Linux
Posts: 103

Rep: Reputation: 15
do this as root:

mkdir /mnt/windows (or whatever you wanna call it)
mount -t vfat /dev/hda1 /mnt/windows (where /dev/hda1 is your windows hard drive. replace with the appropriate nameif necessary)

if you want to automatically have the drive mounted on boot, add this line to your /etc/fstab file, in the appropriate columns:

/dev/hda1 /mnt/windows vfat defaults 0 0

where /dev/hda1 is your windows drive, /mnt/windows is where you want to mount it, and vfat is the file system.
 
Old 10-15-2004, 11:24 AM   #5
Gethyn
Member
 
Registered: Aug 2003
Location: UK
Distribution: (X)Ubuntu 10.04/10.10, Debian 5, CentOS 5
Posts: 900

Rep: Reputation: 32
I set up a FAT32 partition that was accessible to Linux and Windows the other day. Found the default setting in fstab (as described by coolpyrofreak) didn't work though, had to replace "default" with "umask=000". Otherwise, i couldn't write to the partition as anything other than root, and couldn't change the permissions to allow people other than root to write to it either...
 
Old 10-15-2004, 01:56 PM   #6
tutwabee
Member
 
Registered: Jan 2004
Location: California
Distribution: Ubuntu 10.04
Posts: 145

Rep: Reputation: 15
Quote:
Originally posted by coolpyrofreak
do this as root:

if you want to automatically have the drive mounted on boot, add this line to your /etc/fstab file, in the appropriate columns:

/dev/hda1 /mnt/windows vfat defaults 0 0
is the file system.
You may want to make "defaults" "defaults,user" so normal users can mount it.
 
Old 10-15-2004, 10:20 PM   #7
coolpyrofreak
Member
 
Registered: Mar 2004
Location: Las Vegas, NV
Distribution: Arch Linux
Posts: 103

Rep: Reputation: 15
i never knew what that was for. i just stuck it in there because my /mnt/cdrom entry had the same thing. ::shrugs:: i guess i know what it's for now. thanks.
 
Old 10-16-2004, 08:33 AM   #8
echo77
Member
 
Registered: Jun 2004
Location: Goa, India
Distribution: Fedora Core 2
Posts: 34

Rep: Reputation: 15
Thanks for the fstab stuff. I was getting bored of mounting it every time I needed to access it.
 
Old 10-16-2004, 01:14 PM   #9
Robert G. Hays
Member
 
Registered: Jan 2003
Location: Atlanta, Ga., USA
Distribution: Gentoo, Mandrake, ~others
Posts: 157

Rep: Reputation: 30
One other thought -- if you need the win-partition mounted only sometimes, and especially if, like me, you have a multitude of win-parts, what I did was to create tine shell scripts (aliases in your shell-config files works too) :

mntwc contains the "mount /dev/hdxn /somewhere" command;
umntwc contains the umount command;
both for my Win C: drive ( I have Win C: throurh K:, Dos C: through H:, and an emergency Win-as-Dos partition !! )
I also have mntwd, umntdd, etc, AND I have mntw & umntw, which mount & umount all the Win-parts.
having them NOT mounted most of the time can save Lots! of time, but when I need one Or More of them, its just **real** easy to mount & umount them.

Best!

rghays
 
Old 10-17-2004, 01:30 AM   #10
echo77
Member
 
Registered: Jun 2004
Location: Goa, India
Distribution: Fedora Core 2
Posts: 34

Rep: Reputation: 15
I had written scripts. But I was bored of running them everytime I wanted to access (yeah, I'm that lazy). Now I get the partitions on the Desktop everytime. Thanks!
 
Old 10-26-2004, 02:52 PM   #11
darist
LQ Newbie
 
Registered: Aug 2004
Distribution: RedHat 8.0 - 2.4.18-14 - Athlon - laptop
Posts: 2

Rep: Reputation: 0
You can also mount NTFS partitions

Hi there,

I thought some of you may be interested to know that you can also mount NTFS partitions, so you can use the partition (drive) where you installed Windows XP (for example) from Linux.

The only thing is that in my setup, I am unable to write to the partition, I can only read it...

When I first started thinking about accessing my NTFS partition from linux, I thought that I had to recompile the kernel. I am just not comfortable enough yet to start messing with the kernel. I found this other solution that works great and you don't have to recompile the kernel!

Check out this SourceForge project:
http://linux-ntfs.sourceforge.net/

It was easy to install given their instructions and it works great.

David
 
Old 03-25-2006, 02:20 PM   #12
plewkonia
LQ Newbie
 
Registered: Mar 2006
Posts: 3

Rep: Reputation: 0
Bit of Linux newbie, but I'm having some troubles getting my FAT32 partition to mount automtically. Fedora 4 installed on a dual boot system. If I mount the drive manually, I have no problems.

sda is my windows drive
sdb1 is my swap, sdb2 is my linux ext3 partition, and sdb3 is my fat32 partition.

Using: "/dev/sdb3 /mnt/fat32 vfat users,default,unmask=000 0 0" in my /etc/fstab gives me an error: "wrong fs type, bad option, bad superblock on /dev/sdb3" at startup

Any ideas what I might be wrong?

Last edited by plewkonia; 03-25-2006 at 02:28 PM.
 
Old 03-25-2006, 04:17 PM   #13
michaelk
Moderator
 
Registered: Aug 2002
Posts: 16,028

Rep: Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851
The option is defaults not default. BTW defaults combines a number of options and in this case will over ride users. See man pages for details.

Try umask=000,users
 
Old 03-25-2006, 06:58 PM   #14
plewkonia
LQ Newbie
 
Registered: Mar 2006
Posts: 3

Rep: Reputation: 0
Thanks. Fixed that ... but still getting the file system type error.

fstab reads:

Code:
LABEL=/                 /                       ext3    defaults        1 1
/dev/devpts             /dev/pts                devpts  gid=5,mode=620  0 0
/dev/shm                /dev/shm                tmpfs   defaults        0 0
/dev/proc               /proc                   proc    defaults        0 0
/dev/sys                /sys                    sysfs   defaults        0 0
LABEL=SWAP-sdb2         swap                    swap    defaults        0 0
/dev/sdb3               /mnt/fat32              vfat    unmask=000,users
/dev/hdb                /media/cdrecorder       auto    pamconsole,exec,noauto,managed 0 0
/dev/hda                /media/cdrecorder1      auto    pamconsole,exec,noauto,managed 0 0
Any help?
 
Old 03-25-2006, 10:28 PM   #15
michaelk
Moderator
 
Registered: Aug 2002
Posts: 16,028

Rep: Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851Reputation: 1851
The option is umask not unmask
 
  


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
accessing a linux partition from a fat32 partition? abtimoteo Ubuntu 4 09-19-2005 10:41 PM
Accessing FAT32 files rknetsch Linux - Newbie 3 06-16-2005 11:40 AM
Accessing Fat32 partition through linux from the network Raidflex Linux - Networking 8 12-11-2003 05:48 PM
Accessing my FAT32 through Linux? Deathspawner Linux - Software 5 12-06-2003 08:36 PM
Accessing FAT32 partitions from Linux (on the same pc!) KlaymenDK Mandriva 9 10-11-2003 10:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:54 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration