quote:
Original post by CProgrammer
Yes how is it with accessing files in the other os's partition. I mean that would be usefull. Say I use Gentoo. How is it there. Would I have problems accessing eachothers data. Plus why cant I use the same File Format for both partitions. If not why doesnt Linux support the other file system?
-CProgrammer
All partitions have a "device" associated with them. You can access the device nodes in the /dev/ directory. When Linux sees your hard drive, it creates nodes in the /dev/ directory so you can work with them. The device node /dev/hda1 is the first partition on your first physical disk; /dev/hda2 is the second (most likely extended) partition on the same disk; /dev/hda3 is the third partition; /dev/hda4 is the fourth. If you have more then one disk installed, then there will be nodes created with a different letter like /dev/hdb1, /dev/hdb2, /dev/hdb3.
Linux accesses data on partitions by mounting it to a mount point (a directory, basically). Once you mount a partition to a mount point, then the contents of that directory will be the contents of the hard drive FOR THE TIME IT IS MOUNTED. Once un-mounted, the directory will point to its previous mounted device. Someone correct me if I am wrong, I have never done this but read that is how it is done.
So to access some FAT32 partition, you would need to do the following:
Create a directory to mount it to:
mkdir /mnt/windows
Mount the partition to the directory (mountpoint):
mount -t msdosfs /dev/hda1 /mnt/windows
the -t tells mount what type of file system the partition has. You can use "
auto
" as the type, it will try to guess.
After you mount, then /mnt/windows should have all of the contents of the partition. You might need to play around with the mount flags to get exactly what you want (like read/write flags.)
You can install Linux on a FAT32 partition, IIRC, since the FAT32 file system is completely supported in the Linux kernel.
[edited by - aftermath on April 20, 2004 1:16:21 AM]