This repo contains Chia farming scripts for optimizing plotting and farming operations. The scripts automate partitioning, formatting, and plot creation on hard drives using prepare-drives.sh, create Bladebit and C7 plots with GPUs using bladebit-plotting.sh and bladebit-cuda-plotting.sh, farm GPU plots using harvester-compose.yml
If user has destination named drive-1, drive-2, ... drive-19, drive-20 then drive-1 is rarely used because the mover assumes drive-1 is in use if a current move is in progress for drive-10-19. Same can be true for drive-2 on large destinations.
Fix appears to work. - if lsof -w -p "$pid" | grep "$drive" > /dev/null + if lsof -w -p "$pid" | grep -e "$drive/" > /dev/null
Fix is looking for XXG in free space instead of 100% usage to determine fullness. Not foolproof because 99G could be considered full but plot could be much less with compression. But much better for my situation as all my drives (8T, 12T, 14T, 16T) report over 100G while usage is 100%.
- if ! df -h "$drive" | awk '{print $5}' | tail -1 | grep -q "^100"; then + if ! df -h "$drive" | awk '{print $4}' | tail -1 | grep -q "^[0-9]\{2\}G$"; then
The array code to remove full drives does not work properly. If you have drives 1-20 and drive 1 is full, the current replacement routine will substitute all drive-1 matches with ''. The remainder stays in the array. For example 'drive-11' becomes '1'. This then causes errors that day '1' is not mounted.
Comment out these lines. farming_drives=("${farming_drives[@]/$drive}") echo "Drive $drive is full. Removing it from the list of available drives."