ansible playbook fail
Hello,
I am facing the following issue on a Fedora 34:
TASK [runplaybooks : Run Setup Hosts Playbook] *********************************
fatal: [controller-01]: FAILED! => {"changed": true, "cmd": "openstack-ansible --forks 2 setup-hosts.yml > /vagrant/logs/setup-hosts.log", "delta": "0:01:07.373003", "end": "2021-07-06 12:16:44.966819", "msg": "non-zero return code", "rc": 2, "start": "2021-07-06 12:15:37.593816", "stderr": " [WARNING]: Unable to parse /etc/openstack_deploy/inventory.ini as an inventory\nsource\n [WARNING]: Invalid request to find a file that matches a \"null\" value\n [WARNING]: Consider using 'become', 'become_method', and 'become_user' rather\nthan running machinectl", "stderr_lines": [" [WARNING]: Unable to parse /etc/openstack_deploy/inventory.ini as an inventory", "source", " [WARNING]: Invalid request to find a file that matches a \"null\" value", " [WARNING]: Consider using 'become', 'become_method', and 'become_user' rather", "than running machinectl"], "stdout": "", "stdout_lines": []}
TASK [runplaybooks : Running openstack-ansible setup-hosts.yml] ****************
fatal: [controller-01]: FAILED! => {"changed": true, "cmd": "openstack-ansible --forks 1 setup-hosts.yml -v > /vagrant/logs/setup-hosts-fallback.log", "delta": "0:00:46.030336", "end": "2021-07-06 12:17:31.150826", "msg": "non-zero return code", "rc": 2, "start": "2021-07-06 12:16:45.120490", "stderr": " [WARNING]: Unable to parse /etc/openstack_deploy/inventory.ini as an inventory\nsource\n [WARNING]: Invalid request to find a file that matches a \"null\" value\n [WARNING]: Consider using 'become', 'become_method', and 'become_user' rather\nthan running machinectl", "stderr_lines": [" [WARNING]: Unable to parse /etc/openstack_deploy/inventory.ini as an inventory", "source", " [WARNING]: Invalid request to find a file that matches a \"null\" value", " [WARNING]: Consider using 'become', 'become_method', and 'become_user' rather", "than running machinectl"], "stdout": "", "stdout_lines": []}
THank you, M
I have the same error.
logs/setup-hosts.log shows that openstack-ansible failes at the command aria2c [...] http://cdimage.ubuntu.com/ubuntu-base/releases/18.04/release/ubuntu-base-18.04.1-base-amd64.tar.gz which is configured to log to /var/log/aria2c-image-prestage.log in the controller-01. There you can see that downloading the ubuntu-image 404s, probably, because it's so old:
vagrant@controller-01:~$ cat /var/log/aria2c-image-prestage.log
12/09 08:28:55 [NOTICE] Downloading 1 item(s)
12/09 08:28:55 [ERROR] CUID#7 - Download aborted. URI=http://cdimage.ubuntu.com/ubuntu-base/releases/18.04/release/ubuntu-base-18.04.1-base-amd64.tar.gz
Exception: [AbstractCommand.cc:351] errorCode=3 URI=http://cdimage.ubuntu.com/ubuntu-base/releases/18.04/release/ubuntu-base-18.04.1-base-amd64.tar.gz
-> [HttpSkipResponseCommand.cc:219] errorCode=3 Resource not found
The available version is 18.04.05: http://cdimage.ubuntu.com/ubuntu-base/releases/18.04/release/
This is caused by checking out an older version 19.0.0 from https://github.com/openstack/openstack-ansible/tags , defined in config.yml
Dear @toelke,
Have you changed the URL from https://github.com/midu16/vagrant-openstack/blob/024c5bf687b7a004ca245fb3634b77ef2943d02c/full-stack.yml from the default value http://releases.ubuntu.com/16.04/ubuntu-16.04.3-server-amd64.img to http://cdimage.ubuntu.com/ubuntu-base/releases/18.04/release/ubuntu-base-18.04.1-base-amd64.tar.gz ?
I am asking, because I cannot find the command you are outputting out into the Ansible code.
Thank you, @midu16
No, I only changed config.yml; the provisioning runs to completion, but then the resulting openstack-client can't run any openstack commands, probably because of a python2/3 issue.
I am retrying today using ubuntu-20.4 as box.
@toelke Hello, whet version did you use ? because it didn't work for me as well ? Thanks
I gave up on openstack and built on kubevirt.
You said, you changed some value and it worked until the end, could you tell me what was it ?
Just a note on this. This repo that supported the book that was published a few years ago, and for the release of OpenStack at the time, has been unmaintained since 2021.
You said, you changed some value and it worked until the end, could you tell me what was it ?
I mean this was years ago, but from my message above, I guess I changed this line to a newer tag from this.
@toelke , i did it as well to a newer tag, but it didn't work, i switch to devstack anyway i wanted to follow the book's architecture guess i'm a bit late ^^
Thanks any way