Bug 839930

Summary: There is no message if debug level number is out of scope when run a virsh command with -d option
Product: Red Hat Enterprise Linux 6 Reporter: Geyang Kong <gkong>
Component: libvirtAssignee: Ján Tomko <jtomko>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: low Docs Contact:
Priority: low    
Version: 6.3CC: acathrow, dallan, dyasny, dyuan, gsun, jwu, mjenner, mzhan, veillard, yupzhang, zhpeng, zpeng
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: libvirt-0.10.0-0rc0.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-21 07:19:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Geyang Kong 2012-07-13 08:48:51 UTC
Description of problem:
  There is no message if debug level number is out of scope when run a virsh command with -d option.

Version-Release number of selected component (if applicable):
libvirt-0.9.10-21.el6_3.1.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Make sure there is a storage pool.
2. Run #virsh -d 10000 pool-start $poolname.
3. Run #virsh -d -10000 pool-start $poolname.

Actual results:
1. Command 2 and 3 can work normally without any messages.

Expected results:
1. At least, there should be some warning messages said the debug level is out of scope. Normally, debug level should be in 0-4.

Additional info:
1. Steps in this bug is just a example, this issue can be reproduced by all virsh commands with -d option.

Comment 2 Ján Tomko 2012-07-26 13:37:26 UTC
Upstream patch proposed
https://www.redhat.com/archives/libvir-list/2012-July/msg01480.html

Comment 3 Ján Tomko 2012-07-27 09:39:21 UTC
Fixed by commit 4fedf388f68b49dd1a8334f75272c3bfddd6032c
    virsh: check if specified debug level is in range

Comment 5 zhpeng 2012-08-06 04:02:55 UTC
Test it with libvirt-0.10.0-0rc0.el6

# virsh -d 1000 pool-destroy default
error: ignoring debug level 1000 out of range [0-4]
Pool default destroyed

So it's verified

Comment 6 errata-xmlrpc 2013-02-21 07:19:22 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2013-0276.html