I tried to change the backend server to maintenance mode. Once one, the top of 
the page show some text about how to use the "poundctl" with the successful 
message. But it is actually an error and the backend server's mode didn't get 
changed.

I found out that if the service contains space (not sure about other special 
characters), the call to "poundctl" will return error. Looking closer to the 
link to action page (hover mouse to the small icon that will change the mode), 
you will see the last parameter "service=" contains only the first part before 
the space (eg. Service name "Target host" will be shown as "service=Target".)

Incomplete service name leads to the "poundctl" can't find the service, so 
can't match the serverID to switch server's mode.

The fix is to modify the file /usr/local/zenloadbalancer/www/function.cgi
At line 260 and 262 (sub createmenuserversfarm) located the link to enable or 
disable maintenance mode. Just add double quote in href tag.

? Original
print "<a 
href=index.cgi?action=editfarm-maintenance&id=1-2&farmname=$name&id_server=$id_server&service=$sv
 title=\"Enable maintenance ............ >"

? Change to
print "<a href=\" 
index.cgi?action=editfarm-maintenance&id=1-2&farmname=$name&id_server=$id_server&service=$sv\"
 title=\"Enable maintenance ............ >

Hope this help who spent 4 hours wondering why the function is not working, 
like me :D

---------
Nathan

------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://pubads.g.doubleclick.net/gampad/clk?id=154624111&iu=/4140/ostg.clktrk
_______________________________________________
Zenloadbalancer-support mailing list
Zenloadbalancer-support@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/zenloadbalancer-support

Reply via email to