Make one copy of grenade log files
Change 709f2349 removed the blanked 'rm' of grenade log files, but
that leaves behind several confusing entries in the final log output;
e.g [1].
---
grenade.sh.log.2014-06-16-014311
grenade.sh.log.2014-06-16-014311.2014-06-16-014311.summary
grenade.sh.log.summary
grenade.sh.txt
---
grenade.sh.txt is greande.sh.log renamed, which was a symlink to the
time-stampped file, which is no longer removed. The summary files are
also duplicated and not directly visible because they do not have a
.log extension.
This change just keeps the grenade log and summary files. It renames
the summary so it can be viewed, and removes the unnecessary files.
It also puts grenade's localrc in the top-level directory with the
logs, renamed to grenade_localrc
[1] http://logs.openstack.org/83/98283/2/gate/gate-grenade-dsvm/8ba1473/logs/
Change-Id: I932ee1583f04756579abf63c792d336ae937f64d
This commit is contained in:
20
functions.sh
20
functions.sh
@@ -535,7 +535,8 @@ function cleanup_host {
|
||||
|
||||
# copy devstack log files
|
||||
if [ -d $BASE/old ]; then
|
||||
sudo mkdir -p $BASE/logs/old $BASE/logs/new $BASE/logs/grenade
|
||||
sudo mkdir -p $BASE/logs/old $BASE/logs/new
|
||||
|
||||
# copy all log files, but note that devstack creates a shortened
|
||||
# symlink without timestamp (foo.log -> foo.2014-01-01-000000.log)
|
||||
# for each log to latest log. Thus we just copy the symlinks to
|
||||
@@ -545,7 +546,22 @@ function cleanup_host {
|
||||
sudo cp $BASE/old/devstacklog.txt $BASE/logs/old/
|
||||
sudo cp $BASE/old/devstack/localrc $BASE/logs/old/localrc.txt
|
||||
sudo cp $BASE/old/tempest/etc/tempest.conf $BASE/logs/old/tempest_conf.txt
|
||||
sudo cp $BASE/new/grenade/localrc $BASE/logs/grenade/localrc.txt
|
||||
|
||||
# grenade logs
|
||||
sudo cp $BASE/new/grenade/localrc $BASE/logs/grenade_localrc.txt
|
||||
# grenade logs directly and uses similar timestampped files to
|
||||
# devstack. So temporarily copy out & rename the latest log
|
||||
# files from the short-symlinks into grenade/, clean-up left
|
||||
# over time-stampped files and put the interesting logs back at
|
||||
# top-level for easy access
|
||||
sudo mkdir -p $BASE/logs/grenade
|
||||
sudo cp $BASE/logs/grenade.sh.log $BASE/logs/grenade/
|
||||
sudo cp $BASE/logs/grenade.sh.log.summary \
|
||||
$BASE/logs/grenade/grenade.sh.summary.log
|
||||
sudo rm $BASE/logs/grenade.sh.*
|
||||
sudo mv $BASE/logs/grenade/*.log $BASE/logs
|
||||
sudo rm -rf $BASE/logs/grenade
|
||||
|
||||
NEWLOGTARGET=$BASE/logs/new
|
||||
else
|
||||
NEWLOGTARGET=$BASE/logs
|
||||
|
||||
Reference in New Issue
Block a user