I would like an ansible playbook which could be run against the proxy hosts which would allow for a quick restart of failed services.
It would run something like:
systemctl --failed (Potentially should fail if nothing returned?)
journalctl -lru <unit name> -n 50 (Optional to see log of error)
systemctl restart <unit name>
This would allow rbac_playbook runs with a --limit flag for singular proxy hosts
Metadata Update from @pingou:
- Issue tagged with: dev, high-gain, medium-trouble
Metadata Update from @smooge:
- Issue priority set to: Waiting on Assignee (was: Needs Review)
@pingou it's something y're looking for ?
If it's okay with you, I can refine it.
<img alt="restart_service.patch" src="/fedora-infrastructure/issue/raw/files/b7b0d3d774672f427d94739eb2b69f0561484274b6d6ce8fb2fffc77368caca0-restart_service.patch" />
<img alt="restart_service.patch" src="/fedora-infrastructure/issue/raw/files/8dd4cdf4bc1914ba3d7e2c3098953a55ebdc92126d0c582aac1cfc87252f7b78-restart_service.patch" />
sorry failed instead of active
here the file updated
I'd rename the file from restart_when_failed.yml to restart_failed_services.yml.
Could you open a pull-request against https://pagure.io/Fedora-Infra/ansible/ ? I have a few more comments and it'll be easier inline in the PR :)
(Note, could you add the journalctl command while at it?)
add jouranctl + open PR
Commit 98aa36b5 fixes this issue
to comment on this ticket.