-
OS: Ubuntu 22.04 Having an issue with this task task ansible:run playbook=cluster-prepare
Run Ansible playbook 'cluster-prepare'... continue? [y/N]
y
task: Task "workstation:venv" is up to date
task: Task "ansible:deps" is up to date
task: [ansible:run] /path/to/homelab/.venv/bin/ansible-playbook --inventory /path/to/homelab/ansible/inventory/hosts.yaml /path/to/homelab/ansible/playbooks/cluster-prepare.yaml
PLAY [Prepare System] ********************************************************************************************************************************************************************************************
TASK [Gathering Facts] *******************************************************************************************************************************************************************************************
ok: [worker-3]
ok: [worker-2]
ok: [worker-1]
ok: [control-plane]
TASK [Pausing for 5 seconds...] **********************************************************************************************************************************************************************************
Pausing for 5 seconds
(ctrl+C then 'C' = continue early, ctrl+C then 'A' = abort)
ok: [control-plane]
TASK [Populate service facts] ************************************************************************************************************************************************************************************
ok: [worker-3]
ok: [worker-2]
ok: [worker-1]
ok: [control-plane]
TASK [Locale | Set timezone] *************************************************************************************************************************************************************************************
ok: [worker-3]
ok: [worker-1]
ok: [worker-2]
ok: [control-plane]
TASK [Packages | Install] ****************************************************************************************************************************************************************************************
ok: [worker-3]
ok: [worker-2]
ok: [worker-1]
ok: [control-plane]
TASK [Network Configuration | Set hostname] **********************************************************************************************************************************************************************
ok: [worker-1]
ok: [worker-2]
ok: [worker-3]
ok: [control-plane]
TASK [Network Configuration | Update hosts] **********************************************************************************************************************************************************************
ok: [worker-2]
ok: [worker-1]
ok: [worker-3]
ok: [control-plane]
TASK [Network Configuration | Remove immutable flag from /etc/resolv.conf] ***************************************************************************************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Exception: Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf
fatal: [control-plane]: FAILED! => {"changed": false, "details": "Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf\n", "gid": 103, "group": "systemd-resolve", "mode": "0644", "msg": "chattr failed", "owner": "systemd-resolve", "path": "/run/systemd/resolve/stub-resolv.conf", "size": 934, "state": "file", "uid": 102}
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Exception: Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf
fatal: [worker-1]: FAILED! => {"changed": false, "details": "Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf\n", "gid": 103, "group": "systemd-resolve", "mode": "0644", "msg": "chattr failed", "owner": "systemd-resolve", "path": "/run/systemd/resolve/stub-resolv.conf", "size": 934, "state": "file", "uid": 102}
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Exception: Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf
fatal: [worker-2]: FAILED! => {"changed": false, "details": "Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf\n", "gid": 103, "group": "systemd-resolve", "mode": "0644", "msg": "chattr failed", "owner": "systemd-resolve", "path": "/run/systemd/resolve/stub-resolv.conf", "size": 934, "state": "file", "uid": 102}
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Exception: Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf
fatal: [worker-3]: FAILED! => {"changed": false, "details": "Error while setting attributes: /usr/bin/chattr: Operation not supported while reading flags on /run/systemd/resolve/stub-resolv.conf\n", "gid": 103, "group": "systemd-resolve", "mode": "0644", "msg": "chattr failed", "owner": "systemd-resolve", "path": "/run/systemd/resolve/stub-resolv.conf", "size": 934, "state": "file", "uid": 102}
NO MORE HOSTS LEFT ***********************************************************************************************************************************************************************************************
PLAY RECAP *******************************************************************************************************************************************************************************************************
control-plane : ok=7 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
worker-1 : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
worker-2 : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
worker-3 : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
task: Failed to run task "ansible:run": exit status 2 My solution for now has been a little hacky. I deleted the symlink |
Beta Was this translation helpful? Give feedback.
Answered by
onedr0p
Jan 30, 2024
Replies: 1 comment
-
You will see this error on Ubuntu because it uses I would suggest using Debian 12 as there is less junk included than Ubuntu. See these packages I used to remove for example |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
onedr0p
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You will see this error on Ubuntu because it uses
systemd-resolved
and probably not compatible since the playbook is geared towards Debian 12 which does not havesystemd-resolved
.I would suggest using Debian 12 as there is less junk included than Ubuntu. See these packages I used to remove for example