Woodpecker should respect 'fio' action's 'disk-devices' parameter regardless of configuration of 'test-devices'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Woodpecker Charm |
Triaged
|
Medium
|
Unassigned |
Bug Description
Woodpecker should respect 'fio' action's 'disk-devices' parameter regardless of configuration of 'test-devices'.
Currently, if 'test-devices' is configured, woodpecker ignores 'fio' action's 'disk-devices' parameter. See the current implementation in on_fio_action():
```
if not self.ceph_
event.
" ".join(
)
```
It makes it impossible to specify exactly which disk-devices should be used for testing.
In my case, I'd like to run fio tests on ephemeral device, instead of on cinder volumes attached to the woodpecker VM. For that. I have created a flavor with an ephemeral disk and I'm using this flavor when deploying woodpecker units:
```
openstack flavor create \
--vcpus 4 \
--ram 8192 \
--disk 20 \
--ephemeral 10 \
m1.large.
juju deploy cs:~openstack-
--num-units ${NUMBER_OF_UNITS} \
--storage test-devices=
--constraints "cores=4 allocate-
--series bionic \
woodpecker
```
Once I have woodpecker units deployed, I want to run fio action only on top of ephemeral devices:
```
juju run --application woodpecker sudo umount /mnt
juju run-action woodpecker/0 \
fio operation=randwrite runtime=900 block-size=4k disk-devices=
``
Currently, the above action is not run on a specified disk (disk-devices=
As a workaround, I have to first detach the juju storage from the woodpecker VMs:
```
juju detach-storage test-devices/
```
Changed in charm-woodpecker: | |
status: | New → Triaged |
importance: | Undecided → Medium |
Action documentation is not in line with the code that implements it:
Action documentation:
```
fio:
description: "Run the fio performance test"
params:
disk-devices:
type: string
description: "If unset, use the charm default rbd device in the ceph pool or the block devices provided using test-devices storage. If set run fio, against the set disk. Space delimited list of devices."
```
Code: client. pools_available and test_devices:
event. params[ "disk-devices" ] = ( [str(d. location) for d in test_devices])
```
# If storage binding provided then override disk-devices
# unless the application is related to ceph.
if not self.ceph_
" ".join(
)
```