LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 01-29-2004, 12:40 PM   #1
jhirshon
LQ Newbie
 
Registered: Jan 2004
Posts: 14

Rep: Reputation: 0
mount filesystems from hda1 and hda2


I have a fresh installation of Fedora Core 1.0 on its own hard drive. The system is set up for dual boot. How do I mount filesystem hda1 (FAT) and filesystem hda2 (NTFS)

Thanks,
Jordon
 
Old 01-29-2004, 12:56 PM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387
Both (FAT, NTFS) must have kernel support. I'm sure that FAT will be enabled, not sure about NTFS. If it is you will probably only have read access (still a bit dangerous to write to an NTFS fs).

Take a look at the mount manpage (man 2 mount) for all the options for mounting.

Here's the short version:

Create a directoy where your partion is going to be mounted. On most systems there is already a directory (/mnt) where you can create these dirs.

$ mkdir /mnt/hda1
$ mount -t vfat /dev/hda1 /mnt/hda1

You should be able to access your FAT disk.

To unmount:

$ umount /dev/hda1

If you want to make this permanent, add it to your /etc/fstab.
Something like this (read the manpage first, don't copy/paste this!!):

/dev/hda1 /mnt/hda1 vfat defaults 1 2

Last edited by druuna; 01-29-2004 at 12:57 PM.
 
Old 01-29-2004, 01:00 PM   #3
MartinN
Member
 
Registered: Nov 2003
Location: Ronneby, Sweden
Posts: 555

Rep: Reputation: 30
Hi Jordon! Welcome to LinuxQuestions.

There are two answers to your question. The first answer is if you want to mount them once, the second is if you want them to always be mounted automatically.

First, you need an empty directory as a mount point (actually, it doesn't need to be empty, but once you mount something the stuff that was there before will be hidden).

Now, for mounting a disk once, root gives this command:
mount -t vfat /dev/hda1 some_directory
The NTFS partition must be mounted read-only, blame Microsoft who don't give any information as to how NTFS works
mount -r -t ntfs /dev/hda2 some_other_directory

To automatically mount a partition, you (root) must edit the file /etc/fstab
Add two lines that look like this:
Code:
/dev/hda1	      	/some/directory	        vfat    defaults        0 0
/dev/hda2	      	/some/other/directory   ntfs    ro              0 0
I think that the two above lines are correct, but I haven't tested it. Anybody has a second opinion?

Regards
Martin
 
Old 01-29-2004, 01:05 PM   #4
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 59
but we do now have something that enables read/write to ntfs ... never tried it (cause not only do i not use windows, it wouldn't be formatted as ntfs if i did)
you can read up here
 
  


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
Linux root moved from hda2 to hda1 dangerousdave Linux - Software 3 11-02-2005 07:18 PM
mount a subfolder of /hda2 hypoglycemic Linux - Software 2 11-16-2004 06:27 AM
Can mount hda1, but not hda2,3,4,5, or 6? Dobie Linux - Newbie 4 06-13-2004 05:37 PM
hda1, hda2 and hda3.. partitioning order concoran Linux - Software 4 10-16-2003 12:26 AM
Can't mount hda2 thundersnows Slackware 7 09-09-2003 11:50 PM


All times are GMT -5. The time now is 10:38 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