OPERATING DEFINITELY NOT A CLOUD

Definitely Not a Cloud

SYSPREP | DNC | NOBUDGET

Requirements

setup ClusterIt and check that it works. here’s a few hints.

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"

Create a new disk resource for guest template

full-blown new thin LV

TBD

Create a new disk resource for guest system

new snapshot based on template’s LV

check what templates are available (empty origin)

lvs

e.g.

tpl=debian11jan2023

check what DRBD minors are available

grep minor /etc/drbd.d/*.res | sort -V -k4

e.g.

minor=1030

[optional] eventually tune the DRBD resource name

name=ltcpowa

create a new guest

dnc-new-resource.bash $tpl $minor $name

Create a new guest system

[optional] eventually tune the system hostname from the start

name=ltcpowa

dnc-newguest-debian.bash $minor $name

Ready to go

check that the new guest is up and running

dnc-running-guest.bash $name

reach it remotely

ssh pmr.angrycow.ru -l root -p <PORT MAPPED AGAINST MINOR>

Additional notes

scripting — 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

HOME | GUIDES | LECTURES | LAB | SMTP HEALTH | HTML5 | CONTACT
Copyright © 2024 Pierre-Philipp Braun