[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: want to change /var/log partition to a directory in /var --help



cd /var
cp -r log log.bak # or cp -r log /home/log.bak is /var is too small
umount log
rmdir log
mv log.bak log

If the partition that used to be mounted under /var/log is just after
/var, then you can extend /var:
* with fdisk:
	-# delete /var/log
	-# write down where /var begins (press u to see the addresses in
	   blocks instead of cylinders)
	-# delete /var
	-# create a new partition for the whole free space. The new
	   partition must begin at exactly the same address as the old /var
	-# say a prayer
	-# press w for write
now you can also resize the filesystem with ext2resize, xfs_resize etc.
This one is tricky again as XFS can be resized online, ext2 not etc.
Please supplyu some details if you want to continue on this path.

Good luck,
Ionut

On Tue, May 24, 2005 at 03:13:33PM +0530, Siju George wrote:
> Hi all,
> 
> As I installed my Debian I gave very little space for /var/log
> partition and the partition is full now and the system is slow :-(
> 
> how can I change the "/var/log" from the "/var/log"partition to the
> "/var" partition under a directory "/var/log"
> 
> Could someone please tell me what steps should I take so as not to
> miss the current logs too???
> 
> Thankyou so much
> 
> Kind Regards
> 
> Siju
> 
> 
> 
-- 
***************
* Ionuţ Georgescu
* Max-Planck-Institut für Physik komplexer Systeme
* Noethnitzer Str. 38, D-01187 Dresden
* Phone: +49 (351) 871-2209
* Fax:   +49 (351) 871-1999 

Attachment: signature.asc
Description: Digital signature


Reply to: