- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Reduce a FS with fsadm
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
тАО03-12-2007 04:44 AM
тАО03-12-2007 04:44 AM
Now I am trying to reduce it with fsadm but always tells me that there is a block that is being used. I already tried to use fsadm on monouser mode but the system tells me that I have no license to operate the software (I am able to use it in multiuser mode).
How can I reduce the last block of the lvol for making the mirror to be right again in the same two disks as before?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 05:05 AM
тАО03-12-2007 05:05 AM
Re: Reduce a FS with fsadm
Try a defragmentation first.
# fsadm -F vxfs -d -D -e -E /filesystem
When the defrag completes, try reducing the filesystem
# fsadm -F vxfs -b
Note the appix "m".
lvreduce the lv.
As always, it is a very important to have a good backup of the filesystem before you try to reduce. At times, it may not just go very well.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 05:08 AM
тАО03-12-2007 05:08 AM
Re: Reduce a FS with fsadm
Normally this message means that You are trying the filesystem below what is currently IN USE in that filesystem. This often happens to me if I mix up the numbers.
Don't try to change the lvol size or mirroring config until You're done with the filesystem shrink.
There is another possible reason:
- Filesystem fragmentation:
fsadm -Fvxfs -de /mountpoint should correct the filesystem block allocation so that you can reduce the filesystem.
if you have vxfs version 4 or above, try to make it work in multiuser mode, this is easier to debug.
steps (just for verification)
let's assume 17GB current size, and 8GB in use
fsadm -Fvxfs -de /fs
fsadm -Fvxfs -b 8192M /fs
lvreduce -L 8192 /dev/vgNN/lvolXX
lvreduce -m 0 /dev/vgNN/lvolXX
# use PVGs to simplify the next step
pvmove -n /dev/vgNN/lvolXX /dev/dsk/wrong_disk /dev/dsk/wrong_disk /dev/dsk/right_disk
Then, ummm, redistribute, extend as wished
Regards,
Florian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 05:25 AM
тАО03-12-2007 05:25 AM
Re: Reduce a FS with fsadm
But the question now, I am trying to make the extend the lvol again, and it extends it always on the three first disks, and I have enough disk space for extending it on my two original disks. I use this command:
# lvextend -L 1300 /dev/vg00/lvol6
My PE size is 16 Mb, and my lvol actually has 976 Mb (61 PE in each of the two disks).
--- Physical volumes ---
PV Name /dev/dsk/c1t2d0
PV Status available
Total PE 4374
Free PE 3452
Autoswitch On
PV Name /dev/dsk/c1t0d0
PV Status available
Total PE 1085
Free PE 85
Autoswitch On
PV Name /dev/dsk/c2t2d0
PV Status available
Total PE 4374
Free PE 3452
Autoswitch On
PV Name /dev/dsk/c2t0d0
PV Status available
Total PE 1085
Free PE 85
Autoswitch On
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 05:31 AM
тАО03-12-2007 05:31 AM
SolutionIf you would like to extend the LV on specific disks, then you will need to specificy them in the lvextend command
# lvextend -L 1300 /dev/vg04/lvol6 /dev/dsk/cXtYdZ /dev/dsk/c..... /dev/dsk/c.....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 05:38 PM
тАО03-12-2007 05:38 PM
Re: Reduce a FS with fsadm
it looks like this in /etc/lvmtab
VG /dev/vgname
PVG ORIG_PVG
/dev/dsk/c1t2d0
/dev/dsk/c1t3d0
PVG MIRR_PVG
/dev/dsk/c2t8d0
/dev/dsk/c2t9d0
then
lvreduce -A n -m 0 /dev/vgname/lvolname
lvchange -A n -s g /dev/vgname/lvolname
lvextend -m 1 /dev/vgname/lvolname
and hp-ux will automatically distribute the mirrors accordingly, though it might be advisable to do this a bit more extensively. like, first split all mirrors, then pvmove so no PE on the MIRR_PVG disks are allocated, then lvchange, remirror.
After that you won't run into uneven mirrors ever again.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2007 08:36 PM
тАО03-12-2007 08:36 PM
Re: Reduce a FS with fsadm
The of making the pvg I┬┤ll have a look at it as soon as I have some more time, but is a good idea thou.
Thanks to all of you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-13-2007 07:50 AM
тАО03-13-2007 07:50 AM
Re: Reduce a FS with fsadm
I made a big typo: it's /etc/lvmpvg (manually created), not /etc/lvmtab (never to be edited)
Florian