Tags: jtudelag/ceph-ansible
Tags
update: look for short and fqdn in ceph_health_raw According to hostname configuration, the task waiting for mons to be in quorum might fail. The idea here is to look for both shortname and fqdn in `ceph_health_raw` instead of just `ansible_hostname` Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1546127 Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com> (cherry picked from commit c04e673) Signed-off-by: Sébastien Han <seb@redhat.com>
container: osd remove run_once When used along with delegate, run_once does not belong well. Thus, using | last always brings the desired result. Signed-off-by: Sébastien Han <seb@redhat.com> (cherry picked from commit c816a92) Signed-off-by: Sébastien Han <seb@redhat.com>
Check for docker sockets named after both _hostname or _fqdn While hostname -f will always return an hostname including its domain part and -s without the domain part, the behavior when no arguments are given can include or not include the domain part depending on how the system is configured; the socket name might not match the instance name then. (cherry picked from commit bdcc52b) Signed-off-by: Sébastien Han <seb@redhat.com>
purge-docker: fix ceph-osd-zap name container the `zap ceph osd disks` task should iter on `resolved_parent_device` instead of `combined_devices_list` which contain only the base device name (vs. full path name in `combined_devices_list`). this fixes the issue where docker complain about container name because of illegal characters such as `/` : ``` "/usr/bin/docker-current: Error response from daemon: Invalid container name (ceph-osd-zap-magna074-/dev/sdb1), only [a-zA-Z0-9][a-zA-Z0-9_.-] are allowed.","See '/usr/bin/docker-current run --help'." "" ``` having the the basename of the device path is enough for the container name. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1540137 Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com> (cherry picked from commit 3b2f6c3)
syntax: change local_action syntax Use a nicer syntax for `local_action` tasks. We used to have oneliner like this: ``` local_action: wait_for port=22 host={{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }} state=started delay=10 timeout=500 }} ``` The usual syntax: ``` local_action: module: wait_for port: 22 host: "{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}" state: started delay: 10 timeout: 500 ``` is nicer and kind of way to keep consistency regarding the whole playbook. This also fix a potential issue about missing quotation : ``` Traceback (most recent call last): File "/tmp/ansible_wQtWsi/ansible_module_command.py", line 213, in <module> main() File "/tmp/ansible_wQtWsi/ansible_module_command.py", line 185, in main rc, out, err = module.run_command(args, executable=executable, use_unsafe_shell=shell, encoding=None, data=stdin) File "/tmp/ansible_wQtWsi/ansible_modlib.zip/ansible/module_utils/basic.py", line 2710, in run_command File "/usr/lib64/python2.7/shlex.py", line 279, in split return list(lex) File "/usr/lib64/python2.7/shlex.py", line 269, in next token = self.get_token() File "/usr/lib64/python2.7/shlex.py", line 96, in get_token raw = self.read_token() File "/usr/lib64/python2.7/shlex.py", line 172, in read_token raise ValueError, "No closing quotation" ValueError: No closing quotation ``` writing `local_action: shell echo {{ fsid }} | tee {{ fetch_directory }}/ceph_cluster_uuid.conf` can cause trouble because it's complaining with missing quotes, this fix solves this issue. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1510555 Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com> (cherry picked from commit deaf273) Signed-off-by: Sébastien Han <seb@redhat.com>
ceph-common: Don't check for ceph_stable_release for distro packages When we consume the distribution packages, we don't have the choise on which version to install, so we shouldn't require that variable to be set. Distributions normally provide only one version of Ceph in the official repositories so we get whatever they provide. Signed-off-by: Markos Chandras <mchandras@suse.de> (cherry picked from commit dd6ee72)
upgrade: skip luminous tasks for jewel minor update These tasks are needed only when upgrading to luminous. They are not needed in Jewel minor upgrade and by the way, they fail because `ceph versions` command doesn't exist. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1535382 (cherry picked from commit c7ec12d) Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
osds: change default value for `dedicated_devices` This is to keep backward compatibility with stable-2.2 and satisfy the check "verify dedicated devices have been provided" in `check_mandatory_vars.yml`. This check is looking for `dedicated_devices` so we need to default it's value to `raw_journal_devices` when `raw_multi_journal` is set to `True`. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1536098 Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com> (cherry picked from commit 9306a17)
purge-container: use lsblk to resolv parent device Using `lsblk` to resolv the parent device is better than just removing the last char when passing it to the zap container. Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com> (cherry picked from commit 55298fa) Signed-off-by: Sébastien Han <seb@redhat.com>
PreviousNext