Closed fmbiete closed 9 years ago
Thats somewhat strange. The documentation for the Xenserver API just mention there are contructors (create
) and desctructors (destroy
) methods for each class but it does not mention what are the required attributes.
When playing with the api i've found this as a required attribute.
If you take a look at the old api at fog/fog
you will see its required too (https://github.com/fog/fog/blob/master/lib/fog/xenserver/requests/compute/create_server.rb#L30-L31).
Hope this clarifies it to you.
@fmbiete check if XenCenter does not automatically sets affinity to some machine on the pool, as @plribeiro3000 its a required one.
No, XenCenter leaves affinity undefined by default. At least in pool environments.
In a pool when you set the affinity for a vm, that vm will appear under the host even when halted. It's a bit tricky when the host is shutdown for maintenance.
Looking at XenCenter code doesn't seem mandatory: https://github.com/xenserver/xenadmin/blob/master/XenModel/Actions/VM/CreateVMAction.cs#L150
Tomorrow will make more testing and let you know
Hi,
Why is affinity required?
In a XenServer pool, from XenCenter, I can create VM without setting the affinity.