Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 04-19-2007, 08:37 AM   #1
LQ Newbie
Registered: Apr 2007
Posts: 7

Rep: Reputation: 1
Lightbulb new fstab mount option guide for fixed drives - suggestions/mistakes?

(note: I started this thread at, but it hasn't been getting much response there. I'm hoping it will fit in better here. is also a related post in the SUSE forums.)

I've been reading various tutorials on fstab and mounting, but I still don't really understand. There are varying ways to achieve the same end results -- and nowhere among the most popular general fstab guides/tutorials are there many examples of typical partition types and their common mount strategies.

So, what I would like to do is to make a different kind of guide. I'd like to compile a list of typical partition types and common fstab entries for them and give concise explanations for why each element is chosen. I will edit this as feedback comes in and it will essentially publish itself here.

If this kind of guide already exists, it is well hidden. So, please, help me form this into something useful If this ever gets done -- done well, please feel free to post this somewhere else or to translate the commentary. Please do link back to this as the source and help me keep this thread updated. Email me (conquest [at] spamcop [dot] net) if the thread gets old and you'd like to see an alteration of the top post. Maybe making a wiki would be good for this too. I'll do that if it seems appropriate.

Situation 1: Windows partitions (NT, 2000, XP, 2003, Vista)
/dev/xxxx   /media/mountpoint   ntfs   user,ro,auto   0   0
(user allows anyone to mount, ro makes it read-only since ntfs is a MS-protected format, auto mounts it at boot automatically)
/dev/xxxx   /media/mountpoint   ntfs   nls=utf8,umask=0222   0   0
(nls=utf8 includes unicode for non-English users, umask=0222 (-r-xr-xr-x) does what?)
/dev/xxxx   /media/mountpoint   ntfs   defaults,nls=utf8,umask=007,gid=46   0   1
(nls=utf8 includes unicode for non-English users, umask=007 ??? Makes for 659 permissions?, gid=46 ??? )

Situation 2: ntfs data partitions (generally from Windows):
(same as above???)
Situation 3: fat-32 data partitions (ideal shared partition between linux, windows, and apple's mac os):
/dev/xxxx   /media/mountpoint   vfat   iocharset=utf8,umask=000   0   0
(iocharset=utf8 includes unicode for non-English users, umask=000 allows most liberal file permissions)

Situation 4: ext3 data partitions (partitions shared between different linuxes, mac osx, and even Windows (using "Ext2 Installable File System for Windows", for example)):
I don't know. I can find no examples of this on the fstab tutorials.
/dev/xxxx   /media/mountpoint   ext3   defaults   0   2
Situation 5: other linuxes themselves, their root partition:
again, maybe
/dev/xxxx   /media/mountpoint   ext3   defaults   0   2
The format of fstab is also changing, from something like this:
/dev/sda2   /media/sda2   ntfs   defaults,nls=utf8,umask=007,gid=46   0   1
to something like this:
# /dev/sda2
UUID=9068AF8E68AF7220   /media/sda2   ntfs   defaults,nls=utf8,umask=007,gid=46   0   1
However, I cannot find any authoritative links on this: (My device are now "sda" than "hda") (ide drives show up as special device)
Can anyone point out where this transition is explained, please? An announcement somewhere?

Thank you,
Greg Conquest

key phrases: typical mount options, example fstab's, example fstab,

umask (linux permissions)
gid ('s short note on GID)
uuid (man page for uuid)
mount (man page for mount)

more links: (top guide according to google -- no fixed-drive examples are given, though) has several example fstab entries, but it has little to no explanation of those mount options. (another fstab tutorial)

Last edited by gregconquest; 04-22-2007 at 11:22 PM.
Old 04-20-2007, 04:43 PM   #2
Registered: Feb 2004
Location: Homeless
Distribution: PCLinuxOS
Posts: 170

Rep: Reputation: 30
you forgot
Old 04-20-2007, 09:30 PM   #3
LQ Newbie
Registered: Apr 2007
Posts: 7

Original Poster
Rep: Reputation: 1

I have found the source of one of my fstab problems. Two different partitions on my system, sdc2 and sda2, have the same UUID! I tried sdc1 and sda1 just to compare two other partitions on the same drives. Their UUID's are fine.

$ sudo vol_id -u /dev/sdc2
$ sudo vol_id -u /dev/sda2
$ sudo vol_id -u /dev/sdc1
$ sudo vol_id -u /dev/sda1
What is wrong? I didn't set the UUID's.

Below I manged to change the LABEL of one the partitions, so they do have different labels and /dev/sdxx ID's, but the UUID remains non-unique.
$ sudo e2label /dev/sdc2              <-- checking label
ubuntu                                <-- results
$ sudo e2label /dev/sda2              <-- checking label
ubuntu                                <-- results, same label
$ sudo e2label /dev/sda2 OStest3      <-- changing label
$ sudo e2label /dev/sda2              <-- checking label
OStest3                               <-- results, label successfully changed
$ sudo e2label /dev/sdc2              <-- checking label
ubuntu                                <-- results, still OK
$ sudo vol_id -u /dev/sda2            <-- checking UUID
183edeb8-2557-4475-99fd-b4e71c22391b  <-- results
$ sudo vol_id -u /dev/sdc2            <-- checking UUID
183edeb8-2557-4475-99fd-b4e71c22391b  <-- results, two partitions, two labels, one UUID
Now I'm really confused. Even though I set these partitions label according to the above, when they are mounted under kubuntu, they are reversed (ignore the sdd2 and sdb2 here. They seem to change per install, application reading them, boot, . . .):
# kubuntu's fstab (section)
# /dev/sdb2     UUID=183edeb8-2557-4475-99fd-b4e71c22391b     (another linux installation)
LABEL=ubuntu     /media/ubuntu ext3    defaults        0       2
# /dev/sdd2  WRONG UUID   UUID=183edeb8-2557-4475-99fd-b4e71c22391b     (for testing installs)
LABEL=OStest3      /media/OStest3 ext3    defaults        0       2
In Konqueror, though, the drives are reversed. I booted into ubuntu and put a folder in root called, 0_ubuntu_desu. From within kubuntu, however, this folder shows up in the root of OStest3.

I am confused. Using UUID should free me from these changing IDE/SATA designations.

At a loss

PS Nishtya, I'm trying to work this out at and then posting the results here. has been on the other post, but thanks for the pointer.

Last edited by gregconquest; 04-21-2007 at 08:28 AM.
Old 04-21-2007, 09:55 PM   #4
LQ Newbie
Registered: Apr 2007
Posts: 7

Original Poster
Rep: Reputation: 1
Smile UUID issue resolved

I found out what had caused the duplicate UUID. I had used BootIt NG to essentially clone a partition (image and paste in BootIt terms). I cloned ubuntu as OStest3. Thus, both had the same UUID. I reformatted OStest3 and it now has its own UUID.

I also noticed in all this that since I didn't alter root's entry in fstab, that I was actually using BootIt to boot into one partition, and then having another actually running! OStest3 was going to ubuntu or vice versa.

I need to figure out the limitations and dangers on cloning partitions with BootIt, but the damage here has apparently all been undone

Now I can get back to creating my optimal, annotated fstab along with example mountings -- and a few suggestions on using UUID vs. LABEL vs. /dev/sdxx.

Thanks for the help,


examples, fstab, guide, mount, options, tutorial

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Make removable USB hdd mount at fixed mount point ctkroeker Linux - General 13 08-11-2009 09:49 AM
fstab problem: mount: can't find dvd in /etc/fstab or /etc/mtab Nikon01 Slackware 5 11-17-2006 07:15 AM
Definitive Guide to Life suggestions rusty_slacker General 106 02-07-2006 04:53 PM
[mtent] line 7 in /etc/fstab is bad (CD Drives wont Mount) shof515 Linux - Hardware 1 11-24-2005 09:57 AM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:08 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration