History | View | Annotate | Download (392.2 kB)
Rename OpStartupInstance and LUStartupInstance
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: René Nussbaumer <rn@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
Rename OpAddNode and LUAddNode
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
Rename OpNodeEvacuationStrategy and LUNodeEvacuationStrategy
Rename OpMigrateNode and LUMigrateNode
Rename OpModifyNodeStorage and LUModifyNodeStorage
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
Rename OpPowercycleNode and LUPowercycleNode
Rename OpQueryNodes and LUQueryNodes
Rename OpMigrateInstance and LUMigrateInstance
Rename OpMoveInstance and LUMoveInstance
Rename OpQueryInstances and LUQueryInstances
Rename OpQueryInstanceData and LUQueryInstanceData
Rename OpRebootInstance and LURebootInstance
Rename OpRecreateInstanceDisks and LURecreateInstanceDisks
Rename OpReinstallInstance and LUReinstallInstance
Rename OpRemoveInstance and LURemoveInstance
Rename OpRenameInstance and LURenameInstance
Rename OpReplaceDisks and LUReplaceDisks
Rename OpSetInstanceParams and LUSetInstanceParams
Rename OpShutdownInstance and LUShutdownInstance
Rename OpVerifyDisks and LUVerifyDisks
Rename OpAddGroup and LUAddGroup
Rename OpAssignGroupNodes and LUAssignGroupNodes
Rename OpQueryGroups and LUQueryGroups
Rename OpRemoveGroup and LURemoveGroup
Rename OpRenameGroup and LURenameGroup
Rename OpSetGroupParams and LUSetGroupParams
Rename OpActivateInstanceDisks and LUActivateInstanceDisks
Rename OpConnectConsole and LUConnectConsole
Rename OpCreateInstance and LUCreateInstance
Rename OpDeactivateInstanceDisks and LUDeactivateInstanceDisks
Rename OpFailoverInstance and LUFailoverInstance
Rename OpGrowDisk and LUGrowDisk
Rename OpPrepareExport and LUPrepareExport
Rename OpQueryExports and LUQueryExports
Rename OpRemoveExport and LURemoveExport
Rename OpQueryConfigValues and LUQueryConfigValues
Rename OpDestroyCluster and LUDestroyCluster
Rename OpPostInitCluster and LUPostInitCluster
Rename OpQueryClusterInfo and LUQueryClusterInfo
Rename OpRedistributeConfig and LURedistributeConfig
Rename OpRenameCluster and LURenameCluster
Rename OpRepairDiskSizes and LURepairDiskSizes
Rename OpSetClusterParams and LUSetClusterParams
Rename OpVerifyCluster and LUVerifyCluster
Rename OpExportInstance and LUExportInstance
Fix bug introduced by f5677ab
Commit f5677ab added the _VerifyOob functionality, but there are twoissues with this function:
- a real bug, as objects.Node doesn't have a 'master' attribute- a design bug, as we need to verify the OOB programs not only on...
Fix growing of DRBD disks
Patch 03941a26 made disk growth VG-aware, but the code has a bug: itonly works for LD_LV disks, and not LD_DRBD. To fix it, we add ageneric function to compute the per-VG growth requirements, and switchto using that instead of manual build....
List node parameters (if any) in gnt-node info
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Iustin Pop <iustin@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
List node parameters in gnt-cluster info output
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
gnt-group modify: ndparams not correctly updated
ndparams should delete keys which are reset to default
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Adeodato Simo <dato@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Pause/Resume sync accordingly before wiping disk
Add OpAssignGroupNodes and LUAssignGroupNodes
This operation allows to assign nodes to a group, verifying whetherthe change would leave any mirrored instance split between differentnode groups.
Signed-off-by: Adeodato Simo <dato@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
Cluster verify warns if there are split instances
Emit a warning for each instance with a mirrored disk template that hasits primary and secondary nodes living in different node groups.
IAllocator: fix breakage for non-vm_capable nodes
Currently, the IAllocator doesn't know that non-vm_capable nodesshould not be queried for hypervisor/instance information.
This patch updates the node data computation to generate basic info,but not the runtime data for such nodes. Furthermore, the...
Use new console information in hypervisor abstraction
This makes use of the new way of returning console information from themaster daemon. Unittests are included.
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
Introduce verbose opcode result for console
With this patch OpConnectConsole will no longer just return a commandwith arguments, but rather a detailed description about how to connectto an instance's console. Unittests for some parts are included. Another...
Support query of node field 'powered'
This field is based on OOB support and is only available if there's oobsupport for that node.
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
cmdlib.py: convert LUQueryGroups to query2
cmdlib.py: move _GetQueryImplementation to end of file
_GetQueryImplementation() uses _QUERY_IMPL, which list all query typeimplementations. By moving it to the end of the file, we ensure all suchclasses are defined by the time we list them.
Signed-off-by: Adeodato Simo <dato@google.com>...
out of band verification in gnt-cluster verify
This adds the verify tests for out of band management
Migrate code verifying opcode parameters to base class
This allows the function to be used in other places as well.An optional parameter is added to control whether defaultvalues should be set. Unittests are added, providing fullcoverage.
Signed-off-by: Michael Hanselmann <hansmi@google.com>...
cmdlib: Remove opcode parameters
Remove the parameter definitions and use those from the opcode classesinstead. Small style changes are also made (empty lines, wrapping).
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
LUInstanceRename: log result of name resolving
While the LU does return the final name, it's useful to log the actualDNS resolving process (input and output) in order to help with thediagnose of failures.
The patch also fixes the docstring of the Exec() function....
query: Add wrapper for creating response object
It'll be used for querying locks.
Move QueryFields to query module
Also replace “sorted” with “utils.NiceSort” now that it supports a keyfunction.
Merge branch 'devel-2.3'
Conflicts: NEWS: Trivial
Merge branch 'stable-2.3' into devel-2.3
LUSetNodeParams: Add support for powered state
LUSetNodeParams/LUOobCommand respect offline/powered
This patch makes sure we cross verify the state the node isin with our view:
power off -> Node has to be set offlinemodify -O no -> Node has to be powered
Signed-off-by: René Nussbaumer <rn@google.com>...
Conflicts: lib/cmdlib.py: Trivial qa/ganeti-qa.py: Trivial...
ShutdownInstanceDisks: accept offline secondaries
For secondary node that is offline, we should not consider that thedisk shutdown has failed, as it can never succeed under this clusterstate and (by virtue of the fact that the secondary node is offline)...
LUAddNode: default ndparams to empty dict when not provided
Fix gnt-cluster verify with diskless instances
`gnt-cluster verify` was failing with KeyError if there was anydiskless instance in the cluster. This was because _CollectDiskInfo()was not including these instances in the returned dictionary, but theywere expected to be present in LUVerifyCluster.Exec()....
Fix N+1 error message
The error contained a typo and is slightly cumbersome. It changes from:
- ERROR: node a: not enough memory on to accommodate failovers should peer node b fail
to:
- ERROR: node a: not enough memory to accomodate instance failovers should node...
Rename (Op|LU)OutOfBand to (Op|LU)OobCommand
Do the expanding of the node name in ExpandNames
iallocator: Export node group allocation policy
Signed-off-by: Balazs Lecz <leczb@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
Set powered to True for added nodes
Set recorded powered state for OOB calls
Add the "alloc_policy" attribute to node groups
This can be set at group creation time and via OpSetGroupParams. The defaultis "preferred", and existing node groups from previous Ganeti version willget the attribute set to this value.
Add modification of node groups (OpCode/LU/CLI)
With this commit, only modification of the "ndparams" attribute issupported.
Signed-off-by: Adeodato Simo <dato@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Introduce OpAddGroup.ndparams and expose in CLI
Fix sorting bug in LUQueryGroups
In LUQueryGroups.Exec(), NiceSort was being applied to group UUIDs, andnot to group names. We use a temporary name to UUID map to sort the listof UUIDs by group name instead.
cmdlib: Sort list of fields for QueryFields
objects: Add custom de-/serializing code for query responses
… and use them in cmdlib.
Add gnt-cluster modify --master-netdev
Although this might be a dangerous operation, it's still better to allowit rather than requiring a hand-edit of the config file, should it benecessary.
Signed-off-by: Guido Trotter <ultrotter@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
cmdlib: Convert instance query to new infrastructure
Fix disk status verification in LUClusterVerify
Commit b8d26c6 added disk status verification, but it has two(different) bugs for not healthy nodes.
For offline nodes, we don't add at all the disk status to theinstance/node dict, with the result that the instance is not present in...
Check payload of OOB execution
Replace GetOobProgram by GetNdParams
This was due to a older review which used GetOobProgram but thenchanged to GetNdParams. Forgot to adjust this in the LU before.
Allow rename of instance to same name
This basically is a no-op in ganeti, but forces the execution of theos-specific rename scripts.
Node query: maintain order as requested
If the client requests certain names, their order should be maintained.This is already done for instance queries. Moving this part into aseparate function allows sharing code.
cmdlib: Fix prototype for _QueryBase.DeclareLocks
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: Adeodato Simo <dato@google.com>
Group operations: OpCode and LU for renaming a group
Group operations: OpCode and LU for removing a group
Group operations: OpCode and LU for adding a group
Expose new node group attributes in CLI and RAPI
Adding new Logical Unit for OOB
cmdlib: Don't sort list of nodes if names are given
This makes _GetWantedNodes consistent wit _GetWantedInstances.
Make rpc.call_lv_list() VG-aware
Changes to backend.GetVolumeList():- now accepts a list of VGs instead of one VG- returns LV names in the form "vg_name/lv_name"
Corresponding changes are done in: VerifyDisks, VerifyNode,LUCreateInstance (for both disk creation and adoption cases)...