From 6888682f92c328a31c6566faa7cfeabc56b1ce6b Mon Sep 17 00:00:00 2001 From: m0duspwnens Date: Thu, 9 Jan 2025 16:14:01 -0500 Subject: [PATCH] add comments for raid scripts --- salt/hypervisor/raid.sh | 1 + salt/hypervisor/raid3.sh | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/salt/hypervisor/raid.sh b/salt/hypervisor/raid.sh index 031e4c522..b4539ba05 100644 --- a/salt/hypervisor/raid.sh +++ b/salt/hypervisor/raid.sh @@ -1,4 +1,5 @@ # quick script to create raid +# this is an example of the base functions parted -s /dev/nvme0n1 rm 1 parted -s /dev/nvme0n1 mklabel gpt parted -s /dev/nvme0n1 mkpart primary xfs 0% 100% diff --git a/salt/hypervisor/raid3.sh b/salt/hypervisor/raid3.sh index 8e7d6c7ae..4e5bd6c7f 100644 --- a/salt/hypervisor/raid3.sh +++ b/salt/hypervisor/raid3.sh @@ -1,5 +1,13 @@ #!/bin/bash +#raid3.sh is a refinement of raid2.sh. raid2.sh was used to create the raid in testing +#More detailed logging +#More thorough RAID array cleanup +#Better organized cleanup procedures +#Simplified device wiping using more modern tools (sgdisk instead of dd) +#More robust handling of existing MD arrays +#The core RAID creation and mounting functionality remains the same between both scripts, but the second version has improved error handling and cleanup procedures. + # Exit on any error set -e