View Full Version : mounting multiple NTFS drives
mkyb14
2004-12-31, 03:48 PM CST
I have 6 NTFS drives that i would like to mount and have icons on the desktop for... i checked out http://linux-ntfs.sourceforge.net/rpm/instructions.html for instructions and it can only mount ONE drive at a time ... is there away to mount all of my drives so that they start with linux at boot .... then i can access all my music files and what not without this i cannot unless i do each individually .... debain or knoppix does this automatically and wanted to know if it's a function that's part of FC3 ?????????? PLEASE HELP
zulaica
2004-12-31, 04:00 PM CST
where does it say that?
i haven't had any problem mounting more than one ntfs parition. *shrug*
mkyb14
2004-12-31, 05:58 PM CST
not partition ... multiple hd's .... not on just one hd ... multiple
zulaica
2004-12-31, 06:13 PM CST
hmm. i've got two hard drives, both with ntfs partitions on them. i'll double check later to see if i have any issues accessing either disk.
yakleo3
2004-12-31, 06:21 PM CST
Simply edit your /etc/fstab to include all of your drives, then all of them will be mounted at boot time.
Artemis
2005-01-01, 04:18 AM CST
Tip: you can show us the output of this command:
su -
- enter root password -
fdisk -l
And the content of the /etc/fstab file!!!
Then you can tell us what partitions you need to mount and we will figure out the lines for the /etc/fstab!!!
mkyb14
2005-01-01, 02:31 PM CST
ok ok maybe i have to be more specific .... i folllowed the directions from the http://linux-ntfs.sourceforge.net/rpm/instructions.html
Followed it all the way up to
mkdir /mnt/windows
mount /dev/hda1 /mnt/windows -t ntfs -r -o umask=0222
changing it to 777 so that i can edit my files ...
so i have a folder called windows that shows one hd of my choice ... do i have to do that all again for another folder but named differently ????? so instead of nameing the folder windows i should name it hard drive 1,2,3 etc ..... and to edit the bin/fstab .... what other info must be insterted to the right of it if you are to look at yours ..... there's some abbreviations and numbers that i'm lost on ..... anyone have a more detailed account of what has to be done to accomplish this for people in the future as well as me.
Jesus-Franco
2005-01-01, 06:03 PM CST
Yes I belive you should use harddrive 1,2,3 etc
After you mount each drive add it to your auto mount, by modifing your etc/fstab file. This way you dont need to manually mount them after login :)
mkyb14
2005-01-02, 12:44 AM CST
what you just said is no clearer than what was said earlier
benv84
2005-01-02, 07:37 PM CST
ok ok maybe i have to be more specific .... i folllowed the directions from the http://linux-ntfs.sourceforge.net/rpm/instructions.html
Followed it all the way up to
mkdir /mnt/windows
mount /dev/hda1 /mnt/windows -t ntfs -r -o umask=0222
changing it to 777 so that i can edit my files ...
so i have a folder called windows that shows one hd of my choice ... do i have to do that all again for another folder but named differently ????? so instead of nameing the folder windows i should name it hard drive 1,2,3 etc ..... and to edit the bin/fstab .... what other info must be insterted to the right of it if you are to look at yours ..... there's some abbreviations and numbers that i'm lost on ..... anyone have a more detailed account of what has to be done to accomplish this for people in the future as well as me.
what that code is going to do is mount partition "hda1" in the folder "windows", so for your next partition, probably hda2 you would want to mount it in a different folder. so yes, you could have "/mnt/harddrive1" and "/mnt/harddrive2", these folder names do not really matter.
the problem with this method is that every time you reboot, you're going to have to mount all of you partitions again using these commands. an easier way to mount your partitions is with the "fstab" file found in the /etc folder. if you can go find that and post its contents, we can show you how to mount all of your partitions automatically by editting that file.
also, how drives do you have and which partitions are where? this will need to be known to edit the fstab file.
mkyb14
2005-01-03, 01:43 AM CST
GNU nano 1.2.4 File: fstab
# This file is edited by fstab-sync - see 'man fstab-sync' for details
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
/dev/VolGroup00/LogVol01 swap swap defaults 0 0
/dev/hdh /media/cdrom auto pamconsole,fscontext=sy$/dev/hdg /media/cdrecorder auto pamconsole,fscontext=sy$/dev/sda1 /media/LEXAR_MEDIA vfat pamconsole,noatime,sync$
that's the exact code .....
Also i need to be able to modify the files on those drives incase i wanna add some things to my mp3s folder and what not ..... ehh knoppix did it easily on boot by it self, but fedora has a better user GUI
imdeemvp
2005-01-03, 01:48 AM CST
Open terminal and become root and type:/sbin/fdisk -lthis will give you all your hd's partition tables and take it from there. You will only be able to read.
mkyb14
2005-01-03, 02:58 PM CST
Disk /dev/hda: 40.9 GB, 40982151168 bytes
255 heads, 63 sectors/track, 4982 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 4981 40009851 7 HPFS/NTFS
Disk /dev/hdb: 200.0 GB, 200049647616 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdb1 * 1 24321 195358401 7 HPFS/NTFS
Disk /dev/hdd: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdd1 * 1 19929 160079661 7 HPFS/NTFS
Disk /dev/hde: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hde1 * 1 4864 39070048+ 7 HPFS/NTFS
Disk /dev/hdf: 10.8 GB, 10800857088 bytes
255 heads, 63 sectors/track, 1313 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdf1 * 1 13 104391 83 Linux
/dev/hdf2 14 1313 10442250 8e Linux LVM
Disk /dev/sda: 257 MB, 257474560 bytes
65 heads, 32 sectors/track, 241 cylinders
Units = cylinders of 2080 * 512 = 1064960 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 242 251423+ b W95 FAT32
Partition 1 has different physical/logical endings:
phys=(249, 64, 32) logical=(241, 49, 31)
that's what i get when i do /sbin/fdisk -1 .... so how do the hd's info from here translate to what needs to be done in fstab .....??????????
Jesus-Franco
2005-01-03, 03:54 PM CST
Disk /dev/hda: 40.9 GB, 40982151168 bytes
255 heads, 63 sectors/track, 4982 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 4981 40009851 7 HPFS/NTFS
Disk /dev/hdb: 200.0 GB, 200049647616 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdb1 * 1 24321 195358401 7 HPFS/NTFS
Disk /dev/hdd: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdd1 * 1 19929 160079661 7 HPFS/NTFS
Disk /dev/hde: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hde1 * 1 4864 39070048+ 7 HPFS/NTFS
Disk /dev/hdf: 10.8 GB, 10800857088 bytes
255 heads, 63 sectors/track, 1313 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdf1 * 1 13 104391 83 Linux
/dev/hdf2 14 1313 10442250 8e Linux LVM
Disk /dev/sda: 257 MB, 257474560 bytes
65 heads, 32 sectors/track, 241 cylinders
Units = cylinders of 2080 * 512 = 1064960 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 242 251423+ b W95 FAT32
Partition 1 has different physical/logical endings:
phys=(249, 64, 32) logical=(241, 49, 31)
that's what i get when i do /sbin/fdisk -1 .... so how do the hd's info from here translate to what needs to be done in fstab .....??????????
The the only info you need is The part were it says Device Boot and System. System is basicly the File System Type. Take a look here at my fstab
# This file is edited by fstab-sync - see 'man fstab-sync' for details
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
/dev/VolGroup00/LogVol01 swap swap defaults 0 0
/dev/hdb1 /mnt/windows ntfs ro 0 0
/dev/hdc /media/cdrecorder auto pamconsole,fscontext=system_u:object_r:removable_t ,exec,noauto,managed 0 0
/dev/fd0 /media/floppy auto pamconsole,fscontext=system_u:object_r:removable_t ,exec,noauto,managed 0 0
I added the automount ti dev/hdb1 ;)
BTW, note the RO after ntfs, RO makes the disk read only. I have seen people add ways to make linux write to ntfs drives but that causes lots of issues (some fatal)
mkyb14
2005-01-03, 05:15 PM CST
uh fatal is not a word i'l like to hear when i have over 30,000 mp3s and 500+ dvd's backed up ..... hmmmm ok that's more clear than anyone else has stated ... i wasn't sure what all the "ro", "0,0" meant but i'll just copy it and see what happens
so i'll have to create a folder for each first then follow the directions on the rpm website and then edit the fstab?
okok so this is what i did
# This file is edited by fstab-sync - see 'man fstab-sync' for details
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
/dev/VolGroup00/LogVol01 swap swap defaults 0 0
/dev/hda1 /mnt/windows ntfs ro 0 0
/dev/hdb1 /mnt/windows2 ntfs ro 0 0
/dev/hdd1 /mnt/windows3 ntfs ro 0 0
/dev/hde1 /mnt/windows4 ntfs ro 0 0
/dev/hdh /media/cdrom auto pamconsole,fscontext=sy$/dev/hdg /media/cdrecorder auto pamconsole,fscontext=sy$
rebooted and now the folders say that they are unreadable ... with two red icons .... so i loged in as root and can browse the files from the terminal .... but my usr name can't ... i am on the sudoers list ....... what's up now .. heh i can see them as root and not as user .....???????
grandwazir
2005-01-04, 02:18 AM CST
The reason why you can only access these as root is because you didn't tell linux which users are allowed to use it.
So by default linux only lets root use them.
To make it so you can use the mounted partitions in a normal user account you need to make sure you place your username in the fstab commands as well.
So a sample ntfs mount giving read only permission to me on my system would be
/dev/hda1 /mnt/windows ntfs ro,uid=grandwazir 0 0
I have told fstab to mount /dev/hda1 to /mnt/windows and also give read only permissions to userid (ui) grandwazir.
You also assign group permissions in the same way by using 'gid'
PhilD
2005-01-04, 03:04 AM CST
try the following in fstab
dev/hda1 /mnt/windows ntfs ro,umask=0222,uid=user 0 0
Changing user to the username you want to have access to it... also check the permissions of the folder you are mounting to. they need to allow the user to read.
smudge
2005-01-22, 02:45 PM CST
A very informative thread. Following the tutorials here and at http://linux-ntfs.sourceforge.net/rpm/ I can successfully access my windows install drive ( C: ) on hda1 NTFS.
I have three hard drives.
The first is a 40Gb ATA drive with a 10 Gb windows partition and 30 Gb FC3 partition(s).
The other two drives are SATA drives (not raid) NTFS 120Gb Drives. To be precise:
Disk /dev/hda: 40.0 GB, 40027029504 bytes
255 heads, 63 sectors/track, 4866 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 1275 10241406 7 HPFS/NTFS
/dev/hda2 1276 1288 104422+ 83 Linux
/dev/hda3 1289 4866 28740285 8e Linux LVM
Disk /dev/sda: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 14946 120053713+ 7 HPFS/NTFS
Disk /dev/sdb: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 * 1 14946 120053713+ 7 HPFS/NTFS
First I did:
mkdir /mnt/windows
mount /dev/hda1 /mnt/windows -t ntfs -r -o umask=0222
I have yet to get to the fstab automounting.... but the above works well.
My problems begins trying to mount the sda drives.
I did:
mkdir /mnt/windows2 (example)
mount /dev/sda1 /mnt/windows2 -t ntfs -r -o umask=0222
This time I get the error:
mount: wrong fs type, bad option, bad superblock on /dev/sda1,
or too many mounted file systems
[root@localhost bender]# /sbin/fdisk -l
Can anybody help? I don't know what I'm doing or not doing or what services are or aren't running to enable this. I keep having problems with sata mounts.
puremourning
2005-01-23, 03:00 PM CST
check dmesg to see if the kernel understads your sata controler.
smudge
2005-01-23, 03:35 PM CST
Thanks.. I just fixed it myself after pouring through the mount man and the help files at http://linux-ntfs.sourceforge.net
Nothing more than a simple command typo. I shall detail what I did for the benefit of anyone else who is struggling.
I did:
/sbin/fdisk -l and got
Disk /dev/hda: 40.0 GB, 40027029504 bytes
255 heads, 63 sectors/track, 4866 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 1275 10241406 7 HPFS/NTFS
/dev/hda2 1276 1288 104422+ 83 Linux
/dev/hda3 1289 4866 28740285 8e Linux LVM
Disk /dev/sda: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 14946 120053713+ 7 HPFS/NTFS
Disk /dev/sdb: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 * 1 14946 120053713+ 7 HPFS/NTFS
I was trying to mount a wongly named drive. My working commands were:
mount /dev/hda1 /mnt/windows -t ntfs -r -o umask=0222
mount /dev/sda1 /mnt/SATA_01 -t ntfs -r -o umask=0222
mount /dev/sdb1 /mnt/SATA_02 -t ntfs -r -o umask=0222
Windows, SATA_01 and SATA_02 are directories I made in /mnt/
This automounts the filesystems without misery.
smudge
2005-01-24, 12:26 AM CST
Ok I lied.. not working completely.. why do they not auto-mount on reboot? Any ideas.. I'm sure the command is right or is this another typo?
mount /dev/hda1 /mnt/windows -t ntfs -r -o umask=0222
mount /dev/sda1 /mnt/SATA_01 -t ntfs -r -o umask=0222
mount /dev/sdb1 /mnt/SATA_02 -t ntfs -r -o umask=0222
smudge
2005-01-24, 10:17 AM CST
I added:
/dev/hda1 /mnt/windows ntfs ro,umask=0222 0 0
/dev/sda1 /mnt/SATA_01 ntfs ro,umask=0222 0 0
/dev/sdb1 /mnt/SATA_02 ntfs ro,umask=0222 0 0
to my fstab. I rebooted and my hda1 main windows partition mounted fine (C: drive). However the sata drives (sda1 and sdb1) still didn't mount. I don't understand? This is as listed in http://linux-ntfs.sourceforge.net/info/ntfs.html#4.10 but doesn't work. If I type:
mount /dev/sda1 /mnt/SATA_01 -t ntfs -r -o umask=0222
mount /dev/sdb1 /mnt/SATA_02 -t ntfs -r -o umask=0222
into a shell.. they mount?!?! What isn't working here? :confused:
http://www.kabuse.com/fstab.png
vBulletin® v3.8.1, Copyright ©2000-2009, Jelsoft Enterprises Ltd.