summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOleg Strikov <oleg.strikov@canonical.com>2014-02-27 18:04:17 +0400
committerOleg Strikov <oleg.strikov@canonical.com>2014-02-27 18:04:17 +0400
commit516bba11344c7c22aa23e09793a6cdf53faebf01 (patch)
tree699a3c6ac73006052cc3a788a3c0e281c56d9c0e
parent21fc25fbc0e73e15710d2f0333f7d3ba13eb3739 (diff)
downloadvyos-cloud-init-516bba11344c7c22aa23e09793a6cdf53faebf01.tar.gz
vyos-cloud-init-516bba11344c7c22aa23e09793a6cdf53faebf01.zip
AltCloud: do not run dmidecode on arm32/arm64 because it leads to kvm crash
See LP1243287 for more information
-rw-r--r--cloudinit/sources/DataSourceAltCloud.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/cloudinit/sources/DataSourceAltCloud.py b/cloudinit/sources/DataSourceAltCloud.py
index a834f8eb..1e913a6e 100644
--- a/cloudinit/sources/DataSourceAltCloud.py
+++ b/cloudinit/sources/DataSourceAltCloud.py
@@ -115,6 +115,12 @@ class DataSourceAltCloud(sources.DataSource):
'''
+ uname_arch = os.uname()[4]
+ if uname_arch.startswith("arm") or uname_arch == "aarch64":
+ # Disabling because dmidecode in CMD_DMI_SYSTEM crashes kvm process
+ LOG.debug("Disabling AltCloud datasource on arm (LP: #1243287)")
+ return 'UNKNOWN'
+
cmd = CMD_DMI_SYSTEM
try:
(cmd_out, _err) = util.subp(cmd)