A huge part of the logs is irrelevant bash aliases captured by the
openstack client timing wrapper from the run of "openstack complete",
which is only helpful on interactive systems where you'll interact
with the command line. Call it directly to avoid capturing the logs.
While we're here, turn off tracing inside the oscwrap function, which
is called frequently. It's not useful for debugging.
Change-Id: I1cb5399fe7ee6f0e547a9cfff70396aa2007632e
... | ... |
@@ -2354,6 +2354,10 @@ function time_stop { |
2354 | 2354 |
} |
2355 | 2355 |
|
2356 | 2356 |
function oscwrap { |
2357 |
+ local xtrace |
|
2358 |
+ xtrace=$(set +o | grep xtrace) |
|
2359 |
+ set +o xtrace |
|
2360 |
+ |
|
2357 | 2361 |
local out |
2358 | 2362 |
local rc |
2359 | 2363 |
local start |
... | ... |
@@ -2368,6 +2372,7 @@ function oscwrap { |
2368 | 2368 |
echo $((end - start)) >> $OSCWRAP_TIMER_FILE |
2369 | 2369 |
|
2370 | 2370 |
echo "$out" |
2371 |
+ $xtrace |
|
2371 | 2372 |
return $rc |
2372 | 2373 |
} |
2373 | 2374 |
|
... | ... |
@@ -1475,7 +1475,10 @@ fi |
1475 | 1475 |
# =============== |
1476 | 1476 |
|
1477 | 1477 |
# Prepare bash completion for OSC |
1478 |
-openstack complete | sudo tee /etc/bash_completion.d/osc.bash_completion > /dev/null |
|
1478 |
+# Note we use "command" to avoid the timing wrapper |
|
1479 |
+# which isn't relevant here and floods logs |
|
1480 |
+command openstack complete \ |
|
1481 |
+ | sudo tee /etc/bash_completion.d/osc.bash_completion > /dev/null |
|
1479 | 1482 |
|
1480 | 1483 |
# If cinder is configured, set global_filter for PV devices |
1481 | 1484 |
if is_service_enabled cinder; then |