Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: NodeBalancer script
PostPosted: Thu Mar 01, 2012 7:08 pm 
Offline
Junior Member

Joined: Mon Apr 18, 2011 1:54 pm
Posts: 45
Website: http://www.rassoc.com/gregr/weblog
I wrote this script a while back, and just came back around to putting it online so other folks could use it.

My most common task using the node balancers is temporarily enabling/disabling nodes; e.g. pull server 1 completely out of rotation, on all ports, while I'm doing maintenance.

Suppose you have 2 servers (called server1 and server2 in the Linode Manager) as members of a NodeBalancer, and each of them is listening on ports 80 and 443. When you want to do maintenance on server1, it's quite a lot of clicks in the Linode Manager to accomplish this.

So using this tool, you can do

Code:
loadbalancer server1 reject


This will take server1 completely out of rotation in the NodeBalancer, on all ports it is listening on. To bring it back online, use

Code:
loadbalancer server1 accept


Which will bring it back.

The code is at https://github.com/greinacker/linode_loadbalancer - feel free to contribute if you want to add anything!


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group