diff --git a/functions.sh b/functions.sh index aff8a5fd..1ef8e63c 100644 --- a/functions.sh +++ b/functions.sh @@ -472,6 +472,12 @@ function cleanup_host { # logs files we don't want to keep sudo rm $BASE/logs/grenade.sh.log.* + # Copy failure files if they exist + if [ $(ls $BASE/stack/status/*.failure | wc -l) -gt 0 ]; then + sudo mkdir -p $BASE/logs/status + sudo cp $BASE/status/stack/*.failure $BASE/logs/status/ + fi + # Copy tempest config file sudo cp $BASE/new/tempest/etc/tempest.conf $NEWLOGTARGET/tempest_conf.txt @@ -526,6 +532,11 @@ function cleanup_host { sudo mv $f ${f/.log/.txt} done + #rename all failure files to have .txt + for f in $(find $BASE/logs/status -name "*.failure"); do + sudo mv $f ${f/.failure/.txt} + done + # append .txt to all config files # (there are some /etc/swift .builder and .ring files that get # caught up which aren't really text, don't worry about that)