Bug 1234289

Summary: HE deployment with exist VM, failed if used NFS storage path with trailing slash
Product: Red Hat Enterprise Virtualization Manager Reporter: rhev-integ
Component: ovirt-hosted-engine-setupAssignee: Simone Tiraboschi <stirabos>
Status: CLOSED ERRATA QA Contact: Artyom <alukiano>
Severity: high Docs Contact:
Priority: high    
Version: 3.5.3CC: ecohen, gklein, istein, juwu, lsurette, pstehlik, sbonazzo, stirabos, tnisan, ylavi
Target Milestone: ---Keywords: ZStream
Target Release: 3.5.4Flags: ylavi: Triaged+
Hardware: x86_64   
OS: Linux   
Whiteboard: integration
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Previously, when deploying the self-hosted engine, an NFS path with trailing slash was accepted as a user input, but redeploying failed because the path did not match VDSM output. With this update, if a trailing slash is included, it will be removed to match the VDSM output so specifying an NFS path with or without a trailing slash both works.
Story Points: ---
Clone Of: 1228239 Environment:
Last Closed: 2015-09-03 18:11:39 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1228239    
Bug Blocks: 1234795    

Description rhev-integ 2015-06-22 09:55:27 UTC
+++ This bug is a RHEV-M zstream clone. The original bug is: +++
+++   https://bugzilla.redhat.com/show_bug.cgi?id=1228239. +++
+++ Requested by "sbonazzo" +++
======================================================================



----------------------------------------------------------------------
Following comment by alukiano on June 04 at 13:04:47, 2015

Created attachment 1034713 [details]
setup log

Description of problem:
We have possibility to continue deployment with exist vm, how described in bug https://bugzilla.redhat.com/show_bug.cgi?id=1199907, but if first time that I run deployment I specify storage type NFS and storage path with trailing slash, second deployment will be failed with traceback:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/otopi/context.py", line **FILTERED**42, in _executeMethod
    method['method']()
  File "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-setup/storage/storage.py", line 942, in _misc
    self._createStorageDomain()
  File "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-setup/storage/storage.py", line 525, in _createStorageDomain
    raise RuntimeError(status['status']['message'])
RuntimeError: Storage domain already exists

Version-Release number of selected component (if applicable):
ovirt-hosted-engine-setup-1.2.4-2.el7ev.noarch

How reproducible:
always

Steps to Reproduce:
1. Run first time hosted-engine --deploy with NFS storage and nfs path with trailing slash
2. Interrupt deployment after you finis setup of engine on VM
3. Try to deploy again the same vm like described in bug https://bugzilla.redhat.com/show_bug.cgi?id=1199907

Actual results:
Second deployment failed with traceback, looks like setup not find that already exist some storage under NFS path, because it have trailing slash

Expected results:
Deployment must success

Additional info:

Comment 3 Artyom 2015-07-02 11:43:13 UTC
Verified on ovirt-hosted-engine-setup-1.2.5-1.el7ev.noarch

Comment 4 Julie 2015-07-30 05:02:58 UTC
Hi Simone,
   I've updated the doc text. Could you check if my understanding is correct? 

Kind regards,
Julie

Comment 5 Simone Tiraboschi 2015-07-30 07:25:50 UTC
Yes, it is. Thanks.

Comment 7 errata-xmlrpc 2015-09-03 18:11:39 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-1731.html