From 60a18305b6917e891cce8e625d7ca3a6ddeb2cfd Mon Sep 17 00:00:00 2001 From: kneutron <50146127+kneutron@users.noreply.github.com> Date: Thu, 8 Jul 2021 00:29:27 -0500 Subject: [PATCH] Add files via upload --- ZFS/prepvm.sh | 52 +++ ZFS/test-zfs-21-Draid--xfs.vbox | 571 ++++++++++++++++++++++++ ZFS/vbox-create-n-attach-disks-SAS96.sh | 74 +++ 3 files changed, 697 insertions(+) create mode 100644 ZFS/prepvm.sh create mode 100644 ZFS/test-zfs-21-Draid--xfs.vbox create mode 100644 ZFS/vbox-create-n-attach-disks-SAS96.sh diff --git a/ZFS/prepvm.sh b/ZFS/prepvm.sh new file mode 100644 index 0000000..4afe0ed --- /dev/null +++ b/ZFS/prepvm.sh @@ -0,0 +1,52 @@ +#!/bin/bash + +# NOTE VM MUST NOT BE RUNNING +ls -alh +vbm="VBoxManage" # Virtualbox +# Shrinkydink +#time $vbm modifymedium --compact test-zfs-21-Draid-sata0-0-roothomeswap.vdi +time $vbm modifymedium --compact test-zfs-21-Draid-sata0-0.vdi +ls -alh + +# Cleanup +/bin/rm -f Logs/* +/bin/mv *~ ~/tmpdel + +# use 7zip instead + +dirtobkp="test-zfs-21-Draid--xfs" +outfile="$dirtobkp"'.7z' + +cd .. +/bin/rm -f $outfile + +time 7z \ + a \ + -mx=9 \ + -ms=on \ + $outfile \ + $dirtobkp + +time md5sum -b $outfile > $dirtobkp.md5 +time sha1sum -b $outfile > $dirtobkp.sha1 +cat *.md5 *.sha1 +ls -alh + +date; +exit; + +time rar \ + a \ + -m5 \ + -md4096 \ + -rr1p \ + -ol \ + -ow \ + -o+ \ + -r \ + -tsm \ + -tsc \ + -s \ + -- \ + $outfile \ + $dirtobkp diff --git a/ZFS/test-zfs-21-Draid--xfs.vbox b/ZFS/test-zfs-21-Draid--xfs.vbox new file mode 100644 index 0000000..cf87af1 --- /dev/null +++ b/ZFS/test-zfs-21-Draid--xfs.vbox @@ -0,0 +1,571 @@ + + + + + 2021.0702 (2021 Dave Bechtel) Created Devuan 3.1--64 (minimal XFCE install) to test ZFS 2.1.x DRAID + +user/userpass +rt/rootpass + +vbox guest adds: 6.1.22 +kernel 4.19.0-17 + +Openssh server is installed, you can ssh in + +You will find some interesting things in /root/bin and /etc/rc.local +Have a lot of fun :^) + +migrated to dellap samt5 90 drives ++ increased SAS port count + disks to 96 + +changed HO net from intel 1000 desktop to PCNETII - had slow network - in-vm copying is fast 65-70MB/sec +best so far PCNETII +trying pcnet fast3 = good up to 96MB/sec + +intel pro 1000 T server=shitty +intel pro 1000 MT server=shitty + +going with pcnet fast3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ZFS/vbox-create-n-attach-disks-SAS96.sh b/ZFS/vbox-create-n-attach-disks-SAS96.sh new file mode 100644 index 0000000..05ed9c4 --- /dev/null +++ b/ZFS/vbox-create-n-attach-disks-SAS96.sh @@ -0,0 +1,74 @@ +#!/bin/bash + +# 2021 Dave Bechtel - for testing ZFS DRAID 2.1.x +# create ZFS data disks and attach them to existing VM +# REF: http://www.allgoodbits.org/articles/view/54 +# REF: https://superuser.com/questions/741734/virtualbox-how-can-i-add-mount-a-iso-image-file-from-command-line +# +# DO NOT RUN AS ROOT or it wont find the VM +# actually we create 96 + 8 hotspares JIC = 104; SAS drives start at number 25 + +##Check for root priviliges +if [ "$(id -u)" -eq 0 ]; then + echo "Please do NOT run $0 as root." + exit 1 +fi + +vmname=test-zfs-21-Draid--xfs + +#VBoxManage createvm --name "$vmname" --ostype 'Linux_64' --basefolder "$HOME" --register +#VBoxManage modifyvm "$vmname" --description "NOTE this is just a temp VM used to conveniently register ISOs with vbox media manager - it was created with $0" + +#VBoxManage storagectl $vmname --name IDE --add ide --controller piix3 --portcount 2 --bootable on +#VBoxManage storageattach "$vmname" --storagectl IDE --port 0 --device 0 --type dvddrive --medium emptydrive #"X:\Folder\containing\the.iso" + +#4,000,797,696 - must be evenly div.by 512 = sector size +nd=24 +# root is already on port 0 +port=1 +function mkdisks () { + for this in $(seq -w 01 $nd); do + echo $PWD/${this} + +# "Actual" 2TB - REF: https://www.virtualbox.org/manual/ch08.html#vboxmanage-createmedium +# time VBoxManage createmedium disk --filename $PWD/zfs$this.vdi --sizebyte 2000398934016 + +# "Actual" 4GB - REF: https://www.virtualbox.org/manual/ch08.html#vboxmanage-createmedium +# NOTE want unique naming for backing storage or it gets to be a PITA deleting them from VMM + time VBoxManage createmedium disk --filename $PWD/zfs$this-onT5.vdi --sizebyte 4000797696 # 400079786802 + VBoxManage storageattach "$vmname" --storagectl SATA --port $port --device 0 --type hdd --medium $PWD/zfs$this-onT5.vdi + + let port=$port+1 + done +} + +mkdisks + +# SAS controller, goin up to 128 ports +# shit, we have a constraint; 465GB SamT5 so max ~114x4GB disks; root is under 4GB and we need to leave freespace +pnd=$nd +nd=104 # we only use 96, (8) are pspares # evenly / 24 +let startd=$pnd+1 # 79 more disks on SAS +echo "startd=$startd - nd=$nd" +port=0 +function mkdiskSAS () { + for this in $(seq -w $startd $nd); do + echo $PWD/${this} + +# "Actual" 2TB - REF: https://www.virtualbox.org/manual/ch08.html#vboxmanage-createmedium +# time VBoxManage createmedium disk --filename $PWD/zfs$this.vdi --sizebyte 2000398934016 + +# "Actual" 4GB - REF: https://www.virtualbox.org/manual/ch08.html#vboxmanage-createmedium + time VBoxManage createmedium disk --filename $PWD/zfs-SAS$this.vdi --sizebyte 4000797696 + VBoxManage storageattach "$vmname" --storagectl SAS --port $port --device 0 --type hdd --medium $PWD/zfs-SAS$this.vdi + + let port=$port+1 + done +} + +mkdiskSAS + +VBoxManage showvminfo "$vmname" +date + +exit;