diff options
author | Dimitri Staessens <dimitri.staessens@ugent.be> | 2018-01-18 14:38:25 +0100 |
---|---|---|
committer | Dimitri Staessens <dimitri.staessens@ugent.be> | 2018-01-19 11:13:26 +0100 |
commit | 13cf5c0ec0f273f2a866e852047767c51c6a138b (patch) | |
tree | 22ce765fb74c286e9812952e212284df78cb66ee | |
parent | 91c87d35e3c9eeee43788f4acab2e6567bbb9c7d (diff) | |
download | rumba-13cf5c0ec0f273f2a866e852047767c51c6a138b.tar.gz rumba-13cf5c0ec0f273f2a866e852047767c51c6a138b.zip |
testbeds: Set locale on jfed nodes
Some exogeni nodes have a bad locale set, which results in a warning
message to be prepended in the output of the first command run on
the node. Running locale-gen fixes this message.
-rw-r--r-- | rumba/testbeds/jfed.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/rumba/testbeds/jfed.py b/rumba/testbeds/jfed.py index 5bf07d4..94a06e5 100644 --- a/rumba/testbeds/jfed.py +++ b/rumba/testbeds/jfed.py @@ -264,6 +264,11 @@ class Testbed(mod.Testbed): node_n.ssh_config.hostname = l_node.getAttribute("hostname") + ssh_support.execute_command( + self, + node_n.ssh_config, + "sudo locale-gen en_US.UTF-8 || true") + for intf in intfs: aux_mac_address = intf.getAttribute("mac_address") @@ -294,7 +299,7 @@ class Testbed(mod.Testbed): if isinstance(ipcp, mod.ShimEthIPCP): if self.if_id[ipcp] == i_name: ipcp.ifname = ifname - if ifname is None: + if ifname is None or ifname == "": logger.error("Could not determine name of node" "%s interface %s" % (node_n.name, mac)) |