SETTING UP NOBUDGET

INTRO

Current status of NOBUDGET assumes the guests live as sparse files into /data/guests/GUESTNAME/. It can be done with NFS (as described here below as for the client), OCFS2 or GFS2.

DOM0 PREP

Ubuntu

apt install nfs-common

vi /etc/bashrc

PATH=/data/xen:$PATH

source /etc/bashrc

Slackware

ls -lF /etc/rc.d/rc.rpc
chmod +x /etc/rc.d/rc.rpc
/etc/rc.d/rc.rpc start
/etc/rc.d/rc.rpc status

vi /etc/profile

PATH=/data/xen:$PATH

source /etc/profile

NFS PREP

vi /etc/fstab

x.x.x.x:/data /data nfs defaults,auto 0 0
x.x.x.x:/data.images /data.images nfs defaults,auto 0 0

mkdir /data/ /data.images/
touch /data/NOT_MOUNTED /data.images/NOT_MOUNTED

mount /data/
mount /data.images/

and if the /data/xen/ repository is not already there

cd /data/
git clone https://github.com/pbraun9/xen.git
#git clone ssh://git@github.com/pbraun9/xen.git

MANAGEMENT NODE

Setting up ClusterIt

as user

check kernel options

dsh -e -g xen grep xen.gz /extlinux.conf
dsh -e -g xen grep vmlinuz /extlinux.conf

what guests are running over the farm?

dsh -e -g xen "xl li | sed '1,2d' | awk '{print $1}'"

what is the current load?

dsh -e -g xen "xentop -b -i1"

SSH CLOUD

DEPLOYING AND STARTING 10 GUESTS IN A ROW

from an hypervisor as root

cd /data/guests/
for n in `seq 1 10`; do
    deployguest.bash netbsd.DATE.tar.gz
    renameguest.bash netbsd vadim$n
    xl create vadim$n/vadim$n
done; unset n

from the mgmt node as user

update your remote connection settings,

grep dhcpd /var/log/syslog | tail
sudo vi /etc/hosts

...

vi ~/.ssh/config

Host vadim*
        Port 2222
        User root

make sure you have got the nobudget scripts available,

ll ~/bin/vadim*.ksh

to fix the hostnames with a for loop,

cd ~/bin/
for n in `seq 1 10`; do
    dsh -e -w vadim$n -s vadim.hostname.ksh vadim$n
done; unset n

and eventually install the monit agent too,

cd ~/bin/
vi vadim.monit.ksh #edit PASSWORD and MMONIT
for n in `seq 1 10`; do
    dsh -e -w vadim$n -s vadim.monit.ksh vadim$n
done; unset n

Nethence | Pub | Lab | Pbraun | SNE Russia | xhtml