Bug 1624529
| Summary: | hosted-engine-setup doesn't restore hostname entry of RHV manager under "/etc/hosts" at the end of the setup if the engine VM is configured with DHCP | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Virtualization Manager | Reporter: | Ameya Charekar <achareka> |
| Component: | ovirt-hosted-engine-setup | Assignee: | Simone Tiraboschi <stirabos> |
| Status: | CLOSED ERRATA | QA Contact: | Liran Rotenberg <lrotenbe> |
| Severity: | low | Docs Contact: | |
| Priority: | medium | ||
| Version: | 4.2.5 | CC: | achareka, lsurette |
| Target Milestone: | ovirt-4.2.7 | Keywords: | ZStream |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | ovirt-hosted-engine-setup-2.2.27-1.el7ev.noarch.rpm | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-11-05 15:03:44 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | Integration | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 1629888 | ||
|
Description
Ameya Charekar
2018-09-01 00:04:39 UTC
There is an explicit task to add id back at the end of the deployment: https://github.com/oVirt/ovirt-hosted-engine-setup/blob/master/src/ansible/create_target_vm.yml#L443 and it's under "when: VM_ETC_HOSTS and VM_IP_ADDR is not none" condition. Ameya, did you deployed from cockpit or from CLI? Can you please attach hosted-engine-setup logs? OK, the issue comes from here: 2018-09-05 05:48:28,943+0530 DEBUG otopi.plugins.otopi.dialog.human dialog.__logString:204 DIALOG:SEND How should the engine VM network be configured (DHCP, Static)[DHCP]? 2018-09-05 05:48:30,105+0530 DEBUG otopi.plugins.otopi.dialog.human human.queryString:159 query CI_VM_ETC_HOST We are temporary removing the entry under /etc/hosts since the bootstrap VM it's running on libvirt default netted network over a different address. We are not restoring it at the end since the engine VM is configured to use DHCP and so VM_IP_ADDR is none and when: VM_ETC_HOSTS and VM_IP_ADDR is not none fails for that. Verified on: ovirt-hosted-engine-setup-2.2.27-1.el7ev.noarch Steps: 1. Set a FQDN entry for the future engine in /etc/hosts. 2. Deploy HE(# hosted-engine --deploy) 3. In the deployment select DHCP on: How should the engine VM network be configured (DHCP, Static)[DHCP]? 4. Check the /etc/hosts after: TASK [Create an entry in /etc/hosts for the local VM] and TASK [Remove temporary entry in /etc/hosts for the local VM] Results: The host was set in /etc/hosts: # cat /etc/hosts 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 10.65.211.18 my-amazing-test.redhat.com 10.35.72.233 <EngineFQDN> After TASK [Create an entry in /etc/hosts for the local VM]: # cat /etc/hosts 192.168.122.199 <EngineFQDN> # temporary entry added by hosted-engine-setup for the bootstrap VM 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 10.65.211.18 my-amazing-test.redhat.com 10.35.72.233 <EngineFQDN> After TASK [Remove temporary entry in /etc/hosts for the local VM]: # cat /etc/hosts 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 10.65.211.18 my-amazing-test.redhat.com 10.35.72.233 <EngineFQDN> Where <EngineFQDN> is the desired FQDN. 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://access.redhat.com/errata/RHBA-2018:3482 |