Jump to content
Compatible Support Forums
Sign in to follow this  
m1ndctrl

Recognizing my NTFS partition in Redhat 9

Recommended Posts

I have just a quick question.

 

 

I want to be able to access my NTFS (WIN XP) partition via redhat in the /mnt/ directory. In other words I guess I need to mount it.,

 

So I have learned that fstab is the file I need to edit.

 

however I'm not sure what the line of code I need is.

 

Would it be something like mount /dev/hda1 /mnt/windows ?

 

Anybody know what the exact line I need to put is?

 

Thanks in advance.

Share this post


Link to post

Well after about 30 minutes of tinkering I have made some progress. Turns out I didn't have the NTFS RPM's installed.

 

Anyways, I installlation went fine, but I get an error while botting up, hence my partition isn't mounted

 

Quote:

Mounting Other Files systems:

mount: wrong fs type, bad option, bad superblock on /dev/hda1,

or too many mounted file systems

(could this be the IDE device where you in fact use

ide-scsi so that sr0 or sda or so is needed?)

 

I get the same error when I try to do it through terminal.

 

 

Any suggestions?

 

Thanks

Share this post


Link to post

Did you have installed the right NTFS Kernel module for your Kernel? Both (the NTFS module and the kernel) need to be the same version.

Share this post


Link to post

My kernel version is 2.4.20-19.9 (the newest one).

 

The version I got matches the kernel, aswell as my CPU (athlon).

Share this post


Link to post

It's a module, so you have to modprobe it before it'll work. If you want to avoid that, open up /etc/rc.d/rc.local in your favourite editor and right at the bottom add the following line:

 

Code:
modprobe ntfs

 

That will cause the module to be autoloaded at boot but probably not soon enough to allow your NTFS partition to me mounted at boot so add the noauto paramater to it's line in fstab like in my example above and then, if you still want it to want it to be mounted at boot, add mount /mnt/windows to rc.local.

Share this post


Link to post

I add these lines to rc.local

 

modprobe ntfs noauto

mount /mnt/windows

 

 

However, I still have no luck. I get the same error::

 

Mounting Other Files systems:

mount: wrong fs type, bad option, bad superblock on /dev/hda1,

or too many mounted file systems

(could this be the IDE device where you in fact use

ide-scsi so that sr0 or sda or so is needed?)

 

Anything else I could try?

 

Thnx

Share this post


Link to post

noauto has to be in the file /etc/fstab like this:

 

Code:
/dev/hda1 /mnt/windows ntfs noauto,ro,users,umask=0222 0 0

 

Unless you have a line like that (I'm not sure if that's entirely correct as I don't have access to my Linux box) in your fstab, mount /mnt/windows won't work, you have to mount it the long way:

 

Code:
mount -t ntfs -r -o umask=0222 /dev/hda1 /mnt/windows

Share this post


Link to post

I tried the longer command, and it didn't work either.

 

I get the same error.

 

 

It actually told me I had a bad line when I put it in the longer way.

 

I guess that way is dropped? because all of the other entries are in the /dev/###/ /mnt/### format.

Share this post


Link to post

My memory was better than I thought, this is what I have in my fstab:

 

Code:
/dev/hde1		/mnt/windows	ntfs		noauto,ro,users,umask=0222		0 0

 

I'm mounting /dev/hde1 because my HDD is connected to an off board ATA133 controller but otherwise the line you need will be identical. The big difference between your setup and mine though is you're loading NTFS as a module whereas I have it compiled into my kernel proper. That shouldn't be a problem as long as you remember to load the ntfs module. To check if the module is indeed loaded, type this:

 

Code:
cat /proc/filesystems | grep ntfs

 

If you see the word ntfs appear, it's loaded. Otherwise, type modprobe ntfs and try again. If it still doesn't work you're more than likely using the wrong module for your kernel.

Share this post


Link to post

The word ntfs does appear when I type

 

cat /proc//filesystems | grep ntfs

 

Which means that the module is loaded.

 

 

However, I have no success. I don't even get errors or anything anymore, it's as if the whole editted part is by passed.

 

Also while I boot (close ot the end) I get three lines something like this:

 

UP[censored] FSTAB {OK}

FLUSHING ALL USER EDITTED bla bla bla {OK}

REBUILDING bal bal bla [OK]

 

 

is there an option perhaps that I have to enable it to use a custom fstab? kind of like a safety feature?

Share this post


Link to post

Well, she works =)

 

 

It turns out that my NTFS partition is hdC1 not hdA1

 

 

Werid, as they normally are hdA1.

 

 

Thank you a million !!!

Share this post


Link to post

By all accounts, it should be working now. The NTFS module is loaded and the fstab line I posted is correct (assuming you've correctly modified the source device and destination directories to suit your setup and made sure the directory you're trying to mount it into exists). One thing I did notice just now, and it's my fault for not being entirely clear, is that you're putting the lines in the format:

 

Code:
mount -t ntfs -r -o umask=0222 /dev/hda1 /mnt/windows

 

into fstab where in actual fact they have to be entered at the command line (as root). Lines in the format:

 

Code:
/dev/hde1      /mnt/windows   ntfs      noauto,ro,users,umask=0222      0 0

 

are fstab entries and when working right, can be mounted simply by using the destination directory:

 

Code:
mount /mnt/windows

 

Once again, this is my fault for not being clear enough and for that I apologise.

 

Now, if you can mount it from the command line then that means everything is set up and working right so we can move on to figuring out just why it won't work when put into fstab.

Share this post


Link to post

Well, as I said previously, I did manage to get it working. The name of my NTFS partition is not hdA1 but hdC1.

 

The "Can't read super block errors" got me thinking thati t was more of a partition problem and then it hit me that perhaps i'm using the wrong name for the patition.

 

 

So now the partition auto loads on start up and everything. It's working perfect, except for one minor thing. I need the drive to be both read AND write. I thought it might be just the permissions however, when I try and change the permissions (as root) it says can not enable write to read only device.

 

So I'm thinking that it has something to so with the line in fstab? As in, I need to mount it as read/write correct?

 

 

Sorry if I'm being a real pain, I've only been using linux for a limited ammount of time, but I'm trying to learn! =)

Share this post


Link to post

I missed your second post, you got it in before mine so I didn't see it. Anyway, you're not going to see NTFS write support in Linux for a long time, read only is the best you're going to get. Enabling write support has the potential to cause serious data corruption which is why the RPMs disable it and a huge warning message appears next to the relevant section in the kernel configurator.

 

If you really need write access, the best you can do is set up a FAT partition which Linux fully supports and move your files there so you can access them in Linux. Another option is to use a program like Partition Magic to convert your NTFS partition to FAT but I wouldn't really recommend that (what you gain in Linux support you'll lose in the overall unreliability of FAT as a file system).

Share this post


Link to post

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×