Accessing Windows Partition
Newbie here!
I dont expect any quick solutions as there aren't any, especially in the Linux world ;) but basically can someone give me a brief overview of the things that need to be done so I can see the files in my windows partition (i have windows and mandrake installed on different partitions). It would be very useful to me if i could do this, make things easier. So erm... can anyone point me in the right direction :D (hope im not asking a stupid question :confused: ) :newbie: |
Hello
First, we need to know on which device your windows is. You can find that out by typing (assuming you have one partioned ide disk): fdisk -l /dev/hda On my system it responds: Device Boot Start End Blocks Id System /dev/hda1 * 1 634 5092573 b Win95 FAT32 /dev/hda2 635 1584 7624509 f Win95 Ext'd (LBA) /dev/hda5 635 776 1140583 6 FAT16 etc... Now, /dev/hda5 is my "D" drive in Win. When I wan t o access it under Linux, I mount it by typing: mount -t vfat /dev/hda5 /mnt/win_d Of course, /mnt/win_d has to be created before that. Since in Linux everything is a directory, you can see your files in the directory /mnt/win_d or whatever you want to call it. If everything works fine you can add a line like this to /etc/fstab: /dev/hda5 /mnt/win_d vfat noauto,user 0 0 Also, type man mount for more information. Bye Koen Plessers |
sorry but where exactly do i type all of this :confused: in what program ???
|
actually, your win partitions should be in your /mnt directory. It's probably called win_c. In linux, drives appear as directories.
|
wowy ;)
thx for that, but how can i write files back to the drive, it says i dont have the rights to save a file back to the windows drive :confused: |
Hi,
I am accessing my Windows partition through Linux RedHat 9.0 in following way: 1) change to /mnt directory and make a directory cd /mnt mkdir winshare 2) open /etc/fstab using a text editor and add the below line (My windows partition is on /dev/hda5) /dev/hda5 /mnt/winshare vfat defaults 0 0 I prefer an entry in /etc/fstab as it saves me typing mount and umount commands everytime. Hope that helps |
if the win partitons is NTFS you cannot write to it. Actually, you could if really wanted to but you don't want to: you will lose data if you do. If you want a partiton where both linux and win can read and write, create a partion in fat32/vfat.
|
How does one go about changing the permissions on the ntfs drive so that someone other than root can view the drive?
I try chmod as root and get a permission denied error. |
you've got to do it in the /etc/fstab. Something like this
/dev/hda1 /mnt/win_c ntfs auto,iocharset=utf8,umask=0 0 0 the crucial option is the umask=0. Leave the rest as you have it now in your fstab. After the changes in fstab, unmount the ntfs partition and mount it again. |
I am wanting to get access to my windows xp drive as well from Red Hat 9.0 on a different harddrive. But when i try to write to /etc/fstab or if i try to make directory winshare in /mnt I get the message "permission denied." Does anyone have any ideas how i can fix this?
thanks. |
you have to be root to write to fstab or to /mnt
|
I have similar question. I changed fstab by adding the following:
/dev/hdb5 /mnt/vfat vfat auto,umask=0 0 0 I expected to be able to access hdb5 by cd /mnt/vfat. But after I reboot the system, I did cd /mint/vfat ls I got nothing! Sure, there are something on this partition. But if I issue mount -t vfat /dev/hdb5 /mnt/vfat everything is fine. What was wrong with my fstab change? Did I miss something else to auto mount? Many thanks! Ffang |
Quote:
/dev/hdi2 /mnt/win_d vfat noauto,user 0 0 into my /etc/fstab and reloaded my machine, and it doesn't auto mount....what am I doing wrong, if I type the message in again, I can access the files. |
the option "noauto" says not to mount this filesystem automatically. If you want to have the filesystem mounted during boot, you should change the option to something similar to
/dev/hda5 /mnt/win_d vfat user 0 0 or to /dev/hda5 /mnt/win_d vfat defaults 0 0 If I remeber the man pages correctly, this should enable the automatic mounting. However, using this line, only root should be able to see any files. I use this line in /etc/fstab: /dev/hda2 /C ntfs noauto,user,uid=500,gid=500 0 0 which lets all files in /C appear as though the belonged to user-id=500, group-id=500 (which happens to be myself). BTW, my line from /etc/fstab does not mount /C automatically. HTH |
All times are GMT -5. The time now is 02:20 AM. |