# there are a few buggy drivers that don't disable their hardware
# correctly unless they are first unloaded.
- utils.sysexec_noerr("ifconfig eth0 down", log)
+ utils.sysexec_noerr("ifconfig eth0 down || /usr/libexec/nm-ifdown eth0",
+ log, shell=True)
utils.sysexec_noerr("killall dhclient", log)
# start sshd
if not os.path.isfile(sshd_started_flag):
log.write("Starting sshd\n")
- utils.sysexec("service sshd start", log)
+ utils.sysexec("service sshd start || systemctl start sshd",
+ log, shell=True)
# flag that ssh is running
utils.sysexec("touch {}".format(sshd_started_flag), log)
else: