RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1368753 - manual about the --validate flag of create and define commands was not updated
Summary: manual about the --validate flag of create and define commands was not updated
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt
Version: 7.3
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: beta
: ---
Assignee: Erik Skultety
QA Contact: Yanqiu Zhang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-08-21 04:22 UTC by Lili Zhu
Modified: 2018-04-10 10:36 UTC (History)
6 users (show)

Fixed In Version: libvirt-3.8.0-1.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-04-10 10:36:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2018:0704 0 normal SHIPPED_LIVE libvirt bug fix and enhancement update 2018-04-10 15:57:35 UTC

Description Lili Zhu 2016-08-21 04:22:04 UTC
Description of problem:

manual about the --validate flag  of create and define commands was not updated

How producible
100%

Version:
Libvirt-2.0.0-4.el7.x86_64

Steps to Reproduce:
1. # man virsh

Actual results:
1. create FILE [--console] [--paused] [--autodestroy] [--pass-fds N,M,...]
2. define FILE
          
Expected results:
manual should mention the --validate flag of create and define command and it's usability


Additional info:
Infomation about --validate can be shown in virsh create/define --help
1. #  virsh create --help
  NAME
    create - create a domain from an XML file

  SYNOPSIS
    create <file> [--console] [--paused] [--autodestroy] [--pass-fds <string>] [--validate]

  DESCRIPTION
    Create a domain.

  OPTIONS
    [--file] <string>  file containing an XML domain description
    --console        attach to console after creation
    --paused         leave the guest paused after creation
    --autodestroy    automatically destroy the guest when virsh disconnects
    --pass-fds <string>  pass file descriptors N,M,... to the guest
    --validate       validate the XML against the schema
2. # virsh define --help
  NAME
    define - define (but don't start) a domain from an XML file

  SYNOPSIS
    define <file> [--validate]

  DESCRIPTION
    Define a domain.

  OPTIONS
    [--file] <string>  file containing an XML domain description
    --validate       validate the XML against the schema

Comment 2 Erik Skultety 2017-09-08 12:54:53 UTC
fixed upstream by:

commit 11a47211b822d97d49557d17dcb2da50c54b819e
Author:     Erik Skultety <eskultet>
AuthorDate: Thu Sep 7 15:48:14 2017 +0200
Commit:     Erik Skultety <eskultet>
CommitDate: Fri Sep 8 14:33:04 2017 +0200

    virsh: man: Document the --validate option for create and define cmds
    
    Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1368753
    
    Signed-off-by: Erik Skultety <eskultet>
    Reviewed-by: Martin Kletzander <mkletzan>

Comment 4 Yanqiu Zhang 2017-10-11 03:22:42 UTC
Verify this bug with libvirt-3.8.0-1.el7.x86_64.

Steps:
# man virsh
...
       create FILE [--console] [--paused] [--autodestroy] [--pass-fds N,M,...] [--validate]
           Create a domain from an XML <file>. Optionally, --validate option can be passed to
           validate the format of the input XML file against an internal RNG schema (identical to
           using virt-xml-validate(1) tool). Domains created using this command are going to be
           either transient (temporary ones that will vanish once destroyed) or existing persistent
           domains that will run with one-time use configuration, leaving the persistent XML
           untouched (this can come handy during an automated testing of various configurations all
           based on the original XML).  See the Example section for usage demonstration.

           The domain will be paused if the --paused ...

           If --pass-fds is specified ...

           Example

            1) prepare a template from an existing domain (skip directly to 3a if writing
               one from scratch)

            # virsh dumpxml <domain> > domain.xml

            2) edit the template using an editor of your choice and:
               a) DO CHANGE! <name> and <uuid> (<uuid> can also be removed), or
               b) DON'T CHANGE! either <name> or <uuid>

            # $EDITOR domain.xml

            3) create a domain from domain.xml, depending on whether following 2a or 2b
               respectively:
               a) the domain is going to be transient
               b) an existing persistent domain will run with a modified one-time
                  configuration

            # virsh create domain.xml


       define FILE [--validate]
           Define a domain from an XML <file>. Optionally, the format of the input XML file can be
           validated against an internal RNG schema with --validate (identical to using
           virt-xml-validate(1) tool). The domain definition is registered but not started.  If
           domain is already running, the changes will take effect on the next boot.
...

Mark this bug as verified.

Comment 8 errata-xmlrpc 2018-04-10 10:36:45 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.

https://access.redhat.com/errata/RHEA-2018:0704


Note You need to log in before you can comment on or make changes to this bug.