VMWare and Xen Management with BixData

Want to support HowtoForge? Become a subscriber!
 
Submitted by Jed (Contact Author) (Forums) on Wed, 2006-11-01 15:26. :: VMware | Xen | Virtualization

VMWare and Xen Management with BixData

BixData is a system, application, and network monitoring tool which allows you to easily monitor nearly every aspect of your servers. The newly released version 2.6 is the only application that has the ability to control both Xen and VMWare virtual machines. You can control both VM Hosts (the computer that's running the VM software) and VM Guests (the virtual machines running on the hosts).

Installation

The first thing we need to do is install the BixServer onto one of our boxes. I'll be installing this on a Linux box but I could have easily put it on an OS X, FreeBSD or Windows machine. In this case the machine I'm using as the BixServer isn't running any VM software, it'll just be used to watch some that do.

wget http://www.bixdata.com/files/BixServer-2.6-linux-1-DB.tar.gz
tar -zxvf BixServer-2.6-linux-1-DB.tar.gz
cd bixdata
nohup ./runserver.sh >out &

Now I'll install BixAgent on two boxes, one is running Xen and the other VMWare.

wget www.bixdata.com/files/BixAgent-2.6-linux-1.tar.gz
tar -zxvf BixAgent-2.6-linux-1.tar.gz
cd bixdata/bixagent

Edit your bixdata/bixagent/data/xml/xen_cfg.xml and vmware_cfg.xml files and make sure they include the paths to your VM guest files. Xen requires us to run as root (If you're not running Xen then you can be non-root).

sudo su nohup ./bixagent >out &

There is some data that I want from the VM Guests that I can only get from a running BixAgent, so I'm going to install BixAgent on the VM Guests as well.

wget www.bixdata.com/files/BixAgent-2.6-linux-1.tar.gz
tar -zxvf BixAgent-2.6-linux-1.tar.gz
cd bixdata/bixagent
nohup ./bixagent >out &

So now we have BixServer running on a linux box. BixAgent running on the machines that are hosting the VM's and BixAgent running inside the actual VM's

Manipulating VMs

BixDesktop is the UI for BixData. It connects to BixServers or BixAgents to monitor and control them. So now we should install and startup it up.

wget www.bixdata.com/files/BixDesktop-2.6-linux-1.tar.gz
tar -zxvf BixDesktop-2.6-linux-1.tar.gz
cd bixdata ./rundesktop.sh

The first thing I'll do is connect to my BixServer.


Connecting Screen

Once connected we see the situation room. The situation room is where I can get a quick overview of all the machines my BixServer is watching. They can be BixAgents or any other machine (web servers, etc). I'll add the two VM host machines we're using, and the four VM guests. To add a host, just click the + in the title bar of the 'Machines' list.


Situation Room with VMs added

 

Now I'll tag these machines as “VMTest” so I can do things to all of them later on. Just click the + by User on the left to make a tag, then highlight some VM hosts and right click and tag them. The icons next to the machine show what tags they have. Smart tags will automatically be loaded if they are BixAgent machines. In this case we can see that the agent has detected that they are VMs (this can take a few minutes).


Tagging the VMs

 

Now that my BixServer is set up, I'll check out my VMs in the virtualization view. The left hand side shows my VM Hosts, the right side the VM Guests of any hosts I have selected. This allows me to do things like pause or stop many VM Guests at the same time with one click. I can even select guests running on Xen and VMWare at the same time and manipulate them.


Virtualization View


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by jcinacio (registered user) on Sat, 2007-08-11 22:30.

instead of the starting bixagent manually, i use this startup script in /etc/init.d/bixagent.

don't forget to run (as root): chmod +x /etc/init.d/bixagent && update-rc.d bixagent defaults

--SNIP-- 

#!/bin/sh

BIXAGENT_PATH="/usr/local/bixdata/bixagent"

. /lib/lsb/init-functions

case "$1" in
start)
        log_action_begin_msg "Starting bixdata agent"
        start-stop-daemon --chdir "$BIXAGENT_PATH" --exec bixagent --background --start
        log_action_end_msg $?
        ;;
stop)
        log_action_begin_msg "Stopping bixdata agent"
        start-stop-daemon --chdir "$BIXAGENT_PATH" --exec bixagent --stop
        log_action_end_msg $?
        ;;
restart)
        log_action_begin_msg "Restarting bixdata agent"
        start-stop-daemon --chdir "$BIXAGENT_PATH" --exec bixagent --stop 2>&1 >/dev/null
        sleep 3
        start-stop-daemon --chdir "$BIXAGENT_PATH" --exec bixagent --background --start
        log_action_end_msg $?
        ;;
*)
        echo "Usage: /etc/init.d/bixagent {start|stop|restart}"
        exit 1
        ;;
esac

exit 0