All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] Resizing an ext3 file system after extending a logical volume group
@ 2007-09-18 20:58 Richard Kollmar
  2007-09-18 21:07 ` malahal
  2007-09-28  4:33 ` Drew
  0 siblings, 2 replies; 3+ messages in thread
From: Richard Kollmar @ 2007-09-18 20:58 UTC (permalink / raw)
  To: linux-lvm

[-- Attachment #1: Type: text/plain, Size: 1747 bytes --]

Dear All:

I apologize if this has been asked before, but I can't find a way to  
search the list archives:

How do you safely resize an ext3 filesystem after extending a logical  
volume?

I am adding a new hard drive to increase the size of my logical  
volume "home1" in logical volume group "home" with LVM2 under Ubuntu  
6.10.1 LTS.  The instructions in the LVM Howto are pretty  
straightforward; the only part that spooks me is the resizing of the  
ext3 filesystem.  This is what I have done so far:

	(installed new hardware & partitioned with fdisk; shows up as /dev/ 
sdb1)
	(backed up the existing logical volume in case something bad happens)

	# pvcreate /dev/sdb1
		  Physical volume "/dev/sdb1" successfully created	

	# vgextend home /dev/sdb1
		  Volume group "home" successfully extended	

	# lvextend -l 357700 /dev/home/home1
		  Extending logical volume home1 to 1.36 TB
		  Logical volume home1 successfully resized

 From what I googled, the next steps are a bit more involved for LVM2  
than the Howto lets on.  Does the following look o.k. to the experts:

	' use a root login, not su or sudo, because /home will be unmounted

	# umount /dev/home/home1	' the next steps should be done off-line

	# e2fsck -C 0 -v dev/home/home1		' make sure the file system is ok

	# tune2fs -O ^has_journal /dev/home/home1	'disable journaling on the  
logical volume

	# resize2fs /dev/home/home1		'do the resizing

	# e2fsck -C 0 -v dev/home/home1		' make sure the file system is  
still ok

	# tune2fs -O has_journal /dev/home/home1		're-enable journaling

	# e2fsck -C 0 -v dev/home/home1		' yes, I am a first-timer and  
somewhat paranoid

	# mount /dev/home/home1 /home	' back on-line

Thanks in advance for any help,

microscope


[-- Attachment #2: Type: text/html, Size: 6473 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-09-28  4:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-18 20:58 [linux-lvm] Resizing an ext3 file system after extending a logical volume group Richard Kollmar
2007-09-18 21:07 ` malahal
2007-09-28  4:33 ` Drew

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.