oVirt / cockpit-ovirt

cockpit-ovirt: oVirt plugin for Cockpit Project
Apache License 2.0
36 stars 18 forks source link

Unable to initiate Hosted Engine wizard #26

Closed UXabre closed 2 years ago

UXabre commented 2 years ago

Describe the bug Inside cockpit, we're unable to start the Self-Hosted Engine wizard as it tells us that it failed to retrieve system information

To reproduce Install node try and start the self-hosted engine wizard under virtualization

Expected behavior It should give us the wizard

Screenshots afbeelding

Work-around Looking in the webconsole, it seems that the system is looking for a verification role in the "/usr/share/ovirt-hosted-engine-setup/ansible" directory but there is only the "/usr/share/ovirt-hosted-engine-setup/he_ansible" folder. After symlinking this folder to ansible everything seems to work...except for storage... but that's a different bug I guess

sandrobonazzola commented 2 years ago

@avivtur @rchikatw can you please look into this?

rchikatw commented 2 years ago

@UXabre May i know which version of ovirt you are using & also what is the cockpit version installed on the host.

To check cockpit installed vestion: rpm -qa | grep cockpit

Also, I will be needing a status output of cockpit service i.e. systemctl status cockpit

UXabre commented 2 years ago

Hi, sorry for the late reply.

Version of oVirt 4.5.1

Output from rpm -qa | grep cockpit

cockpit-bridge-270-1.el8.x86_64
cockpit-system-270-1.el8.noarch
cockpit-ovirt-dashboard-0.16.0-1.el8.noarch
cockpit-storaged-269-1.el8.noarch
cockpit-ws-270-1.el8.x86_64
cockpit-270-1.el8.x86_64

Output from systemctl status cockpit -l

cockpit.service - Cockpit Web Service
   Loaded: loaded (/usr/lib/systemd/system/cockpit.service; static; vendor preset: disabled)
   Active: active (running) since Thu 2022-06-30 14:02:45 CEST; 1min 45s ago
     Docs: man:cockpit-ws(8)
  Process: 17780 ExecStartPre=/usr/libexec/cockpit-certificate-ensure --for-cockpit-tls (code=exited, status=0/SUCCESS)
 Main PID: 17783 (cockpit-tls)
    Tasks: 2 (limit: 73540)
   Memory: 1.5M
   CGroup: /system.slice/cockpit.service
           └─17783 /usr/libexec/cockpit-tls
dkelson commented 2 years ago

I have a fix for this

dkelson commented 2 years ago

After symlinking this folder to ansible everything seems to work...except for storage... but that's a different bug I guess

Is this storage bug this bug?

[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The field 'environment' has an invalid value, which includes an undefined variable. The error was: 'he_admin_username' is undefined\n\nThe error appears to be in '/usr/share/ansible/collections/ansible_collections/ovirt/ovirt/roles/hosted_engine_setup/tasks/auth_sso.yml': line 2, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n---\n- name: Obtain SSO token using username/password credentials\n ^ here\n"}

UXabre commented 2 years ago

Hi @dkelson , yes, that is absolutely and unfortunately correct :-) I got around it but....setting the default values file with my credentials... because it was the quickest way around

dkelson commented 2 years ago

Hi @dkelson , yes, that is absolutely and unfortunately correct :-) I got around it but....setting the default values file with my credentials... because it was the quickest way around

Do you have more details on the workaround? I edited auth_sso.yml and put the admin username and password in plaintext on the appropriate lines but it still failed.

Also I opened this issue https://github.com/oVirt/ovirt-engine/issues/520

UXabre commented 2 years ago

Hi @dkelson,

I've changed the following file: Usr/share/ansible/collctions/ansible_collections/ovirt/ovirt/roles/hosted-engine_setup/defaults/main.yml

he_admin_username: admin@ovirt@internal 
he_admin_password: *********
rchikatw commented 2 years ago

@arachmani Adding asaf as he maintain the HE role please merge if this looks ok

rchikatw commented 2 years ago

To create symlink navigate to /usr/share/ovirt-hosted-engine-setup directory and run this command ln -s he_ansible/ ansible