Auto Mount Partitions on Boot (also Windows partitions)

Write tutorials and howtos in here
There are more tutorials here http://community.linuxmint.com/tutorial/welcome
Forum rules
Do not start a support topic here please. Before you post please read this

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby tokyo-joe on Sun Mar 18, 2012 10:35 am

I figured out how to solve my problem in Linux Mint 12.
Go to System Settings > Removable Media, and check "Don't ask how to deal with removable media" (this is my translation from the message in Japanese, it might be slightly different in the original language).

Self-solved.
tokyo-joe
Level 1
Level 1
 
Posts: 3
Joined: Sun Jun 26, 2011 12:11 am

Linux Mint is funded by ads and donations.
 

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby leskieurbiker on Sun Jun 03, 2012 8:26 pm

This post should be marked as STICKY. It's the easiest way to automount NTFS drives. The instructions are very clear. Thanks to Fred.

I tried before but could'nt make it with PYSDM: this software is supposed to make easier but it did'nt show all my NTFS partitions, so it was useless.

Follow the instructions on the original post and you're done!
I'm a Linux Mint 17 x64 Cinnamon user 99,5% of the time and very happy with it!
leskieurbiker
Level 1
Level 1
 
Posts: 23
Joined: Tue Feb 07, 2012 9:59 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby proxima_centauri on Mon Jun 04, 2012 6:28 am

leskieurbiker wrote:This post should be marked as STICKY.

It already is. :)
User avatar
proxima_centauri
Level 11
Level 11
 
Posts: 3968
Joined: Tue Dec 25, 2007 3:24 pm
Location: NB, Canada

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby Wonder on Wed Jul 18, 2012 9:24 pm

Fred wrote:...

To auto mount an ntfs Windows partition in /media open a terminal and type:

sudo mkdir /media/Windows

sudo su

echo "/dev/sdxx /media/Windows ntfs defaults,umask=007,gid=46 0 0" >> /etc/fstab


Hi!

I made this changes for automont my hard disk with windows.

My line in fstab is:
Code: Select all
/dev/sda2 /media/Dany7 ntfs defaults,umask=007,gid=46 0 0

Well, appears in my desktop when start linux mint 13, but I have this problem:

I installed Thunderbird and, at the moment, I use the same folder for thunderbird in linux and windows (the folder of thunderbird are in hard drive with windows).
When start thunderbird appears a error that are innacesible.

If I deleted this line in my fstab, restart linux and mount hard drive (access to computer and doble click to the hard drive with windws (sda2)) works fine, I can open Thunderbird and works fine.

But, if automount this drive with this line in my fstab, not works, I go to computer, doble click (for test) in my hard drive (sda2) and try to open thunderbird and appears the same errror message (...are innacessible).

Can help me please?

This is very important for me.

Thank you very much!!!

Edit: Solved: I don't view that, my name hard drive are one with space and the folder that I create in .media are without space.
Sorrys.
Image
Wonder
Level 4
Level 4
 
Posts: 323
Joined: Wed Jul 11, 2012 8:09 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby ajg007 on Wed Sep 12, 2012 3:26 am

I'm new to linux and tried to follow the instructions.
After trying to boot up again it said it could not find the drives to boot up and it cuased my system to pause til i pressed retry skip or manual,

How do i undo what ive done and start again?
ajg007
Level 1
Level 1
 
Posts: 46
Joined: Tue Sep 11, 2012 3:18 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby AlbertP on Wed Sep 12, 2012 6:11 am

You probably removed some line from /etc/fstab, or mounted some filesystem at a wrong location. You can boot a Mint disc, there open the file manager and go to your Linux partition (note it's not the "File System" button - that is the filesystem of the CD/DVD) to edit /etc/fstab again.
Registered Linux User #528502
Image
Feel free to correct me if I'm trying to write in Spanish, French or German.
AlbertP
Level 16
Level 16
 
Posts: 6513
Joined: Sun Jan 30, 2011 12:38 pm
Location: The Netherlands

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby ajg007 on Wed Sep 12, 2012 12:45 pm

AlbertP wrote:You probably removed some line from /etc/fstab, or mounted some filesystem at a wrong location. You can boot a Mint disc, there open the file manager and go to your Linux partition (note it's not the "File System" button - that is the filesystem of the CD/DVD) to edit /etc/fstab again.



Thanks. That sorted it.

Better keep the linux mint disk in the drive lol.

Here goes attempt number 2 lol
ajg007
Level 1
Level 1
 
Posts: 46
Joined: Tue Sep 11, 2012 3:18 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby ajg007 on Sat Sep 15, 2012 6:18 am

Ive managed to do it in a round about way.

I used the terminal to create the mount points using mkdir.

Then in a text document creating the uuid like this:

#Auto mount the Backups partition, (sdb2), File format: NTFS
UUID="FAA4042DA403EAC9" /home/alan/Backups ntfs defaults 0 2

then booting up parted magic i opend the fstab and added the lines above.

Might be a long way round but it works!
ajg007
Level 1
Level 1
 
Posts: 46
Joined: Tue Sep 11, 2012 3:18 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby nthcode on Fri Nov 09, 2012 11:50 am

Was a gentoo ricer and ubuntu user a couple of years ago, then switched back to winows.
Just updated my win7 laptop to win8 and the experience is great imo.

Trying to multi-boot since I'm installing an new OS anyway since mint looks promising.
Obviously I need a shared partition among the two OS as always.

Remember how I was trying to do this since 10 years ago everytime I install a distro,
I can totally do it from CLI but was hoping for a GUI solution for such a common thing to do.
My first intution lead me to look for this feature in the Disk Utility, tough luck.

The group 46 is impossible to find out unless you're really familiar with Ubuntu so a google search is necessary.

IMO it's major usability problem and we shouldn't need a tutorial about this, but instead for customized mounting options only.
The problem is pretty easy to fix, and I'm sure heaps of developers encounter this when they install.
*Scraching my head
nthcode
Level 1
Level 1
 
Posts: 3
Joined: Fri Nov 09, 2012 11:28 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby altair4 on Fri Nov 09, 2012 12:32 pm

This HowTo has become somewhat dated so there are a few things that don't work as smoothly as they did when it was originally posted and conventions and option lists have also changed. So for an NTFS partition instead of something like this:

/dev/sdxx /home/fred/Windows ntfs defaults,umask=007,gid=46 0 0

It's now become something like this:

UUID=200C11850C1156DE /home/fred/Windows ntfs defaults,umask=007,gid=46,windows_names 0 0

And that's the problem. All of these GUI's were written during that awkward stage of Linux evolution when things like Firestarter were written. Most of them were done without adult supervision, really didn't work very well, it's authors really didn't understand the meaning and use of the mounting options, and haven't been supported for years. So very few of these GUI's know what a UUID is, were written before ntfs allowed write access, and not one of them knows what the windows_names optiton does so it's best to just avoid them all.

Side Note:
nthcode wrote:The group 46 is impossible to find out unless you're really familiar with Ubuntu so a google search is necessary.

Up until a few releases ago Ubuntu / Mint automatically made new users members of the plugdev group ( group=46 ) so it wasn't an issue.

BTW, When you install Mint you are given the chance to have these non-system partitions mounted automatically at boot as part of the install process so you don't have to go in after the fact to mess about with fstab unless you install new disks or change partitions around or want specific mounting options applied.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 15
Level 15
 
Posts: 5833
Joined: Tue Feb 03, 2009 10:27 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby aelfinn on Thu Nov 15, 2012 5:10 am

altair4 wrote:When you install Mint you are given the chance to have these non-system partitions mounted automatically at boot as part of the install process

That sounds interesing—where would I find that option?
LM15 C64
Acer Aspire 1810TZ
aelfinn
Level 3
Level 3
 
Posts: 188
Joined: Thu Dec 11, 2008 2:11 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby nthcode on Thu Nov 15, 2012 2:19 pm

altair4 wrote: ...


True that, I still remember when rw access was experimental, not long ago.
Went for Ubuntu 12.10 and I'm gonna stick to it since I actually like unity, wired! (customizability like the location of the dock would be appreciated tho..) But I do understand why people would prefer Cinnamon.

In their gnome-disk-utility (3.6.1-0ubuntu1) you get to disable auto mount options and click "mount at startup".
You get to enter the mount options in a textbox. Well the default mount options they give is not sane either anyway, "nosuid,nodev,nofail,noauto", you get smth like root:root rwxrwxwx. So what you gave me still helps, thanks! I guess they should fix it at gnome3, I'll see if contributing is possible.

I'm not sure about what Cinnamon is using now coz it's been a while since I jumped ship, but IIRC it's different?
Well being able to change it in installation is no excuse! :D And it wasn't obvious anway.
nthcode
Level 1
Level 1
 
Posts: 3
Joined: Fri Nov 09, 2012 11:28 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby MagicMint on Sun Aug 04, 2013 12:26 pm

As an example of safe mounting options for the well-known DATA partition of Windows for the standard “linux” user of Linux Mint, take this for fstab:
Code: Select all
LABEL=DATA /mnt/DATA ntfs-3g defaults,uid=linux,gid=linux,dmask=022,fmask=133,windows_names 0 0

Of course, if you’ve chosen another name for yourself, you should replace the two occurrences of “linux” by your own user (and group) name :P.
Minze, mint, menthe, menta, mento…

Avatar by PhotoZel at CrystalXP.net
User avatar
MagicMint
Level 1
Level 1
 
Posts: 16
Joined: Fri May 31, 2013 1:29 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby biggocharley on Tue Dec 03, 2013 5:01 pm

I am running Mint 16 Petra and I have a data partition on sdb3 that I would like to mount automatically on boot.

Following the instructions in Fred's original post on this thread, I added this line to /etc/fstab:
/dev/sdb3 /media/Data vfat umask=0000,uid=1000,gid=1000,auto,rw,users 0 0

I get the following message during the boot process:
"press S to skip mounting or M for manual reboot"

I pressed "S" but after booting the partition Data is successfully mounted in
/media

What's happening here? more imporatanly how do I get rid of this message and what did I do to cause it?
biggocharley
Level 2
Level 2
 
Posts: 65
Joined: Fri Dec 10, 2010 5:54 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby altair4 on Wed Dec 04, 2013 8:34 am

/dev/sdb3 /media/Data vfat umask=0000,uid=1000,gid=1000,auto,rw,users 0 0

Fred hasn't posted in this forum for quite some time so let me give this a shot.

It's possible that the system is getting confused by /dev/sdb3. Since the original HowTo was written Linux has moved to using UUID numbers rather than /dev/sdxy to specify a partition so as to remove this type of confusion.

Run the following command:
Code: Select all
sudo blkid -c /dev/null

That will list all your partitions and their UUID numbers. Find the UUID number for your vfat partition and use it in fstab instead. Something like this:
UUID=C4DB-C1B0 /media/Data vfat umask=0000,uid=1000,gid=1000,auto,rw,users 0 0


If you have /dev/sdb3 currently mounted unmount it then run the following command to test for any errors in fstab and if there are none mount the partition:
Code: Select all
sudo mount -a
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 15
Level 15
 
Posts: 5833
Joined: Tue Feb 03, 2009 10:27 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby biggocharley on Wed Dec 04, 2013 11:12 am

I did as you suggested above and sudo mount -a revealed a syntax error in fstab ahich I corrected. The error message on boot is no longer there.
Thanks so much for your help and the quick response. I will try the command with sdb3 instead of the UUID again now that the syntax error is fixed and see what happens. I'll report back with the results.
biggocharley
Level 2
Level 2
 
Posts: 65
Joined: Fri Dec 10, 2010 5:54 pm

Re: Auto Mount Partitions on Boot (also Windows)[SOLVED]

Postby biggocharley on Wed Dec 04, 2013 11:23 am

Both of these lines I added to fstab achieved the desired rresults -- The partition mounted ok with no error message.
Thanks again for your help.


Code: Select all
UUID=EF4D-9143 /media/Data vfat umask=0000,uid=1000,gid=1000,auto,rw,users 0 0

/dev/sdb3 /media/Data vfat umask=0000,uid=1000,gid=1000,auto,rw,users 0 0
Last edited by biggocharley on Wed Dec 04, 2013 11:44 am, edited 1 time in total.
biggocharley
Level 2
Level 2
 
Posts: 65
Joined: Fri Dec 10, 2010 5:54 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby altair4 on Wed Dec 04, 2013 11:23 am

I personally would recommend staying with the UUID. By design the probability of duplicate UUID's - outside of cloning your partition - is near zero which is why the installer sets your root partition with UUID's.

With multiple hard drives and multiple partitions on those hard drives the boot process will eventually get confused which is why we moved to UUID's in the first place.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 15
Level 15
 
Posts: 5833
Joined: Tue Feb 03, 2009 10:27 am

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby biggocharley on Wed Dec 04, 2013 11:45 am

good advice -- I will do so
biggocharley
Level 2
Level 2
 
Posts: 65
Joined: Fri Dec 10, 2010 5:54 pm

Re: Auto Mount Partitions on Boot (also Windows partitions)

Postby ronkz on Mon Feb 10, 2014 11:45 am

The initial post held the answers which worked for me to mount my ntfs partition sdab at startup. Wading thru the post was scary for me, but I mananaged it without messing up anything, and by golly it's working! Thank you - good job!
The hurrier I go the behinder I get!
User avatar
ronkz
Level 1
Level 1
 
Posts: 32
Joined: Thu Mar 21, 2013 9:35 am
Location: Northern Arizona

Linux Mint is funded by ads and donations.
 
PreviousNext

Return to Tutorials / Howtos

Who is online

Users browsing this forum: No registered users and 7 guests