How to Re-Label / Re-create filesystems?
jerrymc at msu.edu
Mon Oct 2 12:47:59 PDT 2006
On Mon, Oct 02, 2006 at 02:46:06PM -0400, Wayne wrote:
> Could someone point me to instructions or offer suggestions on how to
> re-configure file systems on a 6.x system?
> When I installed from CD, I used the sysinstall menu, which I guess
> actually calls bsdlabel and newfs (??)
> I want to delete two filesystems, and recreate one large one in the same
> space. I tried dropping to single user and running sysinstall, but it
> protests it can't write to the device... even when I only had things
> mounted read-only. Can I safely use the boot CD to do this? I don't
> want to experiment too much and clobber the whole drive!
Sysinstall calls fdisk, bsdlabel and newfs as well as mkdir to create
your mount points.
Yes, you can do it from a CD boot.
FIRST: Back up every file system on the disk you are modifying using dump
on to some media that will be unaffected by the changes, such as tape or
Boot the CD and select the fixit item - I can't remember just how
it is labeled and don't want to take something down to look right now.
But, it is the one that gives you a limited running system with UNIX
Then, use bsdlabel to create a new partition structure. Make sure
you make the a partition bootable. It probably already is and won't
be affected by these machinations as long as you don't change the slice
or boot sector.
Then newfs the partitions to make file systems of them.
Fix up your fstab file to reflect the changes
reload the dumps using restore.
Make sure you CD in to each file system to do the restore for it.
Reboot. If you messed up fstab, you may have to boot in to single
user and fix it.
Should work just fine.
> -Thanks, Wayne
> freebsd-questions at freebsd.org mailing list
> To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"
More information about the freebsd-questions