Mounting other hard disks
-
- Cadet
- Posts: 4
- Joined: Tue Mar 04, 2008 7:59 pm
Mounting other hard disks
If I have two hardisks and in one hdd I have linux and i want to mount the other hardisk with partitions both ntfs and fat32. how can i do such
-
- Battalion Havaldaar Major
- Posts: 273
- Joined: Sat Jan 27, 2007 11:07 pm
- Location: Dera Ismail Khan, Pakistan
- Contact:
Assalam-o-Alaikum Farhan Ansari,
You can do it by mount command. For example:
If you want the partitions to be automatically mounted on each boot, you will have to edit the file /etc/fstab. But before that you will have to keep some things in mind. For example:
If C drive is on first hard disk, it will probably be /dev/hda1. D drive will be /dev/hda5, E will be /dev/hda6, F will be /dev/hda7 and so on.
NTFS support in some old Linux distributions will be limited to read-only. If possible, you should use FAT file system.
Here is an example of what to add to /etc/fstab:
The first column represents the hard disk device as I have already mentioned. The second column is the mount point, i.e; the directory where you will mount the partition. Third column is for file-system. You can set it to auto to detect the file-system automatically. Fourth column is for other advanced options. To know details about these options, type man mount at the terminal. About the other two columns, I only know that they should be 0 0 for windows disk.
For more details about the process, type man mount or man fstab at the terminal to read a detailed manual.
You can do it by mount command. For example:
Code: Select all
mount /dev/hda1 /mnt/c
If C drive is on first hard disk, it will probably be /dev/hda1. D drive will be /dev/hda5, E will be /dev/hda6, F will be /dev/hda7 and so on.
NTFS support in some old Linux distributions will be limited to read-only. If possible, you should use FAT file system.
Here is an example of what to add to /etc/fstab:
Code: Select all
/dev/hda1 /mnt/c-drive auto iocharset=utf8,umask=000 0 0
/dev/hda5 /mnt/d-drive auto iocharset=utf8,umask=000 0 0
For more details about the process, type man mount or man fstab at the terminal to read a detailed manual.
Mounting Windows Partition in linux
If you have 2.6.20 or above kernel then you going to do it now time by
For NTFS
mount -t ntfs /path/to/your/device /mount/point
e.g.
and for Fat32
If you have below kernel than 2.6.20 then install ntfs-3g and use it for mounting ntfs partition. And now if you want to mount partition permanently then add the entry for your partition in your /etc/fstab file.
For NTFS
mount -t ntfs /path/to/your/device /mount/point
e.g.
Code: Select all
mount -t ntfs /dev/hda1 /mnt/ntfs
Code: Select all
mount -t vfat /dev/hda1 /mnt/vfat
-
- Battalion Quarter Master Havaldaar
- Posts: 214
- Joined: Sun Apr 18, 2004 5:58 pm
- Location: CEME, Pindi
Where are you getting that information from? Kernels <2.6.20 definitely had ntfs write support although it was labelled 'EXPERIMENTAL' or such.x2oxen wrote:below 2.6.20 kernels won't let you write on it or else you have to add ntfs-3g support in those 2.6.20 and above have that builtin
And this is what the latest stable kernel (2.6.25) says in "Documentation/filesystems/ntfs.txt":
So, there is still only limited ntfs write support in the kernel but it is safe to use it now.The biggest limitation at present is that files/directories cannot be created or deleted.
"Where blasphemy is a crime, religious freedom does not exist." - Stallman to Musharraf