This site is now 100% read-only, and retired.

What is your /etc/mtab?

Submitted by mcortese on Wed 23 Dec 2009

a regular file  <-> 58% 1096 votes
a link to /proc/mounts  <-> 29% 543 votes
something else...  <-> 9% 181 votes
Total 1864 votes

 

 

 

Re: What is your /etc/mtab?
Posted by xrat (62.178.xx.xx) on Sat 26 Dec 2009 at 12:19
Interesting poll! Mine are regular files but if I want to see what is mounted I rarely use "mount", instead I do a "cat /proc/mounts". -- Andreas

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (70.105.xx.xx) on Sun 3 Jan 2010 at 05:02
Interesting...
What actually is the "something else"?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (203.141.xx.xx) on Fri 22 Jan 2010 at 10:34
Can someone tell me which distors have a link to the /proc/mounts.
and which is more advantageous. Thanks in advance :D.

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (74.97.xx.xx) on Tue 26 Jan 2010 at 01:32
Could someone list the actual different types of mtab?
Is BSD mtab different than Debian Linux mtab?
How many ways has mtab been done?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (74.97.xx.xx) on Tue 26 Jan 2010 at 01:56
http://www.linuxchix.org/content/courses/filesystem/Lesson5.html
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=494001
http://lkml.indiana.edu/hypermail/linux/kernel/0303.0/0415.html
Some discussions about mtab.
Still not really showing any other kind of mtab: file or link.
Is there anything else out there?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (98.111.xx.xx) on Sat 13 Feb 2010 at 18:50
82 votes for something else.
What are those something elses?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (24.60.xx.xx) on Thu 18 Feb 2010 at 19:21
My guess is windows users are voting.

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (98.111.xx.xx) on Fri 19 Feb 2010 at 23:05
Windows has /etc/mtab ?
Never knew that before.

[ Parent ]

Re: What is your /etc/mtab?
Posted by st_iron (145.236.xx.xx) on Wed 14 Apr 2010 at 16:46
[ View Weblogs ]
LOL
No! I think it was sarcastic. :)

[ Parent ]

Re: What is your /etc/mtab?
Posted by itsec (78.54.xx.xx) on Sun 21 Feb 2010 at 19:14
[ View Weblogs ]
Something else is a regular file that is automatically written to after mounting. So the content is dynamic but it is a regular file.

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (96.253.xx.xx) on Tue 23 Feb 2010 at 22:28
(A regular file which is automatically updated)
Yes I know that from the manpages.
But I consider this poll's three choices to be totally different ways of implementing /etc/mtab.
I have used Slackware,RedHat,SUSE,Turbo,etc. as far back as about 1993.
Also the three BSD's, Net, Free and Open.
Currently I have only been using Debian stable since Potato.
I do not recall any of those distros using anything that fits the something else category.
The question is: What is something else?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (96.253.xx.xx) on Wed 3 Mar 2010 at 23:18
O.K. I'm sort of patient.
But I'm still waiting to find out what those "something else" is/are.
Anybody care to describe a something else /etc/mtab?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (93.36.xx.xx) on Fri 5 Mar 2010 at 22:33
Something else: maybe a pipe?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (77.215.xx.xx) on Tue 9 Mar 2010 at 00:19
My something else: A symlink to a regular file in a writable directory (on tmpfs!), plus a local patch to mount so it doesn't mishandle this case.

Making it a symlink to a different dir allows /etc to be read only when not in the process of reconfiguring the system.

Making it point to a regular file rather than /proc/mounts enables mount features that store information in /etc/mtab not known to the kernel, such as which user mounted a cdrom, the loop mount logic and bind mounts.

Placing the regular file on tmpfs prevents old data from surviving a reboot and allows mtab to work before / or any other persistent file system has been mounted read only later in the boot process.

[ Parent ]

Re: What is your /etc/mtab?
Posted by mcortese (20.142.xx.xx) on Fri 12 Mar 2010 at 11:06
[ View Weblogs ]
Making it point to a regular file rather than /proc/mounts enables mount features that store information in /etc/mtab not known to the kernel, such as which user mounted a cdrom, the loop mount logic and bind mounts.
I think what you're saying was true in the past. There's no additional info in /etc/mtab than in /proc/mounts today. See Debian Bug #494001

[ Parent ]

Re: What is your /etc/mtab?
Posted by paulgear (202.45.xx.xx) on Tue 9 Mar 2010 at 02:36
Where's the Cowboy Neal option? Or the "wouldn't have a clue" option?

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (98.111.xx.xx) on Thu 25 Mar 2010 at 22:14
Perhaps the question should be:
Which *nix distributions actually use the something else option?
Does anyone know of an online published comparison of implemented methods?
This is an interesting poll; if only it had more feedback.
Thanks Steve, very usefull site.

[ Parent ]

Re: What is your /etc/mtab?
Posted by mcortese (20.142.xx.xx) on Mon 29 Mar 2010 at 18:13
[ View Weblogs ]
I think that "something else" was chosen by those who implemented their own nasty tricks to circumvent the limitations that /proc/mounts used to have in the past (namely the lack of info necessary for some kind of special mounts like loops, user mounts, etc.) but still wanted a read-only /etc.

I think that writing "stateful" data to a file in /etc is really ugly, and only understandable as a heritage of the old UNIX days. Just look at all the -n flags added to mount commands in various init scripts! This extra complexity wouldn't be needed, had /proc/mount worked correctly since the beginning.

[ Parent ]

Re: What is your /etc/mtab?
Posted by Anonymous (79.119.xx.xx) on Sat 3 Apr 2010 at 20:54
Actually those who voted 'something else' never checked the contents of that dir, or they are too drunk to do tha now (my case).

Ah yes, it's a file that lists the currently mounted media...

[ Parent ]