#!/bin/bash set -uo pipefail BASE=/home/rafa/joomla-migration/mirror-antiguo RUN=$(cat "$BASE/CURRENT_RUN") DIR=$BASE/runs/$RUN echo "ahora: $(date -u +%FT%TZ)" echo "wget vivos: $(pgrep -cf 'wget --input-file=')" echo "monitor vivo: $(pgrep -cf '22-monitor.sh')" echo "ficheros: $(find "$DIR/raw" -type f 2>/dev/null | wc -l)" du -sh "$DIR/raw" 2>/dev/null echo "--- monitor.log ---"; tail -6 "$DIR/logs/monitor.log" echo "--- ultimo log de wget activo ---" ls -t "$DIR/logs"/wget-*.log | head -1 | xargs tail -2 free -m | head -2