PDA

View Full Version : Mounting NTFS under Linux?



Dr Unne
11-26-2001, 04:15 PM
From what I've read, it's possible to mount an NTFS drive under Linux, at least as read-only, which is all I need. But apparenltly it involves recompiling the kernel, which I was stupid enough to try to do, resulting in destruction. I couldn't find any good instructions on how to do it. Does anyone know of somewhere with good instructions on how to mount an NTFS under Linux? Or good easy-to-follow instructions on how to recompile the kernel without wreaking havoc, if that's even possible? I have RedHat 7.2, by the way. The NTFS is on one HD, Linux is on another. I don't care if I completely lose my current RedHat installation either. I just reinstalled it after the meltdown anyways.

crono_logical
11-27-2001, 02:08 AM
I thought RedHat 7.1 had the ability to read NTFS anyway? I think the distro I've got can do that, although I can't remeber off hand since I haven't rebooted out of Windows for about a month now. :p I think if you run XConfigurator under XWindows, there's a tab somewhere which lets you choose which partitions are mounted on boot, where they're mounted in the tree structure and what file system they are (much easier than editing fstab yourself :) ) Changes apply automatically too.

Dr Unne
11-27-2001, 03:24 AM
I don't think RedHat comes ready to mount NTFS systems. Even if I try manually "mount -t ntfs /dev/hda1 XP" or just "mount /dev/hda1 XP" it just says "mount: fs type ntfs not supported by kernel". I never saw any options when I was installing to include the NTFS type or anything. I'm pretty sure I need to recompile the kernel. I tried Xconfigurator. It wasn't any help.

Ah well. I'll look on the internet a bit more.

Citizen Bleys
11-27-2001, 03:54 AM
I don't know how to do it myself, but I'm sure there was a thread about it on the main forum at <a href=http://www.linuxquestions.org/questions/>linuxquestions.org</a>.

Dr Unne
11-27-2001, 04:15 AM
Yeah, I found that thread. Didn't help. It was just a guy posting problems he was having doing it himself, and no one ever answered him. I found some good instructions on another site and tried recompiling the kernel again a couple minutes ago, but it didn't work. Something like <b>make xconfig</b> , then <b>make dep</b>, then <b>make clean</b>, then <b>make zImage</b> or something. That's as far as I get. It failed trying to make the boot image. At least this time I didn't overwrite my old boot image with garbage like I did last time.

I guess this is just beyond my newbie Linux skills. Maybe I'll try again some day when I know what I'm doing. Thanks for the help anyways.

Citizen Bleys
11-27-2001, 05:16 AM
If you find an answer, let me know. I'd like to mount my XP partition, as well.

Dr Unne
11-27-2001, 05:23 AM
That's what I want to do. Stupid XP. *kicks Windows*

Endless
11-27-2001, 04:07 PM
I remember reading somewhere that XP's ntfs was slightly different from Linux', resulting in a very-hard-not-to-say-impossible compatibility.

I'd rather be wrong.

Dr Unne
11-27-2001, 07:01 PM
I wouldn't be surprised if that was true. *sigh*

Relena Peacecraft
11-28-2001, 06:58 AM
For now, I'm useless. But after Christmas I'll be installing Linux and XP, and I'll want to mount my drive. I know there is a project somewhere on sourceforge that is working to put NTFS support into Linux, but I'm not sure if that one operates as a daemon or if it requires a recompile. I did recomplie my kernel once, for some reason, and I think it succeeded. Not that I remember what I did. *shrugs*

If you haven't figured it out in a while, I'll be more useful once I get my hands dirty.

crono_logical
11-28-2001, 10:19 AM
I suppose the easiest solution is to not convert your partition to NTFS when you install XP, or at least convert it back to Fat32 using Partition Magic or similar - I personally don't see a need for NTFS if you're going to be the only one using your computer, and no-one else :)

Citizen Bleys
11-28-2001, 02:10 PM
That's no good for me. XP's on my laptop, which I'm constantly passing over to others so they can use it whenever I'm not busy.

Plus, NTFS is great for porn-hiding :D

Dr Unne
11-28-2001, 06:14 PM
I thought WinXP Professional required an NTFS filesystem. If I'd have known I could've used a FAT32 I probably would've.

Aexoden: I think I saw that project too. I think that's more for enabling write-access to NTFS systems, which as of now doesn't work, I think. (Everywhere I see to download write-access support, there're all sorts of warnings like "This is dangerous! Don't use it! I'm serious! It'll destroy you!" Things like that.) I thought they already had the read-only part down pretty good. Read-only NTFS support came with my RedHat distribution, but I know I have to recompile the kernel to enable it.

Ah well. Trial-and-error is probably the best way to figure it out. 90% of computer knowledge is gained by screwing stuff up a couple times and figuring out what you did, it seems.

crono_logical
11-28-2001, 06:56 PM
Nope, it doesn't :p I left mine as FAT32 because I didn't see a need for it, and I also use Linux occasionally so would be nice to still have rw access to everything :)

Dr Unne
12-08-2001, 02:03 AM
Well, I got it to work. It took a couple more tries, but I figured it out. It seems my problem was more in getting all my other hardware to work right (my USB mouse was the main problem) after recompiling the kernel. RedHat autodetected my mouse fine during install but it took some work to get the kernel to recognize it myself. All I did was ran usr/src/linux-2.4/make menuconfig; figuring out teh right options to include took the most time. Then I ran make dep, make clean, make bzImage, make modules, make modules_install, then copied the bzimage to /boot, changed /etc/grub.conf to add a menu option for the new boot image, and it worked fine. The command to mount the ntfs drive took awhile to figure out too, since by default ntfs drives only give priveledges to the root user and no one else, but mount -t ntfs -o umask=0222 /dev/hda1 /XP worked fine. That gives all users write and execute access. There is no write access for anyone of course. It's not supported by the kernel yet, and I wouldn't use it if it was.

If I can do it I'm sure you can too Bleys. Now I need to figure out how to add that stuff to my fstab. :(