Hello all!
On my computer there are two operating systems: Windows and Debian. I needed to set up a fat32 partition that both OS-es can use as common partition.
To create this fat32 partition you have many possibilities. You can use a third party software as Partition Magic; a Linux Live CD as Knoppix; or you can use the Debian installer while installing your OS.
I chose the last method since I had to reinstall the whole system (Win XP and Linux). While installing, I didn't choose for the fat32 to be mounted and decided to do that manually.
I don't know if there is a way for manual mounting so that it will be mounted automatically, but everything else works
So, you'll have to edit /etc/fstab as user root.
My file has a line like this:
/dev/sda8 /home/bocskai/transport vfat rw,user,noauto,async 0 0 (watch out for the update on bottom of this post)
We have some columns here. All of them are divided by at least one space character.
The first column describes which device and partition are we mounting. In my case there is a SATA hard drive with the 8th partition (believe me, I need that number of parts )
Second column: where is it going to be mounted. You can choose a custom folder where the files will appear. By default, the system partition and the windows part is mounted outside our Home directory. In the case of fat32 we make an exception to ease our work, so we mount it in a folder inside our Home.
3rd column: type of partition. In Linux, fat32 is known as "vfat"
4th column: rw = read/write access permissions
5th col: user = user may mount partition
6th col: noauto = partition will not be mounted automatically. My system tends to mount is as root and this way the user has no write access (if someone knows a better way, pls IM me)
7th col: async = asynchronous mode. File will appear on file allocation table after it has been written/deleted to/from partition (syn is used at floppies and network file systems)
Column 8 and 9 have a value of zero.
After editing the fstab file, create the folder where you want the fat32 to be mounted.
Reboot the system.
After startup, mount the fat32 manually (KDE users will find it easy because they'll have to launch Konqueror, choose Storage media, then click on the fat partition).
For more information, go to http://www.tuxfiles.org/linuxhelp/fstab.html
Any feedback and correction is welcome.
UPDATE:
My /etc/fstab file has been modified using Isaac Kuo's informations:
/dev/sda8 /home/bocskai/transport vfat rw,auto,async,umask=0000 0 0
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
How to mount fat32 partition
To do what you really want to do, you should probably automount using something this /etc/fstab entry:
/dev/sda8 /home/bocskai/transport vfat rw,auto,async,umask=0000 0 0
With this umask, all files and directories are given 777 permissions. In other words, everyone can read/write/execute everything. For a typical desktop computer, this is typically appropriate.
As you note, an automounted fstab entry will be mounted by root. This is okay, since all of the contents are given 777 permissions due to the umask option.
/dev/sda8 /home/bocskai/transport vfat rw,auto,async,umask=0000 0 0
With this umask, all files and directories are given 777 permissions. In other words, everyone can read/write/execute everything. For a typical desktop computer, this is typically appropriate.
As you note, an automounted fstab entry will be mounted by root. This is okay, since all of the contents are given 777 permissions due to the umask option.
Isaac Kuo