mirror of https://github.com/ceph/ceph-ansible.git
1 Commits (2bc58684e52d4082472ece0237bb7bab5ae315d8)
Author | SHA1 | Message | Date |
---|---|---|---|
Sébastien Han | 3e058bff06 |
ci: reboot with ansible instead of vagrant reload
vagrant is serialized and takes a lot of time compare to simple reboot. See the benchmarks below for 3 VMs: [leseb@rick docker]$ time ANSIBLE_SSH_ARGS="-F /home/leseb/reproduce-ci/tmp.zgGC7d5mIC/build/workspace/ceph-ansible/tests/functional/centos/7/docker/vagrant_ssh_config" ansible-playbook -i /home/leseb/reproduce-ci/tmp.zgGC7d5mIC/build/workspace/ceph-ansible/tests/functional/centos/7/docker/hosts reboot.yml PLAY [mons] **************************************************************************************************************************************************************************************************** TASK [Gathering Facts] ***************************************************************************************************************************************************************************************** ok: [mon1] ok: [mon2] ok: [mon0] TASK [restart machine] ***************************************************************************************************************************************************************************************** changed: [mon2] changed: [mon1] changed: [mon0] TASK [wait for server to boot] ********************************************************************************************************************************************************************************* ok: [mon2 -> localhost] ok: [mon0 -> localhost] ok: [mon1 -> localhost] TASK [uptime] ************************************************************************************************************************************************************************************************** changed: [mon2] changed: [mon0] changed: [mon1] PLAY RECAP ***************************************************************************************************************************************************************************************************** mon0 : ok=4 changed=2 unreachable=0 failed=0 mon1 : ok=4 changed=2 unreachable=0 failed=0 mon2 : ok=4 changed=2 unreachable=0 failed=0 real 0m35.112s user 0m5.737s sys 0m1.849s [leseb@rick docker]$ time vagrant reload ==> mon0: Halting domain... ==> mon0: Starting domain. ==> mon0: Waiting for domain to get an IP address... ==> mon0: Waiting for SSH to become available... ==> mon0: Creating shared folders metadata... ==> mon0: Rsyncing folder: /home/leseb/reproduce-ci/tmp.zgGC7d5mIC/build/workspace/ceph-ansible/tests/functional/centos/7/docker/ => /home/vagrant/sync ==> mon0: Machine already provisioned. Run `vagrant provision` or use the `--provision` ==> mon0: flag to force provisioning. Provisioners marked to run always will still run. ==> mon1: Halting domain... ==> mon1: Starting domain. ==> mon1: Waiting for domain to get an IP address... ==> mon1: Waiting for SSH to become available... ==> mon1: Creating shared folders metadata... ==> mon1: Rsyncing folder: /home/leseb/reproduce-ci/tmp.zgGC7d5mIC/build/workspace/ceph-ansible/tests/functional/centos/7/docker/ => /home/vagrant/sync ==> mon1: Machine already provisioned. Run `vagrant provision` or use the `--provision` ==> mon1: flag to force provisioning. Provisioners marked to run always will still run. ==> mon2: Halting domain... ==> mon2: Starting domain. ==> mon2: Waiting for domain to get an IP address... ==> mon2: Waiting for SSH to become available... ==> mon2: Creating shared folders metadata... ==> mon2: Rsyncing folder: /home/leseb/reproduce-ci/tmp.zgGC7d5mIC/build/workspace/ceph-ansible/tests/functional/centos/7/docker/ => /home/vagrant/sync ==> mon2: Machine already provisioned. Run `vagrant provision` or use the `--provision` ==> mon2: flag to force provisioning. Provisioners marked to run always will still run. real 1m31.850s user 0m7.387s sys 0m0.796s Reboot via Ansible: 0m35.112s Reboot via vagrant: 1m31.850s We save 1/3 time. Signed-off-by: Sébastien Han <seb@redhat.com> |