diff --git a/scripts/apply-bond-hash.sh b/scripts/apply-bond-hash.sh index eab0156..79f1a63 100755 --- a/scripts/apply-bond-hash.sh +++ b/scripts/apply-bond-hash.sh @@ -57,7 +57,7 @@ fi # Show current bond state echo "" echo "--- Current bond0 state ---" -cat /proc/net/bonding/bond0 2>/dev/null | head -15 || echo "(bond0 not up or not present)" +head -15 /proc/net/bonding/bond0 2>/dev/null || echo "(bond0 not up or not present)" # Back up cp -a /etc/network/interfaces "$BACKUP_DIR/interfaces" @@ -131,7 +131,7 @@ sleep 5 echo "" echo "--- Post-change bond0 state ---" -cat /proc/net/bonding/bond0 2>/dev/null | head -20 +head -20 /proc/net/bonding/bond0 2>/dev/null echo "" echo "===================================================================" diff --git a/scripts/fix-bond-nfs.sh b/scripts/fix-bond-nfs.sh index 47bd947..c7eec66 100755 --- a/scripts/fix-bond-nfs.sh +++ b/scripts/fix-bond-nfs.sh @@ -42,7 +42,7 @@ fi # Verify live state echo "" echo "Live bond0 hash policy:" -cat /proc/net/bonding/bond0 | grep "Transmit Hash" +grep "Transmit Hash" /proc/net/bonding/bond0 # 2b: Persist in /etc/network/interfaces (fix the sed that failed before) echo "" @@ -78,7 +78,7 @@ awk '/^auto bond0/,/^$/' /etc/network/interfaces # Final verify echo "" echo "--- Final bond0 running state ---" -cat /proc/net/bonding/bond0 | head -20 +head -20 /proc/net/bonding/bond0 echo "" echo "==================================================================="