You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ro...@apache.org on 2017/12/12 19:50:35 UTC
[cloudstack] branch debian9-systemvmtemplate updated (3018dc3 ->
1b5d90c)
This is an automated email from the ASF dual-hosted git repository.
rohit pushed a change to branch debian9-systemvmtemplate
in repository https://gitbox.apache.org/repos/asf/cloudstack.git.
from 3018dc3 systemvm fixes
new 4d74a22 fix volume usage test case
new 1b5d90c fixes
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
server/src/com/cloud/server/StatsCollector.java | 2 +-
systemvm/debian/etc/rc.local | 28 ----------------
.../etc/systemd/system/cloud-postinit.service | 2 +-
systemvm/debian/opt/cloud/bin/setup/common.sh | 3 +-
.../debian/opt/cloud/bin/setup/consoleproxy.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/elbvm.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/ilbvm.sh | 2 +-
.../debian/opt/cloud/bin/setup/patchsystemvm.sh | 4 +++
systemvm/debian/opt/cloud/bin/setup/postinit.sh | 39 +++++++++++++++++++---
systemvm/debian/opt/cloud/bin/setup/secstorage.sh | 2 +-
systemvm/debian/opt/cloud/bin/update_config.py | 7 ----
test/integration/smoke/test_usage.py | 22 +++---------
ui/l10n/en.js | 1 -
ui/scripts/system.js | 4 +--
ui/scripts/ui/dialog.js | 2 +-
ui/scripts/ui/widgets/multiEdit.js | 2 +-
17 files changed, 54 insertions(+), 72 deletions(-)
--
To stop receiving notification emails like this one, please contact
['"commits@cloudstack.apache.org" <co...@cloudstack.apache.org>'].
[cloudstack] 01/02: fix volume usage test case
Posted by ro...@apache.org.
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
commit 4d74a22b3925fc08861b1c2addc2cc98d25966ae
Author: Rohit Yadav <ro...@shapeblue.com>
AuthorDate: Tue Dec 12 20:52:24 2017 +0530
fix volume usage test case
Signed-off-by: Rohit Yadav <ro...@shapeblue.com>
---
server/src/com/cloud/server/StatsCollector.java | 2 +-
test/integration/smoke/test_usage.py | 22 ++++------------------
2 files changed, 5 insertions(+), 19 deletions(-)
diff --git a/server/src/com/cloud/server/StatsCollector.java b/server/src/com/cloud/server/StatsCollector.java
index 96b51f5..d32ed98 100644
--- a/server/src/com/cloud/server/StatsCollector.java
+++ b/server/src/com/cloud/server/StatsCollector.java
@@ -937,7 +937,7 @@ public class StatsCollector extends ManagerBase implements ComponentMethodInterc
}
public VolumeStats getVolumeStats(String volumeLocator) {
- if (_volumeStats.containsKey(volumeLocator)) {
+ if (volumeLocator != null && _volumeStats.containsKey(volumeLocator)) {
return _volumeStats.get(volumeLocator);
}
return null;
diff --git a/test/integration/smoke/test_usage.py b/test/integration/smoke/test_usage.py
index e6c6565..4419835 100644
--- a/test/integration/smoke/test_usage.py
+++ b/test/integration/smoke/test_usage.py
@@ -680,26 +680,12 @@ class TestVolumeUsage(cloudstackTestCase):
"Check VOLUME.DELETE in events table"
)
self.hypervisor = str(get_hypervisor_type(self.apiclient)).lower()
- if self.hypervisor == "vmware":
- self.testdata["coreos_volume"][
- "url"] = self.testdata["coreos_volume"]["urlvmware"]
- self.testdata["coreos_volume"]["format"] = "OVA"
- elif self.hypervisor == "xenserver":
- self.testdata["coreos_volume"][
- "url"] = self.testdata["coreos_volume"]["urlxen"]
- self.testdata["coreos_volume"]["format"] = "VHD"
- elif self.hypervisor == "kvm":
- self.testdata["coreos_volume"][
- "url"] = self.testdata["coreos_volume"]["urlkvm"]
- self.testdata["coreos_volume"]["format"] = "QCOW2"
- elif self.hypervisor == "hyperv":
- self.testdata["coreos_volume"][
- "url"] = self.testdata["coreos_volume"]["urlxen"]
- self.testdata["coreos_volume"]["format"] = "VHD"
-
+ volume_template = self.testdata["test_templates"][self.hypervisor]
+ volume_template["diskname"] = "Volume_tiny"
+ volume_template["format"] = volume_template["format"].upper()
volume_uploaded = Volume.upload(
self.apiclient,
- self.testdata["coreos_volume"],
+ volume_template,
self.zone.id,
account=self.account.name,
domainid=self.account.domainid)
--
To stop receiving notification emails like this one, please contact
"commits@cloudstack.apache.org" <co...@cloudstack.apache.org>.
[cloudstack] 02/02: fixes
Posted by ro...@apache.org.
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
commit 1b5d90cbf5a7432be2ce404491ba3d89d8d9b72e
Author: Rohit Yadav <ro...@shapeblue.com>
AuthorDate: Wed Dec 13 00:26:27 2017 +0530
fixes
Signed-off-by: Rohit Yadav <ro...@shapeblue.com>
---
systemvm/debian/etc/rc.local | 28 ----------------
.../etc/systemd/system/cloud-postinit.service | 2 +-
systemvm/debian/opt/cloud/bin/setup/common.sh | 3 +-
.../debian/opt/cloud/bin/setup/consoleproxy.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/elbvm.sh | 2 +-
systemvm/debian/opt/cloud/bin/setup/ilbvm.sh | 2 +-
.../debian/opt/cloud/bin/setup/patchsystemvm.sh | 4 +++
systemvm/debian/opt/cloud/bin/setup/postinit.sh | 39 +++++++++++++++++++---
systemvm/debian/opt/cloud/bin/setup/secstorage.sh | 2 +-
systemvm/debian/opt/cloud/bin/update_config.py | 7 ----
ui/l10n/en.js | 1 -
ui/scripts/system.js | 4 +--
ui/scripts/ui/dialog.js | 2 +-
ui/scripts/ui/widgets/multiEdit.js | 2 +-
15 files changed, 49 insertions(+), 53 deletions(-)
diff --git a/systemvm/debian/etc/rc.local b/systemvm/debian/etc/rc.local
index 94c6466..e419de0 100755
--- a/systemvm/debian/etc/rc.local
+++ b/systemvm/debian/etc/rc.local
@@ -16,32 +16,4 @@
# specific language governing permissions and limitations
# under the License.
-[ ! -f /var/cache/cloud/enabled_svcs ] && touch /var/cache/cloud/enabled_svcs
-for svc in $(cat /var/cache/cloud/enabled_svcs)
-do
- logger -t cloud "Starting $svc"
- systemctl enable --no-block --now $svc
-done
-[ ! -f /var/cache/cloud/disabled_svcs ] && touch /var/cache/cloud/disabled_svcs
-for svc in $(cat /var/cache/cloud/disabled_svcs)
-do
- logger -t cloud "Stopping $svc"
- systemctl disable --no-block --now $svc
-done
-
-# Restore the persistent iptables nat, rules and filters for IPv4 and IPv6 if they exist
-ipv4="/etc/iptables/rules.v4"
-if [ -e $ipv4 ]
-then
- iptables-restore < $ipv4
-fi
-
-ipv6="/etc/iptables/rules.v6"
-if [ -e $ipv6 ]
-then
- iptables-restore < $ipv6
-fi
-
-date > /var/cache/cloud/boot_up_done
-logger -t cloud "Boot up process done"
diff --git a/systemvm/debian/etc/systemd/system/cloud-postinit.service b/systemvm/debian/etc/systemd/system/cloud-postinit.service
index 04f71a3..c23516e 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=5min
+TimeoutStartSec=10min
diff --git a/systemvm/debian/opt/cloud/bin/setup/common.sh b/systemvm/debian/opt/cloud/bin/setup/common.sh
index f1f72f4..078cb58 100755
--- a/systemvm/debian/opt/cloud/bin/setup/common.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/common.sh
@@ -590,8 +590,7 @@ routing_svcs() {
systemctl disable --now portmap
systemctl enable apache2
systemctl enable haproxy
- systemctl enable ssh
- echo "ssh haproxy apache2" > /var/cache/cloud/enabled_svcs
+ echo "haproxy apache2" > /var/cache/cloud/enabled_svcs
echo "cloud nfs-common portmap" > /var/cache/cloud/disabled_svcs
if [ $RROUTER -eq 1 ]
then
diff --git a/systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh b/systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh
index a3b2797..225dc6f 100755
--- a/systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh
@@ -19,7 +19,7 @@
. /opt/cloud/bin/setup/common.sh
consoleproxy_svcs() {
- echo "cloud ssh" > /var/cache/cloud/enabled_svcs
+ echo "cloud" > /var/cache/cloud/enabled_svcs
echo "haproxy dnsmasq apache2 nfs-common portmap" > /var/cache/cloud/disabled_svcs
mkdir -p /var/log/cloud
}
diff --git a/systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh b/systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh
index 467bb56..9161aeb 100755
--- a/systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh
@@ -19,7 +19,7 @@
. /opt/cloud/bin/setup/common.sh
dhcpsrvr_svcs() {
- echo "ssh dnsmasq apache2" > /var/cache/cloud/enabled_svcs
+ echo "dnsmasq apache2" > /var/cache/cloud/enabled_svcs
echo "cloud nfs-common conntrackd keepalived haproxy portmap" > /var/cache/cloud/disabled_svcs
}
diff --git a/systemvm/debian/opt/cloud/bin/setup/elbvm.sh b/systemvm/debian/opt/cloud/bin/setup/elbvm.sh
index 600fb0d..ae16b4b 100755
--- a/systemvm/debian/opt/cloud/bin/setup/elbvm.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/elbvm.sh
@@ -19,7 +19,7 @@
. /opt/cloud/bin/setup/common.sh
elbvm_svcs() {
- echo "ssh haproxy" > /var/cache/cloud/enabled_svcs
+ echo "haproxy" > /var/cache/cloud/enabled_svcs
echo "cloud dnsmasq conntrackd keepalived apache2 nfs-common portmap" > /var/cache/cloud/disabled_svcs
}
diff --git a/systemvm/debian/opt/cloud/bin/setup/ilbvm.sh b/systemvm/debian/opt/cloud/bin/setup/ilbvm.sh
index 58a711c..ac801b2 100755
--- a/systemvm/debian/opt/cloud/bin/setup/ilbvm.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/ilbvm.sh
@@ -19,7 +19,7 @@
. /opt/cloud/bin/setup/common.sh
ilbvm_svcs() {
- echo "ssh haproxy" > /var/cache/cloud/enabled_svcs
+ echo "haproxy" > /var/cache/cloud/enabled_svcs
echo "cloud dnsmasq conntrackd keepalived apache2 nfs-common portmap" > /var/cache/cloud/disabled_svcs
}
diff --git a/systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh b/systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh
index 8642945..ba5e2d8 100755
--- a/systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh
@@ -44,6 +44,10 @@ CMDLINE=/var/cache/cloud/cmdline
PATCH_MOUNT=$1
TYPE=$2
+# Refresh and setup systemd
+chmod -x /etc/systemd/system/cloud*.service
+systemctl daemon-reload
+
echo "Patching systemvm for cloud service with mount=$PATCH_MOUNT for type=$TYPE" >> $logfile
if [ "$TYPE" == "consoleproxy" ] || [ "$TYPE" == "secstorage" ] && [ -f ${PATCH_MOUNT}/agent.zip ]
diff --git a/systemvm/debian/opt/cloud/bin/setup/postinit.sh b/systemvm/debian/opt/cloud/bin/setup/postinit.sh
index 9a16966..d29203f 100755
--- a/systemvm/debian/opt/cloud/bin/setup/postinit.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/postinit.sh
@@ -21,10 +21,6 @@
# Eject cdrom if any
eject || true
-# Refresh and setup systemd
-chmod -x /etc/systemd/system/cloud*.service
-systemctl daemon-reload
-
# Setup router
CMDLINE=/var/cache/cloud/cmdline
for str in $(cat $CMDLINE)
@@ -44,7 +40,7 @@ if [ "$TYPE" == "router" ] || [ "$TYPE" == "vpcrouter" ] || [ "$TYPE" == "dhcpsr
then
if [ -x /opt/cloud/bin/update_config.py ]
then
- /opt/cloud/bin/update_config.py cmd_line.json
+ /opt/cloud/bin/update_config.py cmd_line.json || true
logger -t cloud "postinit: Updated config cmd_line.json"
fi
fi
@@ -54,3 +50,36 @@ then
python /opt/cloud/bin/baremetal-vr.py &
logger -t cloud "Started baremetal-vr service"
fi
+
+[ ! -f /var/cache/cloud/enabled_svcs ] && touch /var/cache/cloud/enabled_svcs
+for svc in $(cat /var/cache/cloud/enabled_svcs)
+do
+ logger -t cloud "Starting $svc"
+ systemctl enable --no-block --now $svc
+done
+
+[ ! -f /var/cache/cloud/disabled_svcs ] && touch /var/cache/cloud/disabled_svcs
+for svc in $(cat /var/cache/cloud/disabled_svcs)
+do
+ logger -t cloud "Stopping $svc"
+ systemctl disable --no-block --now $svc
+done
+
+# Enable SSH by default
+systemctl enable --no-block --now ssh
+
+# Restore the persistent iptables nat, rules and filters for IPv4 and IPv6 if they exist
+ipv4="/etc/iptables/rules.v4"
+if [ -e $ipv4 ]
+then
+ iptables-restore < $ipv4
+fi
+
+ipv6="/etc/iptables/rules.v6"
+if [ -e $ipv6 ]
+then
+ iptables-restore < $ipv6
+fi
+
+date > /var/cache/cloud/boot_up_done
+logger -t cloud "Boot up process done"
diff --git a/systemvm/debian/opt/cloud/bin/setup/secstorage.sh b/systemvm/debian/opt/cloud/bin/setup/secstorage.sh
index b890d77..8b6d4ee 100755
--- a/systemvm/debian/opt/cloud/bin/setup/secstorage.sh
+++ b/systemvm/debian/opt/cloud/bin/setup/secstorage.sh
@@ -19,7 +19,7 @@
. /opt/cloud/bin/setup/common.sh
secstorage_svcs() {
- echo "apache2 cloud ssh nfs-common portmap" > /var/cache/cloud/enabled_svcs
+ echo "apache2 cloud nfs-common portmap" > /var/cache/cloud/enabled_svcs
echo "conntrackd keepalived haproxy dnsmasq" > /var/cache/cloud/disabled_svcs
mkdir -p /var/log/cloud
}
diff --git a/systemvm/debian/opt/cloud/bin/update_config.py b/systemvm/debian/opt/cloud/bin/update_config.py
index b63cd0e..7b86378 100755
--- a/systemvm/debian/opt/cloud/bin/update_config.py
+++ b/systemvm/debian/opt/cloud/bin/update_config.py
@@ -117,13 +117,6 @@ if not (os.path.isfile(jsonConfigFile) and os.access(jsonConfigFile, os.R_OK)):
print "[ERROR] update_config.py :: Unable to read and access %s to process it" % jsonConfigFile
sys.exit(1)
-# If the command line json file is unprocessed process it
-# This is important or, the control interfaces will get deleted!
-if jsonFilename != "cmd_line.json" and os.path.isfile(jsonPath % "cmd_line.json"):
- qf = QueueFile()
- qf.setFile("cmd_line.json")
- qf.load(None)
-
# If the guest network is already configured and have the same IP, do not try to configure it again otherwise it will break
if jsonFilename.startswith("guest_network.json"):
if os.path.isfile(currentGuestNetConfig):
diff --git a/ui/l10n/en.js b/ui/l10n/en.js
index e32f358..73fa706 100644
--- a/ui/l10n/en.js
+++ b/ui/l10n/en.js
@@ -556,7 +556,6 @@ var dictionary = {"ICMP.code":"ICMP Code",
"label.console.proxy.vm":"Console Proxy VM",
"label.continue":"Continue",
"label.continue.basic.install":"Continue with basic installation",
-"label.control.ip":"Control IP",
"label.copying.iso":"Copying ISO",
"label.corrections.saved":"Corrections saved",
"label.counter":"Counter",
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index 5bb3ca5..b27007f 100755
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -10895,8 +10895,8 @@
return args;
}
},
- controlip: {
- label: 'label.control.ip'
+ publicip: {
+ label: 'label.public.ip'
},
hostname: {
label: 'label.host'
diff --git a/ui/scripts/ui/dialog.js b/ui/scripts/ui/dialog.js
index 1564a2b..c518859 100644
--- a/ui/scripts/ui/dialog.js
+++ b/ui/scripts/ui/dialog.js
@@ -897,7 +897,7 @@
$listView.dialog({
dialogClass: 'multi-edit-add-list panel',
- width: 825,
+ width: 900,
title: _l('Select VM'),
buttons: [{
text: _l('label.apply'),
diff --git a/ui/scripts/ui/widgets/multiEdit.js b/ui/scripts/ui/widgets/multiEdit.js
index 48d597e..677448a 100755
--- a/ui/scripts/ui/widgets/multiEdit.js
+++ b/ui/scripts/ui/widgets/multiEdit.js
@@ -579,7 +579,7 @@
var $dataList = $listView.addClass('multi-edit-add-list').dialog({
dialogClass: 'multi-edit-add-list panel',
- width: 825,
+ width: 900,
title: label,
buttons: [{
text: _l('label.apply'),
--
To stop receiving notification emails like this one, please contact
"commits@cloudstack.apache.org" <co...@cloudstack.apache.org>.