Brief Description
-----------------
After restore playbook was executed, the unlock failed because docker-lv resize was not successful.
Severity
--------
Critical
Steps to Reproduce
------------------
Install a system
Backup it
Run restore playbook
Unlock controller
Expected Behavior
------------------
Unlock succeeds
Actual Behavior
----------------
Unlock fails
Reproducibility
---------------
100%
System Configuration
--------------------
AIO-SX, AIO-DX
Branch/Pull Time/Commit
-----------------------
stx master build on "2021-04-21"
Last Pass
---------
2021-04-15 worked, did not test between 15-20
Timestamp/Logs
--------------
Puppet wanted to resize docker-lv from 20G to 30G and failed at unlock:
2021-04-22T04:59:09.337 [0;32mInfo: 2021-04-22 04:59:09 +0000 Logical_volume[docker-lv](provider=lvm): Current: value=20.0, unit=G, kibi=20971520[0m
2021-04-22T04:59:09.342 [0;32mInfo: 2021-04-22 04:59:09 +0000 Logical_volume[docker-lv](provider=lvm): New: value=30.0, unit=G, kibi=31457280[0m
2021-04-22T04:59:09.345 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs --noheading -o vg_extent_size --units k /dev/cgts-vg/docker-lv'[0m
2021-04-22T04:59:09.363 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvextend -L 31457280k /dev/cgts-vg/docker-lv'[0m
2021-04-22T04:59:09.417 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: 'umount /dev/cgts-vg/docker-lv'[0m
2021-04-22T04:59:09.425 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: 'fsadm -y check /dev/cgts-vg/docker-lv'[0m
2021-04-22T04:59:09.471 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: 'fsadm -y resize /dev/cgts-vg/docker-lv 31457280k'[0m
2021-04-22T04:59:09.507 [mNotice: 2021-04-22 04:59:09 +0000 /Stage[main]/Platform::Filesystem::Docker/Platform::Filesystem[docker-lv]/Logical_volume[docker-lv]/size: size changed '20G' to '30G'[0m
2021-04-22T04:59:09.512 [0;36mDebug: 2021-04-22 04:59:09 +0000 /Stage[main]/Platform::Filesystem::Docker/Platform::Filesystem[docker-lv]/Logical_volume[docker-lv]: The container Platform::Filesystem[docker-lv] will propagate my refresh event[0m
2021-04-22T04:59:09.516 [0;36mDebug: 2021-04-22 04:59:09 +0000 Class[Platform::Lvm::Vg::Cgts_vg]: The container Stage[main] will propagate my refresh event[0m
2021-04-22T04:59:09.520 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs cgts-vg'[0m
2021-04-22T04:59:09.536 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs --noheading --unit g /dev/cgts-vg/etcd-lv'[0m
2021-04-22T04:59:09.560 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs cgts-vg'[0m
2021-04-22T04:59:09.584 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs --noheading --unit g /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:09.611 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs --noheading --unit g /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:09.632 [0;32mInfo: 2021-04-22 04:59:09 +0000 Logical_volume[kubelet-lv](provider=lvm): Current: value=2.0, unit=G, kibi=2097152[0m
2021-04-22T04:59:09.638 [0;32mInfo: 2021-04-22 04:59:09 +0000 Logical_volume[kubelet-lv](provider=lvm): New: value=10.0, unit=G, kibi=10485760[0m
2021-04-22T04:59:09.642 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvs --noheading -o vg_extent_size --units k /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:09.653 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: '/usr/sbin/lvextend -L 10485760k /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:09.710 [0;36mDebug: 2021-04-22 04:59:09 +0000 Executing: 'umount /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:10.060 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'fsadm -y check /dev/cgts-vg/kubelet-lv'[0m
2021-04-22T04:59:10.166 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'fsadm -y resize /dev/cgts-vg/kubelet-lv 10485760k'[0m
2021-04-22T04:59:10.355 [mNotice: 2021-04-22 04:59:10 +0000 /Stage[main]/Platform::Filesystem::Kubelet/Platform::Filesystem[kubelet-lv]/Logical_volume[kubelet-lv]/size: size changed '2G' to '10G'[0m
2021-04-22T04:59:10.359 [0;36mDebug: 2021-04-22 04:59:10 +0000 /Stage[main]/Platform::Filesystem::Kubelet/Platform::Filesystem[kubelet-lv]/Logical_volume[kubelet-lv]: The container Platform::Filesystem[kubelet-lv] will propagate my refresh event[0m
2021-04-22T04:59:10.364 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[wipe start of device kubelet-lv](provider=posix): Executing check 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.367 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.371 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[wipe end of device kubelet-lv](provider=posix): Executing check 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.376 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.379 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[mark lv as wiped kubelet-lv:](provider=posix): Executing check 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.382 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.kubelet-lv'[0m
2021-04-22T04:59:10.385 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[wipe start of device docker-lv](provider=posix): Executing check 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.389 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.394 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: '/usr/sbin/lvs cgts-vg'[0m
2021-04-22T04:59:10.415 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: '/usr/sbin/lvs --noheading --unit g /dev/cgts-vg/extension-lv'[0m
2021-04-22T04:59:10.441 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[wipe end of device docker-lv](provider=posix): Executing check 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.445 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.457 [0;36mDebug: 2021-04-22 04:59:10 +0000 Exec[mark lv as wiped docker-lv:](provider=posix): Executing check 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.466 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'test ! -e /etc/platform/.docker-lv'[0m
2021-04-22T04:59:10.470 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: '/usr/sbin/blkid /dev/cgts-vg/docker-lv'[0m
2021-04-22T04:59:10.476 [0;36mDebug: 2021-04-22 04:59:10 +0000 Executing: 'mkfs.xfs /dev/cgts-vg/docker-lv -n ftype=1'[0m
2021-04-22T04:59:10.485 [1;31mError: 2021-04-22 04:59:10 +0000 Execution of 'mkfs.xfs /dev/cgts-vg/docker-lv -n ftype=1' returned 1: mkfs.xfs: /dev/cgts-vg/docker-lv contains a mounted filesystem
2021-04-22T04:59:10.489 Usage: mkfs.xfs
2021-04-22T04:59:10.492 /* blocksize */ [-b log=n|size=num]
Firstly, the resize should not be triggered here, in an older load (2021-04-15 )the docker-lv was 30G before unlock.
For some reason docker-lv fs type is drbd and I think it's wrong, it should be xfs:
controller-0:/var/log# blkid /dev/cgts-vg/docker-lv
/dev/cgts-vg/docker-lv: UUID="c5c72dc8a5af335b" TYPE="drbd"
Possible similar bug: https://bugs.launchpad.net/starlingx/+bug/1883825
Test Activity
-------------
Developer Testing
Fix proposed to branch: master /review. opendev. org/c/starlingx /ansible- playbooks/ +/788748
Review: https:/