
Il giorno mer 11 nov 2020 alle ore 11:01 Yedidyah Bar David <didi@redhat.com> ha scritto:
On Wed, Nov 11, 2020 at 11:49 AM Matteo Bonardi <mbona92@gmail.com> wrote:
Hi Didi,
On Tue, Nov 10, 2020 at 7:18 PM Strahil Nikolov via Users <users(a)ovirt.org> wrote:
I already suggested to open a bug for this earlier in this thread.
I will open a bug for that.
Thanks.
I am not sure. I talked with Sandro about this, and we agreed that a common enterprise requirement is being able to use a local _mirror_ (e.g. Foreman), mainly for disconnected use (without an Internet connection). A proxy is technically quite different, even if in principle can be used for the same need.
I can understand your point, but since the deploy script already checks
that the proxy is set, I don't see why it can't pass this information to the engine.
Sorry, where?
Sincerely I didn't read the code, but reading the log there are more than one reference to proxy. For example: 2020-11-10 18:15:48,518+0100 WARNING otopi.plugins.gr_he_common.network.gateway gateway._setup:88 It seems that this host is configured to use a *proxy*, please ensure that this host will be able to reach the engine VM trough that proxy or add a specific exception. 2020-11-10 18:15:49,637+0100 DEBUG otopi.ovirt_hosted_engine_setup.ansible_utils ansible_utils.run:197 ansible-playbook: env: {'LS_COLORS': [..], 'USER': 'root', 'PWD': '', 'HOME': '', 'SSH_CLIENT': '', *'https_proxy': 'http://10.248.2.50:3128/ <http://10.248.2.50:3128/>', 'http_proxy': 'http://10.248.2.50:3128/ <http://10.248.2.50:3128/>', 'no_proxy': '<my_engine>.<my_domain>'*, 'SSH_TTY': '/dev/pts/0', 'MAIL': '/var/spool/mail/root', 'SHELL': '/bin/bash', 'TERM': 'xterm', 'SHLVL': '1', 'PYTHONPATH': '/usr/share/ovirt-hosted-engine-setup/scripts/..:',[..], 'HE_ANSIBLE_LOG_PATH': '/var/log/ovirt-hosted-engine-setup/ovirt-hosted-engine-setup-ansible-get_network_interfaces-20201110181549-tppuv6.log'} 2020-11-10 18:17:11,505+0100 INFO otopi.ovirt_hosted_engine_setup.ansible_utils ansible_utils._process_output:111 TASK [ovirt.ovirt.hosted_engine_setup : *Check http/https proxy*] I'm not sure at all, but the log makes me think the proxy is being checked more than once. Of course I can be wrong.
Also:
On Wed, Nov 11, 2020 at 11:39 AM Matteo Bonardi <mbona92@gmail.com> wrote:
Thanks to all yours suggestions I, finally, complete the deploy with
success.
The solution is been to edit the file /usr/share/ansible/roles/ovirt.engine-setup/tasks/install_packages.yml adding the proxy variable:
Which version?
Perhaps you had 4.4.2 and then updated to 4.4.3 before retrying, or something similar?
Before retry the deploy, I have completely cleanup the installation with: [root@<my-host> ~]# ovirt-hosted-engine-cleanup [root@<my-host> ~]# yum remove ovirt-* And then reinstall all: [root@<my-host> ~]# yum install https://resources.ovirt.org/pub/yum-repo/ovirt-release44.rpm [root@<my-host> ~]# yum install ovirt-engine-appliance [root@<my-host> ~]# yum install ovirt-hosted-engine-setup I am a bit confused on how to check the version (it is embarrassing, but I am new on ovirt and ansible). There is a mismatch between the version in deployment server and in engine vm. I have attached the rpm version of both. The manager web console shows 4.4.2 as version.
- name: Install oVirt Engine package package: name: "ovirt-engine" state: present environment: https_proxy: "http://<proxy_host>:<proxy_port>" http_proxy: "http://<proxy_host>:<proxy_port>" ftp_proxy: "http://<proxy_host>:<proxy_port>" when: ovirt_engine_setup_product_type | lower == 'ovirt' [..]
One suggestion for who will have the same problem: This file was created by the first failed run of the deploy. Without run the deploy, this file does not exists. So you have to run the deploy one time, let it fail and then edit the
file.
I know that it seems a stupid suggestion but i think could help someone.
It's not stupid! :-). I think you unknowingly ran into something caused by the move to ovirt-ansible-roles in 4.4.3 [1].
Until 4.4.2, this file was in the package ovirt-ansible-engine-setup , in:
/usr/share/ansible/roles/ovirt.engine-setup/tasks/install_packages.yml
In 4.4.3, this file, along with many others (including hosted-engine ansible code), is in ovirt-ansible-collection, in:
/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/engine_setup/tasks/install_packages.yml
Can't guess, though, your exact flow - if you suspect a bug, please check/share relevant logs (including dnf, but perhaps also ansible), perhaps in a separate bug.
Sorry if this is confusing/messy. Feel free to comment on [1] if you have something specific to add (it's a RHV bug, though, so if unsure, perhaps file another bug. RHV's and oVirt's documentation are not as aligned as their source code).
[1] https://bugzilla.redhat.com/show_bug.cgi?id=1891749
Thanks and best regards, -- Didi
Regards, Matteo