Bug 873582

Summary: The usage of manual doc and error message about 'sparse' should be consistent in virt-install
Product: Red Hat Enterprise Linux 6 Reporter: Cui Lei <lcui>
Component: python-virtinstAssignee: virt-mgr-maint
Status: CLOSED WONTFIX QA Contact: Virtualization Bugs <virt-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.4CC: cwei, dallan, gscrivan, hyao, jwu, mjenner, mzhan, tzheng
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1210572 (view as bug list) Environment:
Last Closed: 2014-01-28 17:08:00 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:
Bug Depends On:    
Bug Blocks: 1210572    

Description Cui Lei 2012-11-06 08:54:43 UTC
Description
The usage of manual doc and error message about 'sparse' are different in virt-install
For the usage about 'sparse' of manual doc in virt-install:
...
         sparse
             whether to skip fully allocating newly created storage. Value is ’true’ or ’false’. Default is ’true’ (do not fully allocate).
...
But when use '--nonsparse' with '--disk' parameters,
Error message would be pop up as:
ERROR    Cannot mix --file, --nonsparse, or --file-size with --disk options. Use --disk PATH[,size=SIZE][,sparse=yes|no]

The two usages should be consistent, sparse=yes|no or sparse=true|false.

Version
python-virtinst-0.600.0-12.el6.noarch
libvirt-0.10.2-7.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Check manual doc of virt-install about sparse, check the usage explanation.
2. Use "--nonsparse" with "--disk" at the same time
virt-install -n demo2 -r 512 -l http://tree.englab.nay.redhat.com/pub/rhel/released/RHEL-6/6.3/Server/x86_64/os/ --disk path=/var/lib/libvirt/images/demo2.img,size=5 --nonsparse
check the error message.
3. Compare the usage of manual doc and error message about 'sparse'
    
Actual results:
The usage were inconsistent,
In manual doc, which should used as "--disk ...,sparse=false,..."
But in error message, which hint Use "...--disk PATH[,size=SIZE][,sparse=yes|no]"

Expected results:
The usage should be consistent

Additional info:
Both of the usage "sparse=no" and "sparse=false" did not work.
There is a bug for this issue:https://bugzilla.redhat.com/show_bug.cgi?id=873545