View Full Version : mounting non linux partitions
zuser
Oct 10th 2005, 06:57 AM
I am very frustrated here.
When i look at the hardrives menu i can see that my linux parition and my external hdd are detected but i cannot mount my ntfs partions!
Yes i have been into the command line and attempted to learn the code to mount the harddrives but...i just don't know!
Someone give me a very simple outline of how to mount my partitions, include absolutely every step.
Would be most appreciative.
whoiam55
Oct 10th 2005, 07:23 AM
add this line to your /etc/fstab file
/dev/hdxy /mnt/xyz ntfs ro,auto,umask=022 0 0
replace hdxy to your partition and /mnt/xyz to where you want to mount your ntfs partitions. post the output of
sudo fdisk -l and your /etc/fstab file if you need more help
zuser
Oct 11th 2005, 07:59 AM
how do i edit the file, do i do it in Konsole?
i am new to this and when i say every step i mean everything like as in "open this program then click here, type this..."
please, i've edited etc/fstab file bu going into the folder and opening it in Kate as root and changing the bottom lines but it does not work. nothing gets mounted...
I want to mount a partition labeled sdb1? tell me everything. I wish it would do it visually so it didn't confuse beginners, who lose hope and give up easily on new OS's, even good ones like this.
whoiam55
Oct 11th 2005, 10:44 AM
Yes, you can use konsole to edit that file. ok here we do this step by step ;)
click on Kmenu (big K icon) > click on Run command > type konsole in the command line bar and press enter. It will open a shell console. type sudo -i /etc/fstab and press enter. it might ask you for your password, enter you password here. this will run vi editor and open the /etc/fstab file for you.
Press the *INSERT* key to change vi into editing mode. go to the last like using arrorw keys. type /dev/hdxy /mnt/xyz ntfs ro,auto,umask=022 0 0, replace hdxy to your partition and /mnt/xyz to where you want to mount your ntfs partitions.
In Linux, every device/partition of your computer is treated as a file, and you must mount every partition/device in order to use them. mount is the command to mount a device/partition. A basic way of mounting a partition/device is
mount -t <filesystem>(like ext3) <device >(like /dev/hda1) <mount point >(like /home)
In Linux your primary master IDE HDD is the /dev/hda or /dev/sda (if your are using a SCSI disk). The primary HDD is /dev/hda and Primary Slave is /dev/hdb, Secondary Master is /dev/hdc and Secondary slave is /dev/hdd. Learn the way how linux represent HDD in a, b, c, d way.
The Linux partitioning scheme is also different from Windows. Unlike Windows, there is no C: or D: drive in Linux, instead of this Linux has special files you can use to access your partitions, Assume you have a IDE HDD attached with your system. which has 3 partitions. C: drive (Primary partition) D: drive (first logical drive in extended partition) E: (second logical drive in extended partition). Linux use /dev/hda1 /dev/hda2 /dev/hda3 /dev/hda4 /dev/hda5 and so on for defining partitions.
/dev/hda1 is the first primary partition, a Linux system can have maximum of 4 primary partitions. Linux uses /dev/hda4 for extended partition then /dev/hda5(6,7,8) for logical drives under it. I hope I’m not confusing you.
I would suggest you read Linux partitioning HOWTO (http://www.tldp.org/HOWTO/Partition) from The Linux Documentation Project. when Linux boot it will look /etc/fstab file for entries and mount them on boot. You can also mount your partition using mount command or you can add entries in /etc/fstab file if you want them to mount automatically everytime you start your computer.
zuser
Oct 12th 2005, 06:38 AM
I type in konsole:
root@ml193:~ # sudo -i /etc/fstab
then this appeared...
/etc/fstab: line 4: proc: command not found
/etc/fstab: line 5: /dev/sdb3: Permission denied
/etc/fstab: line 6: /dev/hda: Permission denied
/etc/fstab: line 7: /dev/fd0: Permission deniedenied
I am root, but when i hit the Insert key on keyboard i can't see how i can edit this information, and what's with the permission denied stuff? Do you mean some other INSERT button/option wtf? The manual helped a bit but i am stilll confused.
I then tried:
root@ml193:~ # mount -t ntfs /dev/sdb1 /opt
as the manual suggested, now i have my 125gig partition appearing to be mounted in media:/ but i still cannot access it, probably because of the 'opt' bit.
Now i don't know how to unmount it from opt so i'm going to restart and try again. Will keep you posted.
whoiam55
Oct 12th 2005, 06:46 AM
Do you mean some other INSERT button/option wtf? The manual helped a bit but i am stilll confused.
type sodu vi /etc/fstab not sudo -i /etc/fstab, and you must not mount a partition on /opt dir.
/opt is a system folder and /opt is reserved for the installation of add-on application software packages. you must not mount any thing on /opt, create a new folder instead as I suggested in my reply.
I tried to make information as clear and easy as I can and I think any newbie can follow them, If you can't understand them, sorry I can't help you much.
you can unmount a partition/device using umount command.
umount /device_name or /mounted_directory you can type umount /opt in your case.
zuser
Oct 12th 2005, 06:52 AM
will a non-root user have access?
zuser
Oct 12th 2005, 07:05 AM
Thanks, i have now worked out how to edit fstab, but how do i save the edited information?
if i quit it doesn't save, so do i need to hit a button or what?
whoiam55
Oct 12th 2005, 08:34 AM
will a non-root user have access?
No one allowed to edit system files except root.
Thanks, i have now worked out how to edit fstab, but how do i save the edited information?
If you are editing it with vi then press esc once you finish then type : then type wq (w for write and q for quit), you can also edit it with kate, Open Kmenu click on run type kdesu kate /etc/fstab press enter then enter your password when prompted.
I would suggest you reading man pages of vi editor. man vi, they have enough information to get you start. Keep in mind that you must read new thing in order to learn new things. I'm telling you this cause I don't want to spoon fed you. If you do them on your own, you will learn things in a better way. I don't want to hinder your growth by spoon feeding you.
thumper
Oct 12th 2005, 09:31 AM
zuser, I am going to assume that your ntfs partition that you are wanting to mount is hda1, party because that is what mine was originally, and that Windows likes to be the main thing on a PC. Also that your mount point is /opt based on your posts.
So the line to add to /etc/fstab would be:
/dev/hda1 /opt ntfs ro,auto,umask=022 0 0
Before trying to mount it, you need to make sure that the /opt directory exists. I'd suggest:
sudo mkdir /opt
Then you can mount it the first time (ie. without rebooting) using:
sudo mount /opt
You don't need the extra parameters to mount as it looks in /etc/fstab for those details (if the directory is one defined in there, which yours will be).
whoiam55
Oct 12th 2005, 09:45 AM
Before trying to mount it, you need to make sure that the /opt directory exists. I'd suggest:
sudo mkdir /opt
You must not create /opt dir. /opt is a system folder and is reserved for the installation of add-on application software packages. create another folder like /windows or /windows_files
thumper
Oct 12th 2005, 10:35 AM
I agree that you should use something like /windows.
I didn't realise that /opt was a system folder, I just thought it may have been.
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.