1753651 Members
6102 Online
108798 Solutions
New Discussion юеВ

Re: Extending Swap Space

 
SOLVED
Go to solution
Manix
Honored Contributor

Re: Extending Swap Space

You have configured secondary swap at low priority for non vg00 secondary swap which is not a very good idea.

Edit /etc/fstab and add the entry for each of them like this.

/dev/vg??/lv?? ... swap pri=1 0 0

This will enable swap interleaving as primary swap is already set to the default priority of 1.

(lowest number such as 0 gets used first, equal priorities are assigned in round-robin manner).

Further you have 32 Gigs of "pseudo swap" so it means your RAM size should be 50 Gigs which is good , you need to configure swap space at least equal to physical memory.

Check " dmesg | grep -i physical" to check RAM size and make sure you have equal amount of swap.

Look right now 8 Gigs of swap is reserved by some database application i guess.

You have 43 Gigs of free space in vg01 , please go ahead and good amount of swap to make it equal to RAM size ( or as much as you can, i think you need 42 Gigs..- )

Thanks
Manix

HP-UX been always lovable - Mani Kalra
Kavita Poonia
Regular Advisor

Re: Extending Swap Space

>> You can not extend swap lv on a fly , yes lvol can be extended but "swapon -a " wont see it , you do need contagious extents to extend that lvol & reboot is needed as well.



Secondary device swap in your case can be extended on same disk or new disk online with lvextend & swapon -a command. No reboot is required for swapon -a. Then its not necessary for secondary device swap to be contiguous but primary swap has to be.

Thanks & regards,
Kavita
Manix
Honored Contributor

Re: Extending Swap Space

>>>>> You can not extend swap lv on a fly , yes lvol can be extended but "swapon -a " wont see it , you do need contagious extents to extend that lvol & reboot is needed as well.

>>you do need contagious extents to extend ..>>that<< lvol

Hello Kavita

Thanks for checking in but these comments were only for "primary swap" that can`t be extended on fly and needs contagious extents ( if possible ..with certain work around )+ reboot.

Not for secondary do check the same -- ))

Thanks
Manix
HP-UX been always lovable - Mani Kalra
Kavita Poonia
Regular Advisor

Re: Extending Swap Space

Sorry my mistake....Manix is correct....I thought you need to create new sec. device swap which is online but for extending existing device swap you need to do swap off & extend it which is offline activity.

Thanks & regards,
Kavita
Vipin K Gupta
Occasional Advisor

Re: Extending Swap Space

Hi,

I just need to extend swap to 32 GB.

I can create a new swap or I can extend the existing secondary swap.

I got confused.

Conclusion - We can extend the existing secondary swap online right???

Thanks
Vipin
Manix
Honored Contributor

Re: Extending Swap Space

Better create new swap devices as per requirement & don`t get confused !!

Secondary can be extended ( needs reboot after that ) and we need to check what option you used while creating it ( -c y ) & do the things accordingly.

As we already discussed ,create new swap devices .

Thanks
Manix

HP-UX been always lovable - Mani Kalra
223848
Frequent Advisor

Re: Extending Swap Space

Hi Manix,
I have one doubt,
If i created a secondary swap without -C y option, can i extend the swap with lvextend.

What i understood is.
If i created the secondary swap without -C y option, then i have to do swapoff on that LV.
Then i have to extend the LV

Then i have to do swapon on that LV.

Is my undestanding is ryt?
Manix
Honored Contributor

Re: Extending Swap Space

Hello Laiju !

I am not able to find any HP doc ,supporting that secondary swap can be non - contagious.

But 'swapoff' is not a native in built command & there is patch for 11.31 only (AFAIK).read the link below.

https://h20392.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=SwapoffEn

I would still prefer to keep add a new device for -C y option .

Thanks
Manix


HP-UX been always lovable - Mani Kalra
223848
Frequent Advisor

Re: Extending Swap Space

Thank you Manix