Page 1 of 1

problem creating/labeling 4TB drive in MCC

PostPosted: Nov 15th, '12, 12:20
by wintpe
OK, perhaps knowing that 4TB drives need GPT partition i should not have dived into MCC to use its disk labeling and formating section to setup an additional 4TB hitachi drive i just purchased.

However, as i had not had one of these drives before , i had not used the parted commands, (ive always used fdisk) so i took the easy route, as any non techy user might have done.

wow MCC labeled the disk and i then I run mkfs.ext4 on it and it mounted as a drive with 3.6 TB of space.

So I thought to myself, nice, all sorted and started to transfer the contents of my 2 TB drive to it which was running low on space.

I took the drive out and put it to one side, then the following day plugged it in, run the kernel workaround script to fix the "still outstanding hot plug problem", with mga2 (come on guys its been out 6 months), and tried to mount the disk.

at which point it said could not mount file system corrupt.

I run an fsck on it and it passed correctly, but bitched about filesystem size being wrong.

I opened up MCC disk section to have a look at it, and the data section was now only occupiying 40% of the 4TB disk.

So i looked at the partition with fdisk and sure enough it was not GPT.

so with warnings of im about to loose my data, and knowing its only the partition boundaries that im altering i set out to correct the partition with parted.

first setting the type to GPT with mklabel GPT

then setting the label with mkpart primary 0GB 4009GB

once id quit, fdisk -l was showing the partition correctly but fsck kept moaning that the filesystem was a different size and giving me the size it should be (cant recall the number now, but it was shorter that the size it was repoorting to be,
so i used resize2fs to correct the size.

fsck it again, this time clean.

mounted it, and whola, data all back.

scary time, as i had moved all that data not copied it, and it would have been a total loss.

So Im guessing MCC does not properly set 4TB drives, and although on the face of it it looks OK when you start using it, it seems to lead to disaster.

Or something to do with the hotplug workaround corrupted the disk? this is unlikly, I suspect MCC just did the wrong thing.

But if it had just not worked , then i would not have been led into a false sence of security.

and wold have done it from the outset with parted.

feedback welcome, is this a bug with MCC, should it have correctly partitioned the disk, why did it partition the disk , appear to work and then leave me with a corrupt disk on attempted remount, also if this is a bug, hopefully sharing my expirience might save someone else a problem.

regards peter

ps, while i was thinking about how to fix this i considered undeleting the contents of the origional 2TB, tried extundelete, and ext3grep.

the extundelete was a rpmrebuild of the mga3 version. this started but then seg faulted when it found the number of files and started to undelete, and the ext3grep just failed with an unrecognized structure in the journal (maybe it just wont work with ext4).

Re: problem creating/labeling 4TB drive in MCC

PostPosted: Nov 16th, '12, 10:36
by magfan
I had problems to partition an external 10TB drive (actually a hardware RAID5) with mcc. After installing gdisk from the repositories mcc was able to handle this drive properly. The program fdisk which is used per default in mcc cannot manage such huge drives.

Re: problem creating/labeling 4TB drive in MCC

PostPosted: Nov 16th, '12, 12:00
by wintpe
If you are right , that MCC will do the wrong thing with a drive unless a util that is not installed by default
is installed and potentialy loose a user data then that is a major bug.

MCC should have recognised (be coded in such a way) that fdisk is not able to handle such a disk and refused to work with it

perhaps calling rpm/urpmi to install gdisk , like it does for printers and scanners, or using parted.

however i regognize because of the premium price few people are buying 3 or 4 TB drives when 2TB are so cost effctive,
hence why its not been raised many times.

regards peter

Re: problem creating/labeling 4TB drive in MCC

PostPosted: Nov 16th, '12, 12:34
by magfan
Yes, I know. Unfortunately, I posted the problem (and it's solution) with my 10TB RAID only on the german forum. It was a brand new RAID and there was no chance to loose any data. That is why I did not send a bug report. And yes, I discovered it in Mageia 1.

https://forums.mageia.org/de/viewtopic.php?f=7&t=596&p=7129&hilit=gdisk#p7125

Re: problem creating/labeling 4TB drive in MCC

PostPosted: Feb 1st, '13, 16:06
by hintzy64
wintpe wrote:however i regognize because of the premium price few people are buying 3 or 4 TB drives when 2TB are so cost effctive,
hence why its not been raised many times.

But prices are coming down and they're going to become more common, so this should probably be addressed sooner than later. ;)