Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

LV size reduction - sanity check

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
HI...

I have to reduce the size of an lv (/home)
on my rootvg and I was just performing
a sanity check so I didn't miss anything.

I have my rootvg mirrored from hdisk0 to
hdisk1.

Can I simply remove the lv (after backup of
course), or do I need to break my mirror
first. If I don't need to break the mirror,
will the mirroring be automatically restored
when I re-create the LV?

TIA,

Jimmy
 
You need to break your mirror before you do that. And after you reduce the size you can then mirror it back. I am sure you are aware you can add and remove copies for lv's using mklvcopy and rmlvcopy. You will need to make sure nobody is active when you remove the filesystem. One other thing I am not completely sure of is if /home since it is on rootvg will allow you to umount it while the vg is varied on (/usr does not allow that), but am inclined to think /home does allow unmounting. I would also do a syncvg -l logical_volume_name after recreating it.
 
You can umount and mount /home, subject to the open file/inode restrictions like most other filesystems. Basically you'll have to have everyone else off, and be logged in directly as root (no "su" business).
 
Thanks everyone....

So let me make a quick check list:

1) umount
2) rmlvcopy
3) rmfs (which removes the lv)
4) mklv
5) mkfs
6) mklvcopy
7) mount

TIA,

Jimmy
 
1) backup
2) rmfs (don't need to rmlvcopy, rmfs will take care of all of it)
3) mklv -c 2 (-c 2 = 2 copies so you don't have to mklvcopy later)
4) crfs
5) mount
6) restore
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top