deployment fails - debug: var=server_cpu_dict

Hi guys, my: -> $ ovirt-hosted-engine-setup fails every time with: ... [ INFO ] TASK [ovirt.ovirt.hosted_engine_setup : Convert CPU model name] [ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 69, column 15, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n - debug: var=server_cpu_dict\n ^ here\n\nThere appears to be both 'k=v' shorthand syntax and YAML in this task. Only one syntax may be used.\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook ... An expert would care to comment? many thanks, L

As per https://github.com/oVirt/ovirt-ansible-collection/commit/b506a125efc1901e7f1... it was removed from the code. Can you remove all 'debug' tasks and try again ? Best Regards,Strahil Nikolov On Wed, Jun 2, 2021 at 20:12, lejeczek via Users<users@ovirt.org> wrote: Hi guys, my: -> $ ovirt-hosted-engine-setup fails every time with: ... [ INFO ] TASK [ovirt.ovirt.hosted_engine_setup : Convert CPU model name] [ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 69, column 15, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n - debug: var=server_cpu_dict\n ^ here\n\nThere appears to be both 'k=v' shorthand syntax and YAML in this task. Only one syntax may be used.\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook ... An expert would care to comment? many thanks, L _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/XMSADE37OH7L3Y...

On 02/06/2021 18:29, Strahil Nikolov wrote:
As per https://github.com/oVirt/ovirt-ansible-collection/commit/b506a125efc1901e7f1... it was removed from the code.
Can you remove all 'debug' tasks and try again ?
Best Regards, Strahil Nikolov
On Wed, Jun 2, 2021 at 20:12, lejeczek via Users <users@ovirt.org> wrote: Hi guys,
my: -> $ ovirt-hosted-engine-setup
fails every time with: ... [ INFO ] TASK [ovirt.ovirt.hosted_engine_setup : Convert CPU model name] [ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml':
line 69, column 15, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n - debug: var=server_cpu_dict\n ^ here\n\nThere appears to be both 'k=v' shorthand syntax and YAML in this task. Only one syntax may be used.\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook ...
An expert would care to comment? many thanks, L _______________________________________________ Users mailing list -- users@ovirt.org <mailto:users@ovirt.org> To unsubscribe send an email to users-leave@ovirt.org <mailto:users-leave@ovirt.org> Privacy Statement: https://www.ovirt.org/privacy-policy.html <https://www.ovirt.org/privacy-policy.html> oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ <https://www.ovirt.org/community/about/community-guidelines/> List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/XMSADE37OH7L3Y... <https://lists.ovirt.org/archives/list/users@ovirt.org/message/XMSADE37OH7L3YSTWWD6AOQML6Y3E3WA/>
If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message. thanks, L.

Maybe you can provide the error ? Best Regards,Strahil Nikolov If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message.

On 04/06/2021 08:41, Strahil Nikolov wrote:
Maybe you can provide the error ?
Best Regards, Strahil Nikolov
If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message.
[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 64, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n {{ server_cpu_list['ovirt_system_option']['values'][0]['value'].split('; ')|list|difference(['']) }}\n - name: Convert CPU model name\n ^ here\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook

We need to identify the var value. Can you add something like this before the problematic task:- name: DEBUG debug: var: server_cpu_list In cockpit, before running it, there is an option to edit the playbook. Best Regards,Strahil Nikolov On Fri, Jun 4, 2021 at 16:57, lejeczek via Users<users@ovirt.org> wrote: On 04/06/2021 08:41, Strahil Nikolov wrote:
Maybe you can provide the error ?
Best Regards, Strahil Nikolov
If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message.
[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 64, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n {{ server_cpu_list['ovirt_system_option']['values'][0]['value'].split('; ')|list|difference(['']) }}\n - name: Convert CPU model name\n ^ here\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/DC2AKUE5PII5QK...

On Fri, Jun 4, 2021 at 9:04 PM Strahil Nikolov via Users <users@ovirt.org> wrote:
We need to identify the var value.
Can you add something like this before the problematic task: - name: DEBUG debug: var: server_cpu_list
In cockpit, before running it, there is an option to edit the playbook.
I reported a similar (identical?) failure at [1]. Please check that thread. It seems like the recommended workaround is to remove (or not install) edk2-ovmf. [1] https://lists.ovirt.org/archives/list/devel@ovirt.org/thread/PGBNPWBGT6KFPIB... Best regards,
Best Regards, Strahil Nikolov
On Fri, Jun 4, 2021 at 16:57, lejeczek via Users <users@ovirt.org> wrote:
On 04/06/2021 08:41, Strahil Nikolov wrote:
Maybe you can provide the error ?
Best Regards, Strahil Nikolov
If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message.
[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 64, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n {{ server_cpu_list['ovirt_system_option']['values'][0]['value'].split('; ')|list|difference(['']) }}\n - name: Convert CPU model name\n ^ here\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/DC2AKUE5PII5QK...
_______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/TMNW2IY6RRPMUA...
-- Didi

Thanks Didi, it will be even better if we see the output of the debug with and without edk2-ovmf. Best Regards,Strahil Nikolov On Sun, Jun 6, 2021 at 9:29, Yedidyah Bar David<didi@redhat.com> wrote: On Fri, Jun 4, 2021 at 9:04 PM Strahil Nikolov via Users <users@ovirt.org> wrote:
We need to identify the var value.
Can you add something like this before the problematic task: - name: DEBUG debug: var: server_cpu_list
In cockpit, before running it, there is an option to edit the playbook.
I reported a similar (identical?) failure at [1]. Please check that thread. It seems like the recommended workaround is to remove (or not install) edk2-ovmf. [1] https://lists.ovirt.org/archives/list/devel@ovirt.org/thread/PGBNPWBGT6KFPIB... Best regards,
Best Regards, Strahil Nikolov
On Fri, Jun 4, 2021 at 16:57, lejeczek via Users <users@ovirt.org> wrote:
On 04/06/2021 08:41, Strahil Nikolov wrote:
Maybe you can provide the error ?
Best Regards, Strahil Nikolov
If it's about taking out 'debug' from the file mentioned above then - no - deployment still fails at that same step with slightly different error message.
[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute ''\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/create_target_vm/01_create_target_hosted_engine_vm.yml': line 64, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n {{ server_cpu_list['ovirt_system_option']['values'][0]['value'].split('; ')|list|difference(['']) }}\n - name: Convert CPU model name\n ^ here\n"} [ ERROR ] Failed to execute stage 'Closing up': Failed executing ansible-playbook _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/DC2AKUE5PII5QK...
_______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/TMNW2IY6RRPMUA...
-- Didi _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/VHUHVZPUFV2DNU...
participants (3)
-
lejeczek
-
Strahil Nikolov
-
Yedidyah Bar David