# HG changeset patch # User eb # Date 1190924878 -10800 # Node ID d6f7c53b085d2a05a91c6e43512735276d074af5 # Parent b6dc3480caae8d5bd5540137b3d56eb20535d903 several changes diff -r b6dc3480caae -r d6f7c53b085d config-example2.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/config-example2.py Thu Sep 27 23:27:58 2007 +0300 @@ -0,0 +1,97 @@ + +node1='debian' +node2='mirror' +i_am=node1 + +ip_address = { + node1: '10.0.1.19', + node2: '10.0.1.20', +} + +node1_ip=ip_address[node1] +node2_ip=ip_address[node2] + +domains=[ 'gw', 'igw', 'dns', 'vpn', 'apt' 'proxy', 'pgw', 'ldap', 'mail', 'uucp', 'samba', 'dozor', 'vvidd', ] + +domain_home = { + node1 : ['dozor', 'dns', 'gw', 'igw', 'pgw', 'ldap', 'mail', 'proxy', 'vpn', 'uucp', 'vvidd', 'apt'], + node2 : ['samba'], + } + +kernel = "/boot/vmlinuz-2.6.18-4-xen-686" +ramdisk = "/boot/initrd.img-2.6.18-4-xen-686-domU" + +mem_table={ + 'dozor' :256, + 'dns' :64, + 'gw' :64, + 'igw' :128, + 'pgw' :64, + 'ldap' :64, + 'mail' :256, + 'proxy' :256, + 'samba' :512, + 'vpn' :192, + 'uucp' :128, + 'vvidd' :64, + 'apt' :128, +} + +lvm_vg_name="TURBO" +disk_table={ + 'gw' : ['drbd1'], + 'igw' : ['drbd2'], + 'dns' : ['drbd3'], + 'vpn' : ['drbd4'], + 'apt' : ['drbd5'], + 'proxy' : ['drbd6'], + 'pgw' : ['drbd7'], + 'ldap' : ['drbd8'], + 'mail' : ['drbd10','drbd12:maildir'], + 'samba' : [ + 'drbd18', + 'drbd13:samba-home', + 'drbd14:samba-nbumail', + 'drbd15:samba-arm3', + 'drbd16:samba-boxes', + 'drbd17:samba-profiles' + ], + 'dozor' : ['drbd19'], + 'vvidd' : ['drbd20'], +} + +bridges=['tagged0', 'xenbr1', 'xenbr256', 'xenbr257', 'xenbr3', 'xenbr4', 'xenbr501'] +vlans= ['tagged', 1, 256, 257, 3, 4, 501 ] +management_vlan=1 +trunk='eth0' +management_ip=ip_address[i_am] +management_gw='10.0.1.253' + +vbridges_table={ + 'dozor' : ['xenbr3'], + 'dns' : ['xenbr3'], + 'gw' : ['xenbr501', 'xenbr256', 'xenbr257'], + 'igw' : ['tagged0','xenbr3'], + 'pgw' : ['xenbr3','xenbr501'], + 'ldap' : ['xenbr3'], + 'mail' : ['xenbr3'], + 'proxy' : ['xenbr3'], + 'samba' : ['tagged0', 'xenbr3'], + 'vpn' : ['xenbr3'], + 'vvidd' : ['xenbr3'], + 'apt' : ['xenbr3'], + 'uucp' : ['xenbr3'], +} + +# FOR INSTALLATION ONLY + +ip_network="10.0.3" +domain_name="eb.co.ua" +ip_nameserver="10.0.3.4" +ip_gateway="10.0.3.3" + +debian_release="etch" +debian_mirror="http://debian.org.ua/debian" +apt_get_install="less tcpdump libpam-ldap libnss-ldap snmpd libc6-xen openssh-server" + + diff -r b6dc3480caae -r d6f7c53b085d default-xen-drbd --- a/default-xen-drbd Thu Sep 27 18:56:29 2007 +0300 +++ b/default-xen-drbd Thu Sep 27 23:27:58 2007 +0300 @@ -1,4 +1,5 @@ XEN_DRBD_PATH='/usr/local/bin' TOPOLOGY_NAME='eb' START_ACTION=nothing #migrate-and-start-all +STOP_ACTION=migrate-all-out diff -r b6dc3480caae -r d6f7c53b085d init.d-xen-drbd --- a/init.d-xen-drbd Thu Sep 27 18:56:29 2007 +0300 +++ b/init.d-xen-drbd Thu Sep 27 23:27:58 2007 +0300 @@ -3,6 +3,7 @@ XEN_DRBD_PATH='/usr/bin' TOPOLOGY_NAME='xen-drbd' START_ACTION='nothing' +STOP_ACTION='nothing' [ -e /etc/default/xen-drbd ] && . /etc/default/xen-drbd case $1 in @@ -16,7 +17,7 @@ fi ;; stop) - $XEN_DRBD_PATH/xen-drbd.py migrate-all-out + $XEN_DRBD_PATH/xen-drbd.py $STOP_ACTION ;; *) echo $0 'start|stop' diff -r b6dc3480caae -r d6f7c53b085d xen-drbd.py --- a/xen-drbd.py Thu Sep 27 18:56:29 2007 +0300 +++ b/xen-drbd.py Thu Sep 27 23:27:58 2007 +0300 @@ -5,6 +5,7 @@ import sys,os from commands import mkarg + sys.path.append('/etc/xen') try: exec 'from %s import *' % (network)