a5e63ee725
If we have XFS partitions formatted with ftype=0, the upgrades will fail because ftype=0 is incompatible with the docker overlayfs driver. Related-Bug: 1765121 Change-Id: I895fc83d148523c283664080b7b1bf75d53d9edb
35 lines
932 B
YAML
35 lines
932 B
YAML
---
|
|
- hosts: undercloud, overcloud
|
|
vars:
|
|
metadata:
|
|
name: XFS ftype check
|
|
description: >
|
|
Check if there is at least 1 XFS volume
|
|
with ftype=0 in any deployed node.
|
|
groups:
|
|
- pre-upgrade
|
|
tasks:
|
|
- name: Check if there are XFS volumes with ftype=0
|
|
become: true
|
|
shell: |
|
|
for dev in $(df -h | grep '/dev/' | grep -v 'tmp' | cut -d' ' -f1)
|
|
do
|
|
parseftype=$(xfs_info $dev | grep ftype=0);
|
|
if [[ ! -z "$parseftype" ]]; then
|
|
ftype="ftype=0";
|
|
break;
|
|
fi
|
|
done
|
|
echo $ftype;
|
|
register: ftype
|
|
changed_when: false
|
|
- name: Check ftype
|
|
fail:
|
|
msg: >
|
|
XFS volumes formatted using ftype=0 are incompatible
|
|
with the docker overlayfs driver.
|
|
Run xfs_info in {{ ansible_fqdn }} and fix those volumes
|
|
before proceeding with the upgrade.
|
|
when:
|
|
- ftype.stdout == 'ftype=0'
|