Skip to content

Commit

Permalink
Fix OSError when checking the mount status
Browse files Browse the repository at this point in the history
Wrong nfs server cleanup order causes OSError. So update code.

Signed-off-by: lcheng <[email protected]>
  • Loading branch information
cliping committed Sep 2, 2024
1 parent 289525e commit 75d8e5c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions virttest/test_setup/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,12 +90,12 @@ def cleanup(self):

if self.params.get("storage_type") == "nfs":
migration_setup = self.params.get("migration_setup", "no") == "yes"
image_nfs = Nfs(self.params)
image_nfs.cleanup()
if migration_setup:
# Cleanup NFS client on remote host
nfs_client = NFSClient(self.params)
nfs_client.cleanup(ssh_auto_recover=False)
# Cleanup selinux on remote host
seLinuxBool = SELinuxBoolean(self.params)
seLinuxBool.cleanup(keep_authorized_keys=True)
image_nfs = Nfs(self.params)
image_nfs.cleanup()

0 comments on commit 75d8e5c

Please sign in to comment.