LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-04-2009, 04:16 PM   #1
SMB3
LQ Newbie
 
Registered: Jun 2009
Posts: 2

Rep: Reputation: 0
Automount NTFS Partition at Startup


Hey,

I just install Mandriva Spring Edition 2009 for my brother. He used to run XP, with two partitions. One of them was the C drive with all the windows contents, and the other drive was just used for media.
So I formatted the C drive and installed mandriva on it, and left the media partition alone, as it has over 100gb of stuff.

Anyway, first I had a problem with the drive opening up in mandriva, but the help from rev918 at http://www.linuxquestions.org/questi...rtiton-612726/ I was able to fix it.

But now you have to open up Home and click the drive everytime you turn on the computer, so it mounts or something.

So I'm trying to find out how to make it just mount on startup.

I've been searching, and reading posts. From what I understand I have to edit the fstab file.
So my fstab file is below:

# Entry for /dev/sda1 :
UUID=0e40db07-1d63-46d2-b556-88429a0460d8 / ext3 relatime 1 1
none /proc proc defaults 0 0



So I'm not sure what I'm supposed to add to this file. If someone can please help me out, and tell me what I need to add to make that partition automount at startup, that would be great.

Thanks.
 
Old 06-04-2009, 05:10 PM   #2
nuwen52
Member
 
Registered: Feb 2009
Distribution: Debian, CentOS 5, Gentoo, FreeBSD, Fedora, Mint, Slackware64
Posts: 208

Rep: Reputation: 46
Assuming that the ntfs partition is /dev/sda2, I think something like:

/dev/sda2 /windows ntfs defaults 0 0

Might work. The obvious other part is to do a "mkdir /windows" first. I'd have a definite answer if I had my laptop with me. I do the same thing on that. But, I don't have my laptop's windows partition mount at startup. This should. Also, /windows should be replaced with whatever mount point you want to use.

Last edited by nuwen52; 06-04-2009 at 05:12 PM.
 
Old 06-04-2009, 06:55 PM   #3
mostlyharmless
Senior Member
 
Registered: Jan 2008
Distribution: Arch/Slackware/Knoppix
Posts: 1,784
Blog Entries: 14

Rep: Reputation: 279Reputation: 279Reputation: 279
I would recommend setting the mount "ro" or using ntfs-3g.
 
Old 06-04-2009, 07:38 PM   #4
SMB3
LQ Newbie
 
Registered: Jun 2009
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks for the replies.

I would assume the partition is at /dev/sda2, but how can I check?

And I should make a folder in the partition called windows?


Quote:
Originally Posted by mostlyharmless View Post
I would recommend setting the mount "ro" or using ntfs-3g.
I am quite a newb at this, I have no idea what that means.
 
Old 06-04-2009, 07:42 PM   #5
samnjugu
Member
 
Registered: Apr 2006
Location: Atlanta
Distribution: Centos, knoppix, Fedora, Mepis, Zenwalk, Mint
Posts: 142

Rep: Reputation: 16
I used to have the same setup on one of my machines the following should work.
#mkdir /mnt/windows

Edit fstab and add the following
/dev/sda2 /mnt/windows ntfs-3g defaults 0 0

Remember if it's another partition it will be something like sda2 or if it's another drive completely it might be sdb1.
 
Old 06-04-2009, 07:46 PM   #6
samnjugu
Member
 
Registered: Apr 2006
Location: Atlanta
Distribution: Centos, knoppix, Fedora, Mepis, Zenwalk, Mint
Posts: 142

Rep: Reputation: 16
to check just do
#mkdir /mnt/windows
#mount -t ntfs-3g /dev/sda2 /mnt/windows
 
Old 06-04-2009, 11:08 PM   #7
mostlyharmless
Senior Member
 
Registered: Jan 2008
Distribution: Arch/Slackware/Knoppix
Posts: 1,784
Blog Entries: 14

Rep: Reputation: 279Reputation: 279Reputation: 279
Quote:
I am quite a newb at this, I have no idea what that means.
Oh, sorry. Well the ntfs access included normally in the kernel, that is in the OS, is not really safe to use to write to an ntfs filesystem. You should therefore mount these as "ro" or read-only, like this
/dev/sda2 /windows ntfs ro 0 0
If you want to write to the filesystem it is recommended that you use ntfs-3g. You can search for it on the web; they have a site www.ntfs-3g.org. You'll have to install it, probably, I don't know if Mandriva includes it or not. There are instructions for that, if needed on the web site. Basically you use it like
/dev/sda2 /windows ntfs-3g defaults 0 0
as pointed out above, but there are other options you might want to consider.
 
Old 06-04-2009, 11:48 PM   #8
rikxik
Member
 
Registered: Dec 2007
Posts: 88

Rep: Reputation: 19
1. Login as usual (without adding anything to /etc/fstab).
2. Open up Home and click on the drive to mount it (what you have been doing already).
3. Now open a terminal and run command "mount". This will show you all the mounted partitions. Look for the one with "ntfs". Note down the /dev/*** part. This is how you find out if its /dev/sda2 or whatever.
4. Now you can edit fstab as advised by others. If you are not comfortable using command line editors, you can run "gksu gedit /etc/fstab". Make sure you take a safe copy of /etc/fstab before you edit it.
 
Old 06-05-2009, 12:43 AM   #9
divyashree
Senior Member
 
Registered: Apr 2007
Location: bbsr,orissa,India
Distribution: RHEL5 ,RHEL4,CENT OS5,FEDORA,UBUNTU
Posts: 1,363

Rep: Reputation: 135Reputation: 135
Quote:
Originally Posted by SMB3 View Post
Hey,

I just install Mandriva Spring Edition 2009 for my brother. He used to run XP, with two partitions. One of them was the C drive with all the windows contents, and the other drive was just used for media.
So I formatted the C drive and installed mandriva on it, and left the media partition alone, as it has over 100gb of stuff.

Anyway, first I had a problem with the drive opening up in mandriva, but the help from rev918 at http://www.linuxquestions.org/questi...rtiton-612726/ I was able to fix it.

But now you have to open up Home and click the drive everytime you turn on the computer, so it mounts or something.

So I'm trying to find out how to make it just mount on startup.

I've been searching, and reading posts. From what I understand I have to edit the fstab file.
So my fstab file is below:

# Entry for /dev/sda1 :
UUID=0e40db07-1d63-46d2-b556-88429a0460d8 / ext3 relatime 1 1
none /proc proc defaults 0 0



So I'm not sure what I'm supposed to add to this file. If someone can please help me out, and tell me what I need to add to make that partition automount at startup, that would be great.

Thanks.
U just enter this in ur /etc/fstab :
Quote:
/dev/sda2 /mnt/windows ntfs-3g quiet,defaults,locale=en_US.utf8,umask=0 1 2
If u have ntfs-3g for mounting ntfs partition and a mount point as /mnt/windows ,where to be mounted

Last edited by divyashree; 06-05-2009 at 12:45 AM.
 
  


Reply


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to automount NTFS as NTFS-3G ? (with udev ?) michauko Linux - Software 6 04-09-2011 04:54 PM
*solved* Lenny automount NTFS partition, and USB and other removable media bezdomny LinuxQuestions.org Member Success Stories 4 05-16-2009 09:08 AM
automount ntfs or fat32 USB device KMinOZ Linux - Software 3 02-13-2008 02:46 PM
Ntfs-3g automount vatten Linux - Software 2 07-12-2007 05:36 PM
automount NTFS in Redhat 8.0 manub Linux - Newbie 31 03-31-2005 02:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:36 AM.

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