️ rook disk wipe optimizations

This commit is contained in:
auricom
2024-01-24 01:22:21 +01:00
parent cb87a67dd2
commit 3f34557db7

View File

@@ -17,17 +17,19 @@ spec:
nodeName: talos-node-2 nodeName: talos-node-2
containers: containers:
- name: disk-wipe - name: disk-wipe
image: rook/ceph:v1.10.8 image: rook/ceph:v1.13.2
securityContext: securityContext:
privileged: true privileged: true
command: command:
[ [
"/bin/sh", "/bin/sh",
"-c", "-c",
"sgdisk --zap-all /dev/nvme0n1", "echo 'Starting disk operations on /dev/sda'; \
"dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/nvme0n1", echo 'Running sgdisk --zap-all /dev/sda'; time sgdisk --zap-all /dev/sda; \
"blkdiscard /dev/nvme0n1", echo 'Running dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda'; time dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda; \
"partprobe /dev/nvme0n1", echo 'Running blkdiscard /dev/sda'; time blkdiscard /dev/sda; \
echo 'Running partprobe /dev/sda'; time partprobe /dev/sda; \
echo 'Disk operations completed on /dev/sda'"
] ]
volumeMounts: volumeMounts:
- mountPath: /dev - mountPath: /dev
@@ -50,17 +52,19 @@ spec:
nodeName: talos-node-3 nodeName: talos-node-3
containers: containers:
- name: disk-wipe - name: disk-wipe
image: rook/ceph:v1.10.8 image: rook/ceph:v1.13.2
securityContext: securityContext:
privileged: true privileged: true
command: command:
[ [
"/bin/sh", "/bin/sh",
"-c", "-c",
"sgdisk --zap-all /dev/nvme0n1", "echo 'Starting disk operations on /dev/sda'; \
"dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/nvme0n1", echo 'Running sgdisk --zap-all /dev/sda'; time sgdisk --zap-all /dev/sda; \
"blkdiscard /dev/nvme0n1", echo 'Running dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda'; time dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda; \
"partprobe /dev/nvme0n1", echo 'Running blkdiscard /dev/sda'; time blkdiscard /dev/sda; \
echo 'Running partprobe /dev/sda'; time partprobe /dev/sda; \
echo 'Disk operations completed on /dev/sda'"
] ]
volumeMounts: volumeMounts:
- mountPath: /dev - mountPath: /dev
@@ -83,17 +87,19 @@ spec:
nodeName: talos-node-4 nodeName: talos-node-4
containers: containers:
- name: disk-wipe - name: disk-wipe
image: rook/ceph:v1.10.8 image: rook/ceph:v1.13.2
securityContext: securityContext:
privileged: true privileged: true
command: command:
[ [
"/bin/sh", "/bin/sh",
"-c", "-c",
"sgdisk --zap-all /dev/nvme0n1", "echo 'Starting disk operations on /dev/sda'; \
"dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/nvme0n1", echo 'Running sgdisk --zap-all /dev/sda'; time sgdisk --zap-all /dev/sda; \
"blkdiscard /dev/nvme0n1", echo 'Running dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda'; time dd if=/dev/zero bs=1M count=10000 oflag=direct of=/dev/sda; \
"partprobe /dev/nvme0n1", echo 'Running blkdiscard /dev/sda'; time blkdiscard /dev/sda; \
echo 'Running partprobe /dev/sda'; time partprobe /dev/sda; \
echo 'Disk operations completed on /dev/sda'"
] ]
volumeMounts: volumeMounts:
- mountPath: /dev - mountPath: /dev