- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Reducing a logical volume .
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-03-2001 07:46 AM
тАО12-03-2001 07:46 AM
For some reason, (vg00-lvol8-/var) is allocated 5Gb and I need to shift some of the extra capacity over to (vg00-lvol7-/usr) currently at 500Mb.
Is this possible?
Cheers
Russ.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-03-2001 07:50 AM
тАО12-03-2001 07:50 AM
SolutionIt is not advisable to reduce a logical volume unless you have Online JFS. The best way is to re-arrange the file systems a bit. Since /var is only 500MB, create a standby file system of size 600, copy the contents, destroy /var and create it with probably 1.5 GB and then copy back the contents. You don't have to do this if you have around 1.5 GB free space where you can simply make it as /var. You need to do this in single user mode.
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-03-2001 07:51 AM
тАО12-03-2001 07:51 AM
Re: Reducing a logical volume .
Yes it is possible but sometimes dangerous. You can use fsadm to reduce the filesystem and then use lvreduce to shrink the logical volume.
Man fsadm_vxfs and lvreduce for details.
Your safer option is to:
1) Backup the filesystem
2) umount the filesystem
3) remove the logical volume
4) recreate the logical volume
5) build a new filesystem
6) mount the filesystem
7) restore the filesystem from backup
In any event, backup before doing any of this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-03-2001 01:09 PM
тАО12-03-2001 01:09 PM
Re: Reducing a logical volume .
Everyone has given you great suggestions, one thing that you might want to also think about doing since you have a very large /var and want to reduce it, try doing the following:
1) make_recovery -A -C -v - Creating system tape.
2) Reboot into the path of the tape drive booting into the hpux Ignite-UX utility.
3) Rebuild all of the filesystems that you want to resize.
This may take a little longer but it will probably serve you better in the long run.
Hope this helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-05-2001 02:25 AM
тАО12-05-2001 02:25 AM
Re: Reducing a logical volume .
create a new lvol the size you want.
cp -rp /orig /new
vi /etc/fstab
change the lvol mount info
reboot
remove the orig_lvol
Best way to do it is with fsadm
(Online JFS)
you must first defrag the filesystem, reduce the filesystem (fsadm again) then lvreduce the lvol.. all online.
If it really is a concern to do this online, you need to get OnlineJFS.
Later,
Bill
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-10-2001 02:21 AM
тАО12-10-2001 02:21 AM
Re: Reducing a logical volume .
If you reduce logical volume you may ( 99 %) corrupt data on that logical volume.
In fact, hp-ux didn't mark blocks containing data and those not containing data within the logical volume.
See the manuel page in the Warning section, it's written :
The lvreduce command on a logical volume containing a file systemof greater length than the size being reduced to will cause data CORRUPTION.
Action :
You must plan for an Ignite first to save you data.
Magdi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-21-2001 11:01 AM
тАО12-21-2001 11:01 AM
Re: Reducing a logical volume .
-Gene
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-28-2003 06:00 AM
тАО10-28-2003 06:00 AM
Re: Reducing a logical volume .
1. Advanced Online JFS Insatlled & working properly.
2. The file system be mounted, but inactive.
3. Do not reduce smaller than data size (or data WILL be corrupted!)
Keep in mind this is not an "Online" feature, just added functionality that the Advanced Online JFS package offers.
Assumptions in this example:
-"/m" represents the mountpoint
-The new file system size is 300mb
-The file system is /dev/vg00/lvol6
1.Unmount and mount /m. (Best way to ensure it is not active)
2.Defragment and cluster the data:
#/usr/sbin/fsadm -F vxfs -d -D -e -E /m
3.Shrink the file system (Example 300mb):
#/usr/sbin/fsadm -F vxfs -b 300000 /m (the -b is the new size in KB)
4.Shrink the Logical Volume:
#/sbin/lvreduce -L 300 /dev/vg00/lvol6 (-L is new size in MB)
(Keep in mind that this is just one suggestion, and there are likely inefficiencies. Please feel free to comment or include suggestions.)