I've reverified that install new host, check for upgrades, upgrade host and
enroll certificates work fine even with ansible 2.9.10 on standalone engine
installation. So there is some issue inside HCI installer, which doesn't
handle python interpreter correctly.
Gianluca, could you please create a bug for that?
Thanks,
Martin
On Fri, Jul 17, 2020 at 11:36 AM Gianluca Cecchi <gianluca.cecchi(a)gmail.com>
wrote:
On Fri, Jul 17, 2020 at 11:25 AM Gianluca Cecchi <
gianluca.cecchi(a)gmail.com> wrote:
> On Fri, Jul 17, 2020 at 11:04 AM Gianluca Cecchi <
> gianluca.cecchi(a)gmail.com> wrote:
>
>> On Fri, Jul 17, 2020 at 10:58 AM Gianluca Cecchi <
>> gianluca.cecchi(a)gmail.com> wrote:
>>
>>> On Fri, Jul 17, 2020 at 10:54 AM Martin Perina <mperina(a)redhat.com>
>>> wrote:
>>>
>>>> Hi Gianluca,
>>>>
>>>> that's very strange error, because I'm 100% sure we are using
yum
>>>> module with Python3 in several other roles including adding host to
engine
>>>> or upgrading host and so far I haven't heard any issue with ansible
2.9.10
>>>> and yum module.
>>>>
>>>> Gobinda, wouldn't enforcing python interpreter version help there?
>>>>
>>>>
>>>>
https://github.com/oVirt/ovirt-engine/blob/master/packaging/ansible-runne...
>>>>
>>>> Regards,
>>>> Martin
>>>>
>>>>
>>> I have a very clean install from 4.1.1.1 node ng iso anf I'm the third
>>> to notice that with this release.
>>> The engine deployment is going on. Not finished yet, but to have ti go
>>> I had to modify, with the same strategy ("use: dnf" with package
module and
>>> use "package" instead of "yum" and also specifying
"use: dnf") in these
>>> files under /usr/share/ansible/roles:
>>>
>>> ovirt.engine-setup/tasks/engine_setup.yml
>>> ovirt.engine-setup/tasks/install_packages.yml
>>> ovirt.hosted_engine_setup/tasks/install_packages.yml
>>>
>>>
ovirt.hosted_engine_setup/tasks/create_target_vm/03_hosted_engine_final_tasks.yml
>>> ovirt.hosted_engine_setup/tasks/install_appliance.yml
>>>
>>> Gianluca
>>>
>>
>> The installation from the iso was with all default values.
>> The only "non standard" thing, if we want it to call this way is that
>> before running the wizard, on the host I pre-installed the appliance
>> package, to shorten the deploy phase hereafter.
>> And to do it I executed, because of habit:
>> yum install ovirt-engine-appliance
>>
>> instead of "dnf install...", but I think this doesn't influence
ansible
>> autodetect when using "package" module or the error about python2 when
>> using "yum" module...
>>
>> Gianluca
>>
>
> The engine deployment failed in the phase where it tries to add the host
> and waits for the host to be up and if I go into the logs in
>
>
/var/log/ovirt-hosted-engine-setup/engine-logs-2020-07-17T08:30:48Z/ovirt-engine/host-deploy/
>
> the file
> ovirt-host-deploy-ansible-20200717104103-novirt2.example.net-3a710f0c.log
> contains
>
> 020-07-17 10:41:17 CEST - fatal: [
novirt2.example.net]: FAILED! =>
> {"changed": false, "module_stderr": "/bin/sh: /usr/bin
> /python2: No such file or directory\n", "module_stdout": "",
"msg": "The
> module failed to execute correctly, you probably
> need to set the interpreter.\nSee stdout/stderr for the exact error",
> "rc": 127}
> 2020-07-17 10:41:17 CEST - {
> "status" : "OK",
> "msg" : "",
> "data" : {
> "uuid" : "00f4c6a8-8423-4a2a-bfd5-f38c34f56ecf",
> "counter" : 53,
> "stdout" : "fatal: [
novirt2.example.net]: FAILED! =>
{\"changed\":
> false, \"module_stderr\": \"/bin/sh: /usr/bin/pytho
> n2: No such file or directory\\n\", \"module_stdout\": \"\",
\"msg\":
> \"The module failed to execute correctly, you probab
> ly need to set the interpreter.\\nSee stdout/stderr for the exact
> error\", \"rc\": 127}",
>
> So I think I have to find and solve why it searches python2....
> I compared on an existing 4.4.0 environment I have (hci single node
> installed from 4.4.0 node ng iso) and no python2 apparently there, only
> ansible that is at ansible-2.9.9-1.el8.noarch instead of
> ansible-2.9.10-1.el8.noarch of 4.4.1.1
>
> Possibly any wrong default about python?
>
> Alternatives seems the same between 4.4.0 and 4.4.1.1
>
> 4.4.0
> [g.cecchi@ovirt01 ~]$ alternatives --list
> cifs-idmap-plugin auto /usr/lib64/cifs-utils/cifs_idmap_sss.so
> ifup auto /etc/sysconfig/network-scripts/ifup
> ld auto /usr/bin/ld.bfd
> libnssckbi.so.x86_64 auto /usr/lib64/pkcs11/p11-kit-trust.so
> libwbclient.so.0.15-64 auto
> /usr/lib64/samba/wbclient/libwbclient.so.0.15
> mkisofs auto /usr/bin/genisoimage
> mta auto /usr/sbin/sendmail.postfix
> nmap auto /usr/bin/ncat
> python auto /usr/libexec/no-python
> python3 auto /usr/bin/python3.6
> [g.cecchi@ovirt01 ~]$
>
> 4.4.1.1
> [root@novirt2 host-deploy]# alternatives --list
> cifs-idmap-plugin auto /usr/lib64/cifs-utils/cifs_idmap_sss.so
> ifup auto /etc/sysconfig/network-scripts/ifup
> ld auto /usr/bin/ld.bfd
> libnssckbi.so.x86_64 auto /usr/lib64/pkcs11/p11-kit-trust.so
> libwbclient.so.0.15-64 auto
> /usr/lib64/samba/wbclient/libwbclient.so.0.15
> mkisofs auto /usr/bin/genisoimage
> mta auto /usr/sbin/sendmail.postfix
> nmap auto /usr/bin/ncat
> python auto /usr/libexec/no-python
> python3 auto /usr/bin/python3.6
> [root@novirt2 host-deploy]#
>
> Not sure where to search if not somehow a bug of ansible 2.9.10
> Can I try to clean install a 4.4.1.1 host and downgrade ansible before
> deploy, eg running
>
> rpm -Uvh --oldpackage ansible-2.9.9-1.el8.noarch
> ?
>
> Where to get the 2.9.9 rpm to apply in case, just to exclude it?
>
> Gianluca
>
>
Inside
ovirt-host-deploy-ansible-20200717104103-novirt2.example.net-3a710f0c.log
at the beginning the gathering of facts seems all ok and python3, but then
I see this:
2020-07-17 10:41:14 CEST - TASK [ovirt-host-deploy-facts : Reset
configuration of advanced virtualization module] ***
2020-07-17 10:41:14 CEST - TASK [ovirt-host-deploy-facts : Enable advanced
virtualization module for relevant OS version] ***
2020-07-17 10:41:17 CEST - TASK [ovirt-host-deploy-facts : Install Python3
for CentOS/RHEL8 hosts] ********
2020-07-17 10:41:17 CEST -
2020-07-17 10:41:17 CEST - skipping: [
novirt2.example.net]
2020-07-17 10:41:17 CEST - TASK [ovirt-host-deploy-facts : Set facts]
*************************************
2020-07-17 10:41:17 CEST -
2020-07-17 10:41:17 CEST - ok: [
novirt2.example.net]
2020-07-17 10:41:17 CEST - {
"status" : "OK",
"msg" : "",
"data" : {
"uuid" : "c6ab4add-cf41-41b0-b7c8-2a3d156542fa",
"counter" : 39,
"stdout" : "ok: [novirt2.example.net]",
"start_line" : 37,
"end_line" : 38,
"runner_ident" : "402b6968-c809-11ea-9d36-00163e0765c1",
"event" : "runner_on_ok",
"pid" : 28793,
"created" : "2020-07-17T08:41:14.380339",
"parent_uuid" : "00163e07-65c1-0ebc-a725-000000000021",
"event_data" : {
"playbook" : "ovirt-host-deploy.yml",
"playbook_uuid" : "eb09419a-dc4a-4ea7-9d94-3f666d9d17e0",
"play" : "all",
"play_uuid" : "00163e07-65c1-0ebc-a725-000000000006",
"play_pattern" : "all",
"task" : "Set facts",
"task_uuid" : "00163e07-65c1-0ebc-a725-000000000021",
"task_action" : "set_fact",
"task_args" : "",
"task_path" :
"/usr/share/ovirt-engine/ansible-runner-service-project/project/roles/ovirt-host-deploy-facts/tasks/main.yml:26",
"role" : "ovirt-host-deploy-facts",
"host" : "novirt2.example.net",
"remote_addr" : "novirt2.example.net",
"res" : {
"changed" : false,
"ansible_facts" : {
"ansible_python_interpreter" : "/usr/bin/python2"
},
"_ansible_no_log" : false
},
"start" : "2020-07-17T08:41:14.242287",
"end" : "2020-07-17T08:41:14.379769",
"duration" : 0.137482,
"event_loop" : null,
"uuid" : "c6ab4add-cf41-41b0-b7c8-2a3d156542fa"
}
}
}
and then the failure because the ansible_python_intepreter has been set to
pythin2
Gianluca