*BSD News Article 45906


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!simtel!zombie.ncsc.mil!news.mathworks.com!news.kei.com!nntp.et.byu.edu!news.caldera.com!park.uvsc.edu!usenet
From: Terry Lambert <terry@cs.weber.edu>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Resizing File System Partitions
Date: 24 Jun 1995 02:15:35 GMT
Organization: Utah Valley State College, Orem, Utah
Lines: 60
Message-ID: <3sfsg7$c0k@park.uvsc.edu>
References: <jeremy.262.2FEB07F7@cfs.purdue.edu>
NNTP-Posting-Host: hecate.artisoft.com

jeremy@cfs.purdue.edu (W. Jeremy Nauck) wrote:
]
] Could anyone briefly give me some instructions as to how I would go about 
] resizing a file system partition??  I've got a 100 Meg partition that only 
] uses about 8 Meg, and I would like to re-size this down to 20 Meg.  The 
] remaining 80 Meg would then be added to an already existing partition.  Thanks 
] in advance!!

What do you mean, "file system" and "partition"?

If you mean you want to steal room from a DOS file system to give
to BSD, you will need to:

1)	Backup the BSD data that you want to save (configuration
	files you have modified, etc., basically anything that
	didn't go on as part of the initial install process).
2)	Run fips to shrink the DOS partition.
3)	Delete the BSD partition
4)	Reinstall BSD.
5)	Restore your local information from your backups.


If you mean you want to steal room from one BSD filesystem for
another, and one of them is the root partition, you will need to:

1)	Backup the BSD data that you want to save (configuration
	files you have modified, etc., basically anything that
	didn't go on as part of the initial install process).
2)	Delete the BSD partition.
3)	Reinstall BSD.
4)	Restore your local information from your backups.


If you mean you want to steal room from one BSD filesystem for
another, and neither of them is the root partition, you will need
to:

1)	Backup the partitions involved.
2)	Unmount them.  This probably shouldn't be necessary,
	since you should be doing this in single user mode.
3)	Using the disklabel -e command as root, adjust *only*
	the partitions you are playing around with.
4)	Manually run the newfs command to "reformat" the disk
	partitions.  This will blow away any data on them.
5)	Mount the partitions an restore the file system contents
	from the backup media.


In BSD's defense, you can *not* move the boot area for any OS
for which you have a bootable partition without a lot of work
(at best) or a reinstall (at worst, and most likely).  That BSD
would let you adjust partitions that aren't the boot partition
without reinstalling is pretty amazing in and of itself.


                                        Terry Lambert
                                        terry@cs.weber.edu
---
Any opinions in this posting are my own and not those of my present
or previous employers.