- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- I need to squeeze out some didk space
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
Forums
Discussions
Discussions
Discussions
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
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
08-12-2005 03:20 AM
08-12-2005 03:20 AM
I have a bunch of free space in /opt that is also in vg00.
There are process running using /opt so I have to play some games to get some down time.
Here is my thoughts how I can fix this problem using my skill level.
First use "shutdown 0" to get it into single user mode.
mount /usr so I can get the commands I need.
copy /opt to another location.
Drop and recreate the /opt partition makeing it smaller.
Then copy /opt back to this new location.
Then bring the system back up.
Then extend the size of of /usr.
Woops! I forgot I wont have "sam' will I?
What are the commands I would use to drop /opt and recreate it?
I should learn that.
Can you guide me with this?
Marty
Using HP-UX 11.0 here.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:27 AM
08-12-2005 03:27 AM
Re: I need to squeeze out some didk space
That's a risky approach, I really don't know if it will work. An easier and clean solution would be to make a ignite tape_recovery including all vg00. Then you may boot from tape and resize filesystems as you want:
#make_tape_recovery -v -I -x inc_entire=vg00
The boot from this tape, reboot the server and interrupt the boot on the 10 seconds messages, search for bootable devices, select the tape drive and follow instructions :)
Another alternative would be to do it on-line, but this is possible only if you have "On-Line JFS" installed. You may check if you have it by:
root@porsx011:/# swlist -l product|grep -i online
OnlineJFS B.11.11 Online features of the VxFS File System
Enjoy :)
Pedro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:30 AM
08-12-2005 03:30 AM
Re: I need to squeeze out some didk space
Yes I would backup /opt to tape with tar.
To remove and recreate your /opt you would: -
unmount /opt
lvreduce -L newsize /dev/vg00/lvol4
This will reduce the logical volume to "newsize". No need to remove and recreate since you are recreating the filesystem anyway.
Then newfs -Fvxfs /dev/vg00/rlvol4
Then mount the filesystem.
Then restore your tape.
You can then unmount /usr, then use vgextend and extendfs to grow /usr.
However I'd seriously consider investing on OnlineJFS if you don't have it already, saves a lot of headaches!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:30 AM
08-12-2005 03:30 AM
Re: I need to squeeze out some didk space
You can use SAM in single user mode. Just do a "mount -a" when it comes up. Then umount /opt. Shrink /opt, then umount and grow /usr. You won't have SAM available but all you have to do is lvextend and extendfs. Then come back up.
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:32 AM
08-12-2005 03:32 AM
Re: I need to squeeze out some didk space
I do not have JFS.
Ignite tape should work. I haven't done a boot from Ignite. It may be goot time to learn. I have been doing the Make_Tape_recover tapes for quite a while.
Thanks,
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:44 AM
08-12-2005 03:44 AM
Re: I need to squeeze out some didk space
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 03:57 AM
08-12-2005 03:57 AM
Re: I need to squeeze out some didk space
fsadm -F vxfs -b 1000M /opt
is the command
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:01 AM
08-12-2005 04:01 AM
Re: I need to squeeze out some didk space
Mel didnt mention that before extending filesystem with fsadm you must extend lvol:
lvextend -L 1000 /dev/vg##/lvol##
Enjoy :)
Pedro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:05 AM
08-12-2005 04:05 AM
Re: I need to squeeze out some didk space
We are talking about reducing the filesystem size not extending it.
Actually after the fsadm command, one needs to shrink the size of the logical volume with lvreduce command.
But again, reducing filesystem and logical volume sizes are very risky at best.
My advice: have a known-good backup before committing to any of this.
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:07 AM
08-12-2005 04:07 AM
Re: I need to squeeze out some didk space
Mel, yes you are right, but Marty also wants to extend /usr :)
Enjoy :)
Pedro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:20 AM
08-12-2005 04:20 AM
Re: I need to squeeze out some didk space
Entending /usr is not a problem.
I can do that in "sam" any time. I have done that already. I just need some space.
It is taking space back from /opt that I was not sure about.
When I said I did not have OnlineJFS I may have been mistaking.
As you see I do have it.
B3929BA B.11.00 HP OnLineJFS (Advanced VxFS)
PHKL_22393 1.0 VxFS 31 OnlineJFS cumulative patch
PHKL_24201 1.0 JFS;stickybit;quota access;vx_maxlink tunabl
I also have the "fsadm" command.
Some time I use thing I do not know have.
I know reducing space is always risky.
And I preach Backup!, Backup! Backup.
I keep 4 online copies of the out production database and put it on tape too.
Wait, stop preaching Marty.
So to do this reduce thing.
After the backup, use the fsadm command and then restore the /opt backup.
Since I have JFS do I still have to still go down to single user mode?
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:29 AM
08-12-2005 04:29 AM
Solutionagaing with the example for from 2G to 1G
fsadm -F vxfs -b 1000M /opt
(completes successfully)
lvreduce -L 1000 /dev/vg00/lvol5
if this completes successfully as well, you should be good to go with extending /usr. If not, well, bring out the backup tapes, recreate lvol5, then newfs, then mount /opt, then restore from tape... worst case scenario.
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 04:32 AM
08-12-2005 04:32 AM
Re: I need to squeeze out some didk space
You have On-line JFS so it's much easier!
1ºHave a good backup, just-in-case :)
2ºfsadm -F vxfs -b new_size_optM /opt
3ºlvreduce -L new_size_opt /dev/vg00/lvol##
4ºlvextend -L new_size_usr /dev/vg00/lvol##
5ºfsadm -F vxfs -b new_size_usr /usr
That's all, don't forget the "M" after the size on fsadm!
Enjoy :)
Pedro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 05:27 AM
08-12-2005 05:27 AM
Re: I need to squeeze out some didk space
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-12-2005 06:24 AM
08-12-2005 06:24 AM
Re: I need to squeeze out some didk space
I understand the risk in changing any thing to do with the OS and FS so I will have a double backup and make see what I can do.
Thanks again for your help.
Marty