Resizing ntfs partition

Lars Rasmussen lars.rasmussen at
Thu Mar 1 19:41:15 MST 2007

Today at work I had an opportunity to give ntfsresize a try.

I installed the OS yesterday(W2K3 Standard) on a brand new HP ProLiant
DL360 G5.  Today my boss told me he wanted the partitioning scheme
changed.  (C:) should occupy ~40GB, and the remaining ~69GB should be
a second primary partition (D:).  The new partition (D:) would also be
formatted as NTFS.

I originally installed one logical drive(C:) as NTFS spread over four
75GB physical drives as a RAID 5 array.

So I tell my boss, "No problem", thinking that ntfsresize should make
quick work of this problem.  Failing that, I can try a commercial
product, right?

I booted into Knoppix and saw 4 penguins for the first time.

I ran:
fdisk -l

and that showed the SAS RAID 5 array as   /dev/cciss/c0d0p1

With my handy dandy 160GB external drive attached via USB, I backed up
the MBR using dd & then backed up /dev/cciss/c0d0p1 to the USB drive
with partimage.

Afterward I ran:
ntfsresize --no-action --size 40GB /dev/cciss/c0d0p1

Testing info looked good, next is for real:
ntfsresize --size 40GB /dev/cciss/c0d0p1

ntfsresize appeared to make quick work of resizing the original
partition, and I rebooted into W2K3, which promptly ran chkdsk as
expected.  The problem came when viewing the drive in Windows.  The
(C:) drive appeared to return contradictory info.  (C:) was now a 40GB
drive, with a small portion used.  Sounds good so far.  When I viewed
the drive with Disk Manager, there was no free space on the physical
drive.  There should have been ~69GB unallocated, but it just wasn't

I tried rebooting with Acronis Partition Expert 2003 - the program was
unable to see my array at all(perhaps due to lack of drivers), so no
luck there.

I tried rebooting with Partition Magic.  PM was able to view all 209GB
of the array - but displayed an ugly yellow Error #106 indicating
errors in the partition table values.  At this point I thought, "I'll
just delete the partitions, create new ones with the correct sizes,
and restore the partimage backup into the newly created partitions."

PM was unable to even create the partitions, so booted to knoppix again and ran:

dd if=/dev/zero of=/dev/cciss/c0d0 bs=1024 count=1024

I then ran CFDISK and created 2 primary partitions of the desired
sizes of TYPE 07(HPFS/NTFS), the first being bootable.  Next step, to
restore the image:

partimage restore /dev/cciss/c0d0p1 /dev/sda1/mybackup.partimage

partimage promptly issued a segmentation fault.

My last step was to try and restore the backup in its original config,
so I deleted the partition table again, & afterward ran:

partimage restore /dev/cciss/c0d0 /dev/sda1/mybackup.partimage

partimage began the restore.  At this point I had to go home, and my
boss suggested I rebuild the server from scratch in the morning.  I

Any ideas on what I should have done differently?

More information about the PLUG mailing list