Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 23 Nov 2005 00:24:15 +0100 (CET)
From:      Wojciech Puchar <wojtek@tensor.3miasto.net>
To:        freebsd-questions@freebsd.org
Subject:   growfs - to fear or not to fear?
Message-ID:  <20051123001731.D38500@chylonia.3miasto.net>

next in thread | raw e-mail | index | archive | help
did anyone used this little thing?

i have system like this:

# /dev/ad0:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
   a: 18432000        0    4.2BSD     2048 16384 28552             (/)
   b:  2457600 18432000      swap
   c: 312581808        0    unused        0     0
   d: 291692208 20889600    4.2BSD     2048 16384 43400         (/home)


and would like to have one partition+swap, not two.

after booting from CD and turning on shell will

1) copy files from partition a to d, and put files from partition d's root 
to d's home.

mount -o async,noatime /dev/ad0d /mnt
cd /mnt
mkdir home
mv * home
mount -r /dev/ad0a /mnt2
(cd /mnt2;tar cf - .)|tar xpf -
umount /mnt2
cd ..
umount /mnt

2) bsdlabel and delete b, set up a partition to end of disk-1GB, and b 
after a, not deleting d (yes it will overlap temporarily)

3) dd if=/dev/ad0d of=/dev/ad0a bs=1m to move

4) bsdlabel and remove d

5) FINALLY - growfs /dev/ad0a

6) boot0cfg to make it all bootable.




can i do 5) without fear? i want to do full dump of my data, but don't 
like to do it twice (before for sure, and then after repartitioning).



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051123001731.D38500>