From d2b52d977b594cfd9d201dff215bda21aa1146ae Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Wed, 4 Mar 2015 08:57:03 -0600 Subject: [PATCH] Control the nfs service correctly on rpm-based systems This fixes issue #11020 Signed-off-by: Andrew Schoen (cherry picked from commit 2e4d884fdaabbeca67b519537a80166d3cc99fa3) --- tasks/qemu.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasks/qemu.py b/tasks/qemu.py index 17554a1f0d151..bcd79caa64f58 100644 --- a/tasks/qemu.py +++ b/tasks/qemu.py @@ -188,7 +188,7 @@ def _setup_nfs_mount(remote, client, mount_dir): if remote.os.package_type == "deb": remote.run(args=['sudo', 'service', 'nfs-kernel-server', 'restart']) else: - remote.run(args=['sudo', 'systemctl', 'nfs', 'restart']) + remote.run(args=['sudo', 'systemctl', 'restart', 'nfs']) def _teardown_nfs_mount(remote, client): @@ -205,7 +205,7 @@ def _teardown_nfs_mount(remote, client): ]) else: remote.run(args=[ - 'sudo', 'systemctl', 'nfs', 'stop' + 'sudo', 'systemctl', 'stop', 'nfs' ]) log.info("Unmounting exported directory...") remote.run(args=[ @@ -226,7 +226,7 @@ def _teardown_nfs_mount(remote, client): ]) else: remote.run(args=[ - 'sudo', 'systemctl', 'nfs', 'start' + 'sudo', 'systemctl', 'start', 'nfs' ]) -- 2.39.5