[SOLUTION] Resize NTFS Volume
Posted: 23. Oct 2009, 21:38
After some playing around I found a nice solution for enlarging a disk without any crazy program. I will give a short description, but be reminded that a minimality of linux experience is necessary. The description below is detailed in the sense that several steps could be merged, but I didn't mind doing it one by one.
If you have any comments let me know.
Norbert
- create a new disk the size you want
- attach it to the same controller (as primary slave or secondary slave). Do not use a different harddisk controller for that
- get System Rescue CD
- mount that CD image
- boot into the CD
- now you should have /dev/sda1 your old disk, and /dev/sdb
- use fdisk /dev/sdb and create a new partition on the full disk of type 7 (NTFS)
- use ntfsclone to copy all your data from /dev/sda1 to /dev/sdb1 by calling ntfsclone --overwrite /dev/sdb1 /dev/sda1 mind that this can destroy your old disk if you get it wrong, ie if you reverse source and target!
- try if the new sdb1 can be mounted with ntfs-3g /dev/sdb1 foobar (where foobar is some directory)
- turn off the machine
- detach the old disk and attach the new disk to the primary master
- boot again into the system rescue cd
- install a boot loader with install-mbr /dev/sda --enable 1A --partition 1 --timeout 9
- make ntfs bootable again by calling ntfsreloc /dev/sda1
- shut down your computer
- unmount the cdrom drive
- boot again, now you should boot into Windows as usual, also with the usual size of the disk
- shut down
- mount the System Rescue CD again and boot into it
- call ntfsresize -n /dev/sda1 that will make a test run. If that worked call ntfsresize /dev/sda1 which will resize your ntfs volume to the full partition size
- turn off the computer, unmount the CD image, and boot again
- wait until Windows has checked the filesystem
If you have any comments let me know.
Norbert