Merge "xenapi: Fix console rotate script"
This commit is contained in:
commit
7f45bacc53
@ -44,6 +44,8 @@ domains=$($list_domains | sed '/^id*/d' | sed 's/|.*|.*$//g' | xargs)
|
||||
for i in $domains; do
|
||||
log="${log_file_base}$i"
|
||||
tmp="${tmp_file_base}$i"
|
||||
|
||||
if [ -e "$tmp" ]; then
|
||||
size=$(stat -c%s "$tmp")
|
||||
|
||||
# Trim the log if required
|
||||
@ -52,6 +54,7 @@ for i in $domains; do
|
||||
else
|
||||
mv $tmp $log || true
|
||||
fi
|
||||
fi
|
||||
|
||||
# Notify xen that it needs to reload the file
|
||||
xenstore-write /local/logconsole/$i $log
|
||||
|
Loading…
Reference in New Issue
Block a user