Click to See Complete Forum and Search --> : Viewing NTFS partition under Linux


Dave_M
09-16-2001, 08:13 AM
Hello, sorry for sounding thick, but I have a small problem here.
I recently installed Mandrake 8.1b3 on my Win2k box, and I was wondering how I could view my NTFS partition when running Linux?

Can anyone help me, please?

7
09-16-2001, 09:03 AM
You need to add NTFS support to your kernel. You could compile a new kernel with it built in, or you could insert a module. Its a big topic, so I can't really explain it all here. This (http://www.linuxnewbie.org/nhf/intel/compiling/index.html) should help. Post back if you get stuck.

Btw, you can't write to the NTFS partition, Linux only has read support.

7
09-16-2001, 09:05 AM
Oh yeah, then you need to mount it, do you understand mounting filesystems? With 'mount'?

Craig McPherson
09-16-2001, 09:48 AM
Well, the first hurdle is that you need to have the NTFS driver in your kernel. It may already be built in. Many distros include it by default now that Windows 2000 has gotten so popular. Try to mount the partition, and if it says "unknown filesystem type" or somesuch, the NTFS driver is NOT in the kernel.

There's also a chance that the driver is built as a module, in which case "modprobe ntfs" will insert the driver into the kernel.

If neither of these is true, you'll have to recompile.

This is how you mount the filesystem:

mkdir /mnt/win (this creates a mount point, you only need to do it once)
mount -t ntfs /dev/hdxx /mnt/win

Replace "hdxx" with the correct device name for your NTFS partition.

Good luck.

Dave_M
09-16-2001, 10:05 AM
Thanks for all the help guys, it's MUCH appreciated

Dave_M
09-16-2001, 10:05 AM
Thanks for all the help guys, it's MUCH appreciated

Dave_M
09-16-2001, 10:57 AM
Excellent, got it working...
How can I set it up to mount every time I boot?
Also, for some odd reason, I can't change the permissions on the NTFS drive, I can only enter the folders as 'root' :(

Craig McPherson
09-16-2001, 11:16 AM
Originally posted by Dave_M:
<STRONG>How can I set it up to mount every time I boot?</STRONG>

Add an entry to /etc/fstab. Post back here if you can't figure out how by looking at the existing entries.

Also, for some odd reason, I can't change the permissions on the NTFS drive

It's not odd. The NTFS filesystem doesn't support UNIX-style permissions any more than the Ext2 filesystem supports NT-style permissions. You can't change something that doesn't exist for the filesystem.

I can only enter the folders as 'root'

You can change the effective permissions for the filesystem when you mount it.

For example:

mount -t ntfs -o mask=222 /dev/hdc1 /mnt/point

The option might be "umask" instead of "mask". I forget. Anyway, that'll give all files on the filesystem an effective mode of 555. (mode=555 might work also. The mount manpage will tell you, but I'm too lazy to check it right now)

Remember that the NTFS driver is read-only, so you won't be able to write to the filesystem no matter what you do. There's a read-write NTFS driver, but it's very experimental so I wouldn't recommend you use it.

If you need an easy way to move stuff back and forth between OS's, create a small FAT32 partition. Both OS's can read/write FAT32 with ease.