diff options
author | Richard Jones <rjones@redhat.com> | 2010-08-23 22:58:51 +0100 |
---|---|---|
committer | Richard Jones <rjones@redhat.com> | 2010-08-26 22:49:50 +0100 |
commit | dcb4097d78eae4f71fbe7d119d122bc15bb7da57 (patch) | |
tree | 46f1ebb6d73e426bbd14778913a950e7bfee78b6 | |
parent | 97ebfc7314b162fd8d464c764b3299c5230d2afc (diff) | |
download | libguestfs-dcb4097d78eae4f71fbe7d119d122bc15bb7da57.tar.gz libguestfs-dcb4097d78eae4f71fbe7d119d122bc15bb7da57.tar.xz libguestfs-dcb4097d78eae4f71fbe7d119d122bc15bb7da57.zip |
Don't print debug messages when not in verbose mode.
Don't print them because no one's listening ...
(cherry picked from commit 5c1346dae72064f7fd9c2afe5517afc6f050cd9a)
-rwxr-xr-x | appliance/init | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/appliance/init b/appliance/init index b8133caf..6aeea0c3 100755 --- a/appliance/init +++ b/appliance/init @@ -69,21 +69,23 @@ for f in /sys/block/vd*/queue/rotational; do echo 1 > $f; done # http://kbase.redhat.com/faq/docs/DOC-5428 for f in /sys/block/[hsv]d*/queue/scheduler; do echo noop > $f; done -# Keep these to enhance the usefulness of debug output. -ls -l /dev -cat /proc/mounts -lvm pvs -lvm vgs -lvm lvs -ifconfig -netstat -rn -lsmod -#hwclock -r -date -#ping -n -v -c 5 10.0.2.2 -#ping -n -v -c 5 10.0.2.4 - -echo -n "uptime: "; cat /proc/uptime +# These are useful when debugging. +if grep -sq guestfs_verbose=1 /proc/cmdline; then + ls -l /dev + cat /proc/mounts + lvm pvs + lvm vgs + lvm lvs + ifconfig + netstat -rn + lsmod + #hwclock -r + date + #ping -n -v -c 5 10.0.2.2 + #ping -n -v -c 5 10.0.2.4 + + echo -n "uptime: "; cat /proc/uptime +fi if ! grep -sq guestfs_rescue=1 /proc/cmdline; then exec guestfsd -f |