Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Mar 2008 21:00:20 +0100 (CET)
From:      Wojciech Puchar <wojtek@wojtek.tensor.gdynia.pl>
To:        Jeffery Swan <scientist@engineer.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Expanding file system
Message-ID:  <20080303205522.L52185@wojtek.tensor.gdynia.pl>
In-Reply-To: <20080303151000.4183D1F50B1@ws1-2.us4.outblaze.com>
References:  <20080303151000.4183D1F50B1@ws1-2.us4.outblaze.com>

next in thread | previous in thread | raw e-mail | index | archive | help
growfs can expand UFS filesystem. worked for me with normal partitions, if 
you use geli with sector size != 512 bytes, it won't, but i've patched it 
for that. still - it's buggy.

but really don't assume it won't screw up your filesystem...

if you like to try do:

a)unmount this fs
b) fsck it to make sure
clear up new space with zeroes (yes, it will make it easier to survive 
after growfs)

use dd if=/dev/zero of=/dev/yourpartition bs=1m seek=oldsizeinmegabytes

(to obtain size, use dumpfs read blocks data, divide by 2048 to get 
into megs, round result up)

run growfs
fsck this again with -y option, preferably on screen as you'll get 
megabytes of error messages about screwed up inodes (growfs doesn't 
properly initialize new ones, used ones are ok)


data will survive, i had a success just my root directory got destroyed, 
and all subdirs and files went into lost+found).



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