Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
By mcd at 2003-09-01 01:55
This is to help create a functioning FAT32 (vfat) partition to be shared between your linux and windows OS's. For simplicity, i'll assume that you're using hda1 for windows, hda2 as an extended partition for linux with hda5,6 and 7 for /, /usr, and swap contained as logical sub-partitions. That's a normal setup. Now you'll want to create a new partition using fdisk. Some people seem to be afraid of this, but i find it very easy to use. First, go to the command line and as root type:
this will take you to single user mode, which means disks aren't usually mounted and stuff like that (it's not a good idea to try and format a disk that's already mounted and in use). type:
this will take you into the menu-driven fdisk program. type:
to list your current partitions, and take a moment to familiarize yourself with the setup. an i.d. of 83 is an ext3 linux native partition, i.d. 82 means a linux swap partition.
Now you want to create a new primary partition, with a file system type FAT32 (this can be easily accessed by both OS's) to do this, type:
n <---- create new partition
p <---- primary
3 <---- label it hda3 (3rd primary)
At this point it'll ask for first and last sector, which will default to first available sector and last available sector (take up any free space left), if you want to control the size yourself, say create a 5 gigabyte partition, accept the first default, then type +5000M
Now change the fs type with
c <---- this specifies vfat filesystem
and review what you've done with 'p' to make sure everything is the way you want it. If you're satisfied, use 'w' to write the partition table to disk, and exit fdisk. (WARNING: this will write the partition table to disk, make sure you haven't changed any of your old partitions)
At this point you need to format the new parition, which can be done with mkfs, although i had to download dosfsutils because slackware didn't come with mkfs.vfat (FAT32) included. If you are missing this package, try the following link to download the rpm (i'm still looking for a good source package).
Either way, in the end the command should look something like this:
mkfs -t vfat /dev/hda3
Assuming that works, there's just one thing left to do: edit your /etc/fstab to automatically mount the new partition on boot. Use emacs, vi or whatever editor you're familiar with, and add the following line:
/dev/hda3 /mnt/windows defaults,umask=000 0 0
There are actually several different sets of options you could use in place of defaults, but i have this setup and it so far it works extremely well for me. Type:
mount -a or mount /dev/hda3
and presto!, you should be able to read and write to this partion from linux or windows!
Well, there you go. I apologize if that's more detail than you wanted, but it's best to have the info and not need it, than the other way around.
If anything goes wrong, or you have questions, post up.