Skip to content

Commit

Permalink
Add nolock option in case mount error
Browse files Browse the repository at this point in the history
Signed-off-by: Ming Xie <mxie@redhat.com>
  • Loading branch information
mxie91 committed Jul 29, 2024
1 parent 289525e commit 1832a18
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions virttest/utils_v2v.py
Original file line number Diff line number Diff line change
Expand Up @@ -1641,7 +1641,7 @@ def get_authorized_keys_file(server_type=None):
return authorized_keys


def v2v_mount(src, dst="v2v_mount_point", fstype="nfs"):
def v2v_mount(src, dst="v2v_mount_point", fstype="nfs", options="nolock"):
"""
Mount nfs src to dst
Expand All @@ -1652,7 +1652,7 @@ def v2v_mount(src, dst="v2v_mount_point", fstype="nfs"):
if not os.path.exists(mount_point):
os.makedirs(mount_point)

if not utils_misc.mount(src, mount_point, fstype, verbose=True):
if not utils_misc.mount(src, mount_point, fstype, options, verbose=True):
raise exceptions.TestError("Mount %s for %s failed" % (src, mount_point))

return mount_point
Expand Down

0 comments on commit 1832a18

Please sign in to comment.