Skip to content

Commit

Permalink
Merge pull request #172 from DeliZhangX/private/deliz/CP-30513
Browse files Browse the repository at this point in the history
CP-30513: Change ifconfig to ip
  • Loading branch information
DeliZhangX authored Jan 26, 2019
2 parents c6604f6 + 26cd7d1 commit 6f8ca61
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions autocertkit/network_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -1047,10 +1047,8 @@ def _run_test(self, session):
for vm_ref in [vm1_ref, vm2_ref]:
check_vm_ping_response(session, vm_ref)

ips = [vm1_ip, vm2_ip]
# SSH to vm 'ifconfig ethX mtu XXXX up'
cmd_str = 'ifconfig eth1 mtu %s up' % self.MTU
for vm_ip in ips:
cmd_str = 'ip link set dev eth1 mtu %s' % self.MTU
for vm_ip in [vm1_ip, vm2_ip]:
ssh_command(vm_ip, self.username, self.password, cmd_str)

log.debug("Starting large MTU ping test...")
Expand All @@ -1070,7 +1068,7 @@ def _run_test(self, session):
rec['config'] = self.PING_ARGS

# Check for failure
if "0% packet loss" not in ping_result:
if " 0% packet loss" not in ping_result:
raise TestCaseError("Error: Large MTU ping transmission failed. %s"
% ping_result)

Expand Down

0 comments on commit 6f8ca61

Please sign in to comment.