Showing posts with label windows. Show all posts
Showing posts with label windows. Show all posts

Sunday, April 15, 2007

Mounts, folders and partitions

One of the better features of the Unix filesystem is the way in which it is designed. There are no drives such as in Windows "C:, D:, G: etc." but rather it is designed with a lot more flexibility. The base filesystem is your "/" or root directory is where everything else goes, it is similar to a tree's roots. From the root you can navigate to other places. /boot is where the files necessary to start the system are kept, your kernel images, initial ram disks and boot menu. /usr is similar to the "Program Files" directory in windows. /home relates to the "Documents and Settings" directory in windows. What's the point? the point is that these filesystems: /boot /usr /home, don't have to be in the same partition. This makes maintenance a breeze, add in logical volumes and NFS mounts and resizing filesystems becomes quite easy. It would even be possible to boot an entire system without a hard drive. "Big deal, live CDs don't use the hard drive either!" the big deal is that you can't save anything on a CD and it runs slower, NFS mounts are real hard drives that reside on a different server. Place the /home filesystem on an NFS mount and everything in a users home directory follows them without having to copy it across the network everytime they log in. Using network booting with PXE you are guaranteed that all workstations in your network have the same software installed everywhere without having to image a ton of hard drives. You could have just the root filesystem: /{root} /boot /bin and /sbin, reside on the workstation and have everything else as an NFS mount. This would ensure that if all the workstations were not the same hardware they would have specific drivers for each machine while still maintaining the same base applications.

Flexibility is increased when you use logical volumes. A logical volume is a group of physical drives treated as a single drive. It can be partitioned just like a physical drive, with the exception that physical drives can be added or removed (space permitting). It does slow down access slightly but the benefit of adding space when needed is worth the extra overhead.

Windows just recently added the ability to mount partitions onto empty folders. This is still pale when compared to the unix filesystem. You can't mount a separate partition for Documents and Settings or Program Files. If your Windows system goes down, gets a virus, or becomes unstable or unusable in any way and you end up having to reformat your C:\ drive everything on the partition is lost. You can avoid that in unix by having your /home mounted elsewhere.

Just another reason to drop windows.

More to follow....