Skip to content

Commit

Permalink
test: use pvcreate with a timeout and verbose logging
Browse files Browse the repository at this point in the history
the pvcreate call gives us problems, and different problems on different
platforms.  Use `timeout 30s` to avoid hangs when it tries
to read from stdin.  Use verbose `-vvv` to figure out why it
hangs/fails.  Use `-y` to make it not ask questions and continue
anyway.

Signed-off-by: Rich Megginson <[email protected]>
  • Loading branch information
richm committed Aug 19, 2024
1 parent 6f53e54 commit 344e14b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/tests_lvm_pool_pv_grow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@
min_size: "10g"

- name: Create PV with a space to grow
command: "pvcreate --setphysicalvolumesize {{ pv_size }} /dev/{{ unused_disks[0] }}"
command: >-
timeout 30s pvcreate -vvv -y --setphysicalvolumesize
{{ pv_size | quote }} /dev/{{ unused_disks[0] | quote }}
register: pvcreate_output
changed_when: pvcreate_output.rc != 0

Expand Down

0 comments on commit 344e14b

Please sign in to comment.