Last active
November 10, 2020 23:25
-
-
Save zmc/63ac22414a3bd4d42fd13cf11dc7f5ab to your computer and use it in GitHub Desktop.
FIO on Power reproducer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: v1 | |
kind: Namespace | |
metadata: | |
name: fio-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: fio-test | |
namespace: fio-test | |
spec: | |
containers: | |
- image: nginx | |
name: fio-test | |
volumeMounts: | |
- mountPath: /var/lib/www/html | |
name: fio-test | |
volumes: | |
- name: fio-test | |
persistentVolumeClaim: | |
claimName: fio-test | |
readOnly: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: v1 | |
kind: PersistentVolumeClaim | |
metadata: | |
name: fio-test | |
namespace: fio-test | |
spec: | |
accessModes: | |
- ReadWriteOnce | |
resources: | |
requests: | |
storage: 3Gi | |
storageClassName: ocs-storagecluster-cephfs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -x | |
oc create -f ./fio-ns.yaml | |
sleep 5 | |
oc create -f ./fio-pvc.yaml | |
sleep 5 | |
oc create -f ./fio-pod.yaml | |
sleep 20 | |
oc rsh -n fio-test fio-test apt update | |
oc rsh -n fio-test fio-test apt install -y fio |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -x | |
oc delete pod -n fio-test fio-test | |
oc delete pvc -n fio-test fio-test | |
oc delete namespace fio-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -ex | |
RUNS=0 | |
while true; do | |
time oc rsh -n fio-test fio-test fio --name=fio-rand-readwrite --filename=/var/lib/www/html/fio-rand-readwrite --readwrite=randrw --bs=4K --direct=1 --numjobs=1 --time_based=1 --runtime=60 --size=1G --iodepth=4 --invalidate=1 --fsync_on_close=1 --rwmixread=75 --ioengine=libaio --rate=1m --rate_process=poisson --output-format=json | |
echo "fio rc: $?" | |
RUNS=$(echo $RUNS+1 | bc) | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment