LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
LinkBack Search this Thread
Old 05-17-2009, 12:24 AM   #1
Absolute Zero
LQ Newbie
 
Registered: May 2009
Posts: 4

Rep: Reputation: 0
NTFS Partition Problems on HW Raid 5 Array


Ok. I've been trying to figure this out for about a week. I've decided I need to ask the Gurus out there.

I have a linux machine running Fedora 10 on a primary hdd.
For storage I had an Areca 1210 hardware raid controller with three 750gb WD RE2 hdds. I have them set up in Raid5 therefore I had 1500gb of storage which was being automounted on boot.

Well, it came time for a storage increase (b/c it was full of backups) so I decided to add another 750gb RE2. I went through the procedures for adding the drive (expand the raid set and modify the volume set for the increased size) but the full space was still not available in Fedora.

I opened up Gparted and noticed that the full disk was showing up, but the space just couldn't be used because the NTFS partition hadn't been expanded. So, I used Gparted and resized the partition to fill the full space. I thought I had solved my problem because I could now use the full space (2.05tb).

I thought everything was fine b/c there were no problems. However, after a reboot now it won't mount the drive. It says there's something wrong with the NTFS partition. And if I open up Gparted again it shows the unmounted array as the full size but it only shows that about 50gb are in the ntfs partition and the other 2TB are unformatted space. If I try to resize again (which I was really hesitant to do anyway) it says it can't until the partition is fixed.

Note: I've tried running live versions of Knoppix and Fedora and nothing I try will mount the array.

output of commands ran:
=======================
[root@localhost Absolute_Zero]# ntfsfix /dev/sdb
Mounting volume... Failed to startup volume: Invalid argument.
FAILED
Attempting to correct errors... FAILED
Failed to startup volume: Invalid argument.
Volume is corrupt. You should run chkdsk.

[root@localhost Absolute_Zero]# ntfsfix /dev/sdb1
Mounting volume... Failed to read $MFTMirr: Input/output error.
FAILED
Attempting to correct errors...
Processing $MFT and $MFTMirr...
Reading $MFT... OK
Reading $MFTMirr... FAILED
Failed to read $MFTMirr: Input/output error.

[root@localhost Absolute_Zero]# mount -t ntfs-3g /dev/sdb1 /media/RAID
Failed to read last sector (4394528728): Invalid argument
HINTS: Either the volume is a RAID/LDM but it wasn't setup yet,
or it was not setup correctly (e.g. by not using mdadm --build ...),
or a wrong device is tried to be mounted,
or the partition table is corrupt (partition is smaller than NTFS),
or the NTFS boot sector is corrupt (NTFS size is not valid).
Failed to mount '/dev/sdb1': Invalid argument
The device '/dev/sdb1' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?

[root@localhost Absolute_Zero]# mount -t ntfs-3g /dev/sdb /media/RAID
NTFS signature is missing.
Failed to mount '/dev/sdb': Invalid argument
The device '/dev/sdb' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?
==================================================================

I started trying to run chkdsk (which means I had to find an XP disc) because that was what everything was recommending. But tonight I found something saying that you should never run chkdsk on a RAID array because of the layout. So now I'm at a loss and I have no idea what to do. If I SHOULD still run chkdsk then I have to come up with a 64bit xp disc because my linux system is the only 64bit in the house.


Any suggestions or help? I can't bare the thought of losing everything I've downloaded or backed up for the last several years.
PLEASE...I'm begging for some feedback on this. Is there anywhere else I should look?

Anyone know how to fix NTFS partitions without using a Windows solution?

Last edited by Absolute Zero; 05-17-2009 at 12:41 AM.
 
Old 05-17-2009, 03:39 AM   #2
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
After using gparted to create or resize NTFS partitions, you have to boot into Windows. The reason for this is it sets NTFS partitions as dirty. At this time only Windows 2000 or up can scan NTFS partitions.

Expanding a present RAID-5 array will always have problems. It is best to back up the data and then try to expand the array. If you did not do that and you have problems, the chances of losing data is very high.

You try to use photorec and foremost to try to extract the data as much as you can. Then try using Windows to fix your NTFS partition.

If you are using NTFS for back ups and you are switching between Windows and Linux, you have to use commercial programs and have a high chance of data corruption in Linux. EXT2 or EXT3 will be a lot better. Windows can read and write to EXT2 by using EXT2 IFS.

You do not need a 64-bit OS to access 2 TB of hard drive space. A 64-bit OS is required when using 4 GB of memory on an 80x86 system. A file system coded with 64-bit blocks has the ability to handle 2 TB of hard drive space and more with out the ability for the OS to be 64-bit.
 
Old 05-17-2009, 10:20 AM   #3
Absolute Zero
LQ Newbie
 
Registered: May 2009
Posts: 4

Original Poster
Rep: Reputation: 0
So is chkdsk safe to use on a Raid array?

So it is REQUIRED to use Windows to fix this NTFS partition? B/c I'm having trouble even doing that. I just tried running the Recovery Console and loading the HW Raid drivers when it asked, and the drive still doesn't show up in the volume list. Therefore, I can't run chkdsk from there. The only option I'm seeing right now is grabbing an old harddrive and installing WinXP on it just so I can run chkdsk.

The reason I was asking about the 64bit stuff is because my system won't run the 32bit install discs.
 
Old 05-17-2009, 03:31 PM   #4
Absolute Zero
LQ Newbie
 
Registered: May 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Several places say "don't run CHKDSK on a Raid array". I'm not sure why this is since the hardware raid card is basically functioning so that as far as the OS is concerned it is one disk. It's not like the OS can tell that it is multiple disks. So if it can be run on one disk, it should still work (i would think).

I've tried UBCD (none of the progs seem to recognize the raid array)
UBCD4Win (after loading driver, it still doesn't let me access the array. Probably requires a reboot but it's a live version of Win so I can't)
Knoppix live (finds the raid array fine but just won't mount and gives the same error as Fedora)
Fedora live (same as Fedora)
Windows Recovery Console (lets me load the driver for the HW raid but still doesn't list the drive or give me access)
Gparted live (can't do anything until the partition is fixed)

Anyway, here's what I'm down to so far as courses of action and I need some suggestions...

Should I:

A) pull my primary hdd that has Fedora on it, and replace it with another hdd and install WinXP so that I can run chkdsk on that drive?
B) Find some software that would allow me to possibly pull my data off of that partition onto an external drive and then reformat the raid array and move all the data back over

With option A, is there a higher risk of data loss?
With option B, I would be fine with buying an external drive to back it up as long as I'm sure I can get to the data. So, that means I would have to find software that would run on linux that allows me to view and copy files off the raid array even though I can't mount it. Is this even possible?

One thing I don't get is why is it being marked "dirty" now? I set this drive up in linux initially and created the partition and formatted NTFS from within Gparted originally without any problems. It just seems that this new "resize" is what caused the problems. Should I not have resized the partition to the end? Is there some space that is needed at the end of an NTFS partition for the tables? So if I had resized to 2.00TB instead of 2.05TB it would have worked? I've been seeing a lot of stuff about "superblocks" on ntfs.

Right now I need to know the most probable way of getting my data safely off the drive even though it can't be mounted. This is the absolute most important thing. I will buy drives to back it up. That's not a problem. I just need to make sure I get everything from this partition.
 
Old 05-17-2009, 07:28 PM   #5
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
What you should do is re-read my previous post. I suggested to run both photorec and foremost to start recovery as much data as possible. Then you can think about reconstruction. I suggest use the following devices to image the drive to some else to extract as much data using photorec and foremost.

SANS DIGITAL MS2UTN+ (set in FAST mode or RAID-0)
(2) Western Digital Green 1 TB (WD10EADS)

Since from the pictures of SATA connectors, it looks easy to hit them loose. I suggest do not jump inside the computer. I suggest copy the OS drive to some where else and install Windows on the present system.

From what I gathered. Data recovery services say to not use CHKDSK or FSCK with RAID, but to use their programs. IMHO, use CHKDSK and FSCK for fixing data, but figuring out about hardware damage is to use both the utility from the controller and hard drive manufacture. Both CHKDSK and FSCK has two stages. One they scan the data integrity of the file system and fix it. The other stage is they do a surface scan or a sector scan which is useless for just about any setup. A sector scan should be done by the hard drive manufacture utility for better results. Doing a sector repair on a RAID could damage the data. RAID-5 and RAID-6 is affected more with sector re-allocation than other RAID levels. When using either CHKDSK or FSCK, tell them to fix the file system and not the sectors. Fixing the file system is higher level than fixing the sectors. Though I have not never used RAID, but I have read about it.

A utility named File Scavenger from Quetek looks good and I have not used it. It comes from a data recovery service, so they can help you with the recovery process or they can do it for you.

The reason why gparted has marked NTFS as dirty is because it still an unknown file system. There are no utilities to fix NTFS with open source utilities. Sure you can force to change the dirty bit of the file system to clean in order to mount it. You run in a very high chance of data corruption. NTFS is still unknown to the open source community. It is best to avoid using it in Linux. If you are going to use it, mount it as read-only to be safe. Again a safer file system, with out the file size limit, and to be used with Linux and Windows is EXT2. The safest is FAT, but it has a file size limit of 4 GB and it can only be formatted up to a terabyte.

A 64-bit computer that will not handle a 32-bit OS is just asking for problems. I have never heard or read a 64-bit 80x86 processor that has problems running 32-bit programs. All I can think it is a user related problem when using 32-bit programs or the processor is defective.
 
Old 05-17-2009, 10:10 PM   #6
Absolute Zero
LQ Newbie
 
Registered: May 2009
Posts: 4

Original Poster
Rep: Reputation: 0
SOLVED IT!!!!!!!!!!!!!

I downloaded System Rescue CD from here...
http://www.sysresccd.org/Main_Page

which contains what I needed which was "TestDisk" which is discussed here...
http://www.cgsecurity.org/wiki/TestDisk

After booting into this CD, I ran "TestDisk". It then searched for drives in the /dev/ folder.
Then it asked you to select which one you want to fix.
Then after you select it there's an option at the bottom for "Boot".
I chose that then told it to rebuild the boot sector.
Apparently GParted damaged the boot sector when it resized the partition.

But all is well now. I have access to all my files. I new I was using the right program when it was able to list the file contents of the drive even before I wrote the bootsector info. Anyway, SystemRescueCD will definitely be on my system repair hotlist. Recommended for anyone having partition problems.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Shrink NTFS partition in RAID 1 array pwc101 General 4 11-15-2008 03:51 PM
Install Fedora7 on existing NTFS Raid-0 Windows array evilkorn Linux - Newbie 1 06-28-2007 07:38 AM
RAID help restoring a degraded array partition jahlewis Linux - Hardware 2 10-17-2006 07:55 PM
Unable to Mount NTFS RAID O Array lpboarder23 Suse/Novell 1 03-14-2006 04:29 PM
Help accessing data on NTFS raid array Qwindelzorf Linux - Hardware 2 01-15-2005 02:34 PM


All times are GMT -5. The time now is 07:44 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration