-
Notifications
You must be signed in to change notification settings - Fork 23.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
virt: chokes on define/create #34559
Comments
Files identified in the description: If these files are inaccurate, please update the |
@coaxial Thanks for reporting this issue. Could you please try without specifying needs_info |
I can confirm that it happens with |
@coaxial This issue is waiting for your response. Please respond or the issue will be closed. |
@Akasurde yes that works |
Using |
Tried to address this and other issues in #41622 |
* autostart cannot be used with command=define autostart cannot be used with command=define. If it's used with state, it'll be silently ignored. #41592 * guest name should not be used with xml When both ```name``` and ```xml``` are specified, there might be a mismatch of domain names in ```name``` and inside ```xml```. * Improved error handling and param deps for autostart-only tasks. Standalone autostart tasks depend on ```name``` and need the domain to be present. * Added handling of errors thrown by libvirt * Updates to documentstion and examples * Removed required flag from name. Added description on some option combinations. Added a few examples. * lint issues * docs: note that name is optional * Removing required from documentation of name parameter * extra text to make clearer when name is required * When defining a domain with xml, its name is taken directly from the xml definition. This reverts commit 4ac14a6.
* autostart cannot be used with command=define autostart cannot be used with command=define. If it's used with state, it'll be silently ignored. ansible#41592 * guest name should not be used with xml When both ```name``` and ```xml``` are specified, there might be a mismatch of domain names in ```name``` and inside ```xml```. * Improved error handling and param deps for autostart-only tasks. Standalone autostart tasks depend on ```name``` and need the domain to be present. * Added handling of errors thrown by libvirt * Updates to documentstion and examples * Removed required flag from name. Added description on some option combinations. Added a few examples. * lint issues * docs: note that name is optional * Removing required from documentation of name parameter * extra text to make clearer when name is required * When defining a domain with xml, its name is taken directly from the xml definition. This reverts commit 4ac14a6.
* autostart cannot be used with command=define autostart cannot be used with command=define. If it's used with state, it'll be silently ignored. ansible#41592 * guest name should not be used with xml When both ```name``` and ```xml``` are specified, there might be a mismatch of domain names in ```name``` and inside ```xml```. * Improved error handling and param deps for autostart-only tasks. Standalone autostart tasks depend on ```name``` and need the domain to be present. * Added handling of errors thrown by libvirt * Updates to documentstion and examples * Removed required flag from name. Added description on some option combinations. Added a few examples. * lint issues * docs: note that name is optional * Removing required from documentation of name parameter * extra text to make clearer when name is required * When defining a domain with xml, its name is taken directly from the xml definition. This reverts commit 4ac14a6.
ISSUE TYPE
COMPONENT NAME
virt
ANSIBLE VERSION
CONFIGURATION
OS / ENVIRONMENT
Ubuntu 17.10 targetting Ubuntu 17.10 host
SUMMARY
The
virt
module demands aname
argument be passed, even when usingcreate
ordefine
actions. If none is passed, it errors saying it's required. If one is passed, and the domain doesn't exist (i.e. you want to define or create it), then it errors too saying it can't find the domain . It is odd that a domain name would be required by the virt module forcreate
ordefine
, becausevirsh {create,define}
only expects the path to an XML file. The XML file contains the domain name.I should add that running
virsh create mydomain.xml
andvirsh define mydoamin.xml
on the command line on the target machine works perfectly well.STEPS TO REPRODUCE
EXPECTED RESULTS
OK
ACTUAL RESULTS
The text was updated successfully, but these errors were encountered: