HOWTO: Mount a File System
My most recent posts talk about the fstab file, mount options, and file system types. Now that we have those things out of the way, we can talk more in depth about mounting a file system.
There are three things that the system needs to know in order to mount a file system (like a USB drive or CDRom drive):
- The device name: such as /dev/sda
- The mount point: such as /media/usbstick
- The file system: such as vfat
Some, or all, of these things may be contained on the fstab file and if so, then you don’t need to specify them at mount time. If you’re mounting a file system totally unknown to your system (meaning it’s not in the fstab), then you’ll have to specify all of them.
For example, consider the situation where the following line is present in your fstab file:
/dev/sdb /usb msdos defaults 0 0
In this example, sdb is a USB stick formatted with the msdos file system. Since it is present in my fstab file, I could mount it in the following ways:
- mount /dev/sdb
- mount /usb
and access the stick at /usb. If I wanted to mount this stick and it wasn’t in the fstab file, then I would have to specify everything, as in:
mount -t msdos /dev/sdb /usb
Make sense?
Related Stories
POSTED IN: How To
0 opinions for HOWTO: Mount a File System
No one has left a comment yet. You know what this means, right? You could be first!
Have an opinion? Leave a comment: