OpenVZ Forum


Home » General » Support » how to switch off automatic suspend/resume?
how to switch off automatic suspend/resume? [message #48787] Sat, 24 November 2012 06:22 Go to next message
Wireless is currently offline  Wireless
Messages: 9
Registered: August 2010
Junior Member
When HN reboots, it suspends all CTs, and after reboot complete - resumes them back up.
Is any way to switch off this feature?
It takes many minutes to suspend a database CT, and then many minutes to resume it back.
It is *way* faster to just shutdown database normally and then start it up (withing 10-15 seconds or so).

If it's not possible to do on per-container base, I would disable this feature globally.

Any way to accomplish this?
Re: how to switch off automatic suspend/resume? [message #48802 is a reply to message #48787] Wed, 05 December 2012 16:40 Go to previous messageGo to next message
mperkel is currently offline  mperkel
Messages: 253
Registered: December 2006
Senior Member
I agree. I never want suspend under any conditions. What I'm seeing is the shutdown hanging the system while trying to suspend.

Re: how to switch off automatic suspend/resume? [message #48804 is a reply to message #48802] Wed, 05 December 2012 17:01 Go to previous messageGo to next message
Wireless is currently offline  Wireless
Messages: 9
Registered: August 2010
Junior Member
I just modified /etc/init.d/vz to switch off suspending for a database container.

In the stop_ves() function, in the inner most loop
for stage in $stages; do
  for i in 0 1 2; do
    for veid in $velist; do


added
if [ "$stage" = "suspend" -a "$veid" == "908" ]; then
   echo "Database container $veid will be just stopped"
   continue
fi


So now CTID 908 doesn't get suspended - just stopped.

[Updated on: Wed, 05 December 2012 17:11]

Report message to a moderator

Re: how to switch off automatic suspend/resume? [message #48805 is a reply to message #48804] Wed, 05 December 2012 17:07 Go to previous messageGo to next message
mperkel is currently offline  mperkel
Messages: 253
Registered: December 2006
Senior Member
What about just skipping suspend changing the line to

stages="stop"


Re: how to switch off automatic suspend/resume? [message #48806 is a reply to message #48805] Wed, 05 December 2012 17:12 Go to previous message
Wireless is currently offline  Wireless
Messages: 9
Registered: August 2010
Junior Member
I guess it should work... i have no problems with suspending on other containers except database one. So i would keep suspending for other stuff for now.
Previous Topic: vzctl suspend problem
Next Topic: How to make broadcasting work in a VE
Goto Forum:
  


Current Time: Tue Aug 27 13:22:33 GMT 2024

Total time taken to generate the page: 0.03487 seconds