[cloudstack] branch debian9-systemvmtemplate updated: fixes

2017-12-11 Thread rohit
This is an automated email from the ASF dual-hosted git repository.

rohit pushed a commit to branch debian9-systemvmtemplate
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/debian9-systemvmtemplate by 
this push:
 new c666485  fixes
c666485 is described below

commit c666485dfdd655103608a9fb6e04d67737518506
Author: Rohit Yadav 
AuthorDate: Tue Dec 12 10:24:39 2017 +0530

fixes

Signed-off-by: Rohit Yadav 
---
 .travis.yml| 11 ++---
 .../etc/systemd/system/cloud-postinit.service  |  2 +-
 systemvm/debian/opt/cloud/bin/cs/CsApp.py  |  2 +-
 systemvm/debian/opt/cloud/bin/passwd_server| 26 
 systemvm/debian/opt/cloud/bin/passwd_server_ip | 29 -
 systemvm/debian/opt/cloud/bin/update_config.py | 14 +++
 systemvm/debian/opt/cloud/bin/vpc_passwd_server| 32 ---
 .../opt/cloud/templates/keepalived.conf.templ  |  4 +-
 .../definitions/systemvmtemplate/apt_upgrade.sh| 13 ++
 .../definitions/systemvmtemplate/configure_grub.sh |  2 +-
 .../definitions/systemvmtemplate/finalize.sh   |  9 
 tools/marvin/marvin/config/test_data.py| 48 +-
 tools/marvin/marvin/lib/common.py  | 47 +
 13 files changed, 79 insertions(+), 160 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index a206cbe..b4749c0 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -115,8 +115,7 @@ env:
  component/test_acl_sharednetwork_deployVM-impersonation
  component/test_affinity_groups_projects
  component/test_cpu_domain_limits
- component/test_cpu_limits
- component/test_volumes"
+ component/test_cpu_limits"
 
 - TESTS="component/test_cpu_max_limits
  component/test_acl_isolatednetwork
@@ -144,10 +143,12 @@ env:
  component/test_snapshots
  component/test_stopped_vm"
 
-- TESTS="component/test_resource_limits
- component/test_tags
+- TESTS="component/test_resource_limits"
+
+- TESTS="component/test_tags
  component/test_templates
- component/test_update_vm"
+ component/test_update_vm
+ component/test_volumes"
 
 - TESTS="component/test_vpc
  component/test_vpc_network
diff --git a/systemvm/debian/etc/systemd/system/cloud-postinit.service 
b/systemvm/debian/etc/systemd/system/cloud-postinit.service
index 83f0636..04f71a3 100644
--- a/systemvm/debian/etc/systemd/system/cloud-postinit.service
+++ b/systemvm/debian/etc/systemd/system/cloud-postinit.service
@@ -11,4 +11,4 @@ WantedBy=multi-user.target
 Type=oneshot
 ExecStart=/opt/cloud/bin/setup/postinit.sh
 RemainAfterExit=true
-TimeoutStartSec=1min
+TimeoutStartSec=5min
diff --git a/systemvm/debian/opt/cloud/bin/cs/CsApp.py 
b/systemvm/debian/opt/cloud/bin/cs/CsApp.py
index 2085088..031ac05 100755
--- a/systemvm/debian/opt/cloud/bin/cs/CsApp.py
+++ b/systemvm/debian/opt/cloud/bin/cs/CsApp.py
@@ -66,7 +66,7 @@ class CsApache(CsApp):
 
 class CsPasswdSvc():
 """
-  nohup bash /opt/cloud/bin/vpc_passwd_server $ip >/dev/null 2>&1 &
+  CloudStack VR password server
 """
 
 def __init__(self, ip):
diff --git a/systemvm/debian/opt/cloud/bin/passwd_server 
b/systemvm/debian/opt/cloud/bin/passwd_server
deleted file mode 100755
index 295e720..000
--- a/systemvm/debian/opt/cloud/bin/passwd_server
+++ /dev/null
@@ -1,26 +0,0 @@
-#!/bin/bash
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-#we have intentionally split the ip gathering command into two.
-#This was done to avoid getting a SIGPIPE during certain load conditions.
-ipInfo=$(ip addr show dev eth0 | grep inet | grep eth0 )
-ips=$(echo "$ipInfo" | awk '{print $2}' ); echo $ips
-for ip in $ips; do
-   addr=$(echo $ip | awk -F'/' '{print $1}')
-   /opt/cloud/bin/passwd_server_ip $addr >> /var/log/cloud.log 2>&1 &
-done;
diff --git a/systemvm/debian/opt/cloud/bin/passwd_server_ip 
b/systemvm/debian/opt/cloud/bin/passwd_server_ip
deleted file mode 100755
index ce21b53..000
--- a/systemvm/debian/opt/cloud/bin/passwd

[cloudstack] branch debian9-systemvmtemplate updated: fixes

2017-11-25 Thread bhaisaab
This is an automated email from the ASF dual-hosted git repository.

bhaisaab pushed a commit to branch debian9-systemvmtemplate
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/debian9-systemvmtemplate by 
this push:
 new e0fa409  fixes
e0fa409 is described below

commit e0fa4091513f8cedcc8e76c44a1933db0fb6975f
Author: Rohit Yadav 
AuthorDate: Sun Nov 26 12:28:45 2017 +0530

fixes

Signed-off-by: Rohit Yadav 
---
 .../debian/config/opt/cloud/bin/setup/common.sh| 63 ++
 .../debian/config/opt/cloud/bin/setup/router.sh|  9 ++--
 .../debian/config/opt/cloud/bin/setup/vpcrouter.sh |  5 ++
 .../definitions/systemvmtemplate/zerodisk.sh   |  2 +-
 4 files changed, 73 insertions(+), 6 deletions(-)

diff --git a/systemvm/patches/debian/config/opt/cloud/bin/setup/common.sh 
b/systemvm/patches/debian/config/opt/cloud/bin/setup/common.sh
index 2165628..3b766ef 100755
--- a/systemvm/patches/debian/config/opt/cloud/bin/setup/common.sh
+++ b/systemvm/patches/debian/config/opt/cloud/bin/setup/common.sh
@@ -612,6 +612,69 @@ routing_svcs() {
fi
 }
 
+setup_redundant_router() {
+rrouter_bin_path="/ramdisk/rrouter"
+rrouter_log="/ramdisk/rrouter/keepalived.log"
+rrouter_bin_path_str="\/ramdisk\/rrouter"
+rrouter_log_str="\/ramdisk\/rrouter\/keepalived.log"
+mkdir -p /ramdisk
+mount tmpfs /ramdisk -t tmpfs
+mkdir -p /ramdisk/rrouter
+ip route delete default
+cp /root/redundant_router/keepalived.conf.templ 
/etc/keepalived/keepalived.conf
+cp /root/redundant_router/conntrackd.conf.templ 
/etc/conntrackd/conntrackd.conf
+cp /root/redundant_router/enable_pubip.sh.templ 
$rrouter_bin_path/enable_pubip.sh
+cp /root/redundant_router/master.sh.templ $rrouter_bin_path/master.sh
+cp /root/redundant_router/backup.sh.templ $rrouter_bin_path/backup.sh
+cp /root/redundant_router/fault.sh.templ $rrouter_bin_path/fault.sh
+cp /root/redundant_router/primary-backup.sh.templ 
$rrouter_bin_path/primary-backup.sh
+cp /root/redundant_router/heartbeat.sh.templ $rrouter_bin_path/heartbeat.sh
+cp /root/redundant_router/check_heartbeat.sh.templ 
$rrouter_bin_path/check_heartbeat.sh
+cp /root/redundant_router/arping_gateways.sh.templ 
$rrouter_bin_path/arping_gateways.sh
+cp /root/redundant_router/check_bumpup.sh $rrouter_bin_path/
+cp /root/redundant_router/disable_pubip.sh $rrouter_bin_path/
+cp /root/redundant_router/checkrouter.sh.templ 
/opt/cloud/bin/checkrouter.sh
+cp /root/redundant_router/services.sh $rrouter_bin_path/
+sed -i "s/\[ROUTER_ID\]/$NAME/g" /etc/keepalived/keepalived.conf
+sed -i "s/\[ROUTER_IP\]/$GUEST_GW\/$GUEST_CIDR_SIZE/g" 
/etc/keepalived/keepalived.conf
+sed -i "s/\[BOARDCAST\]/$GUEST_BRD/g" /etc/keepalived/keepalived.conf
+sed -i "s/\[PRIORITY\]/$ROUTER_PR/g" /etc/keepalived/keepalived.conf
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
/etc/keepalived/keepalived.conf
+sed -i "s/\[DELTA\]/2/g" /etc/keepalived/keepalived.conf
+sed -i "s/\[LINK_IF\]/eth0/g" /etc/conntrackd/conntrackd.conf
+sed -i "s/\[LINK_IP\]/$ETH0_IP/g" /etc/conntrackd/conntrackd.conf
+sed -i "s/\[IGNORE_IP1\]/$GUEST_GW/g" /etc/conntrackd/conntrackd.conf
+sed -i "s/\[IGNORE_IP2\]/$ETH0_IP/g" /etc/conntrackd/conntrackd.conf
+sed -i "s/\[IGNORE_IP3\]/$ETH1_IP/g" /etc/conntrackd/conntrackd.conf
+sed -i "s/\[ETH2IP\]/$ETH2_IP/g" $rrouter_bin_path/enable_pubip.sh
+sed -i "s/\[ETH2MASK\]/$ETH2_MASK/g" $rrouter_bin_path/enable_pubip.sh
+sed -i "s/\[GATEWAY\]/$GW/g" $rrouter_bin_path/enable_pubip.sh
+sed -i "s/\[GATEWAY\]/$GW/g" $rrouter_bin_path/master.sh
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
$rrouter_bin_path/master.sh
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
$rrouter_bin_path/backup.sh
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
$rrouter_bin_path/fault.sh
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
$rrouter_bin_path/heartbeat.sh
+sed -i "s/\[RROUTER_BIN_PATH\]/$rrouter_bin_path_str/g" 
$rrouter_bin_path/check_heartbeat.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" $rrouter_bin_path/master.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" $rrouter_bin_path/backup.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" $rrouter_bin_path/fault.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" 
$rrouter_bin_path/primary-backup.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" 
$rrouter_bin_path/check_heartbeat.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" 
$rrouter_bin_path/arping_gateways.sh
+sed -i "s/\[RROUTER_LOG\]/$rrouter_log_str/g" /opt/cloud/bin/checkrouter.sh
+if [ $ADVERT_INT ]
+then
+sed -i "s/advert_int 1/advert_int $ADVERT_INT/g" 
/etc/keepalived/keepalived.conf
+fi
+chmod a+x $rrouter_bin_path/*.sh
+sed -i "s/--exec\ \$DAEMON;/--exec\ \$DA