Placement modes
Placements for compute nodes have two modes: hard and soft. The hard mode is the default one. To better understand how these modes work, let's consider an example when a system administrator creates placements and assigns them to images, flavors, and nodes as follows:
In the figure above:
- Placement1 in the hard mode is assigned to the Win2k19 image and the nodes Node1, Node2, and Node4.
- Placement2 in the soft mode is assigned to the Win10 image and the nodes Node5, Node6, and Node7.
- Placement3 in the soft mode is assigned to the Medium flavor and the nodes Node4, Node6, and Node7.
- Placement4 in the hard mode is assigned to the Large flavor and the nodes Node1, Node3, Node5, and Node6.
- The Linux image, the Small flavor, and node Node8 have no placements assigned.
When a user starts creating virtual machines, they inherit placements from the selected images and flavors. Depending on its placement mode, a virtual machine can be placed on different nodes.
Virtual machines with the hard placement mode
With the hard placement mode, a virtual machine is placed on a node that has exactly the same placements as the virtual machine.
In the figure above:
- VM1 is created from the Win2k19 image with Placement1 and the Large flavor with Placement4. The VM inherits Placement1 and Placement4 in the hard mode. VM1 can be placed only on Node1 because only this node has both Placement1 and Placement4 assigned.
- VM2 is created from the Win2k19 image with Placement1 and the Small flavor without placements. The VM inherits Placement1 in the hard mode. VM2 can be placed only on Node2 because only this node has single Placement1 assigned.
- VM3 is created from the Linux image without placements and with the Large flavor with Placement4. The VM inherits Placement4 in the hard mode. VM3 can be placed only on Node3 because only this node has single Placement4 assigned.
Virtual machines with the soft placement mode
With the soft placement mode, a VM is placed on a node that has at least the same placements as the VM.
In the figure above:
- VM4 is created from the Win10 image with Placement2 and the Medium flavor with Placement3. The VM inherits Placement2 and Placement3 in the soft mode. VM4 can be placed on Node6 and Node7 because these nodes have both Placement2 and Placement3 assigned.
- VM5 is created from the Win10 image with Placement2 and the Small flavor without placements. The VM inherits Placement2 in the soft mode. VM5 can be placed Node5, Node6, and Node7 because all of these nodes have Placement2 assigned.
- VM6 is created from the Linux image without placements and with the Medium flavor with Placement3. The VM inherits Placement3 in the soft mode. VM6 can be placed on Node4, Node6, and Node7 because all of these nodes have Placement3 assigned.
Virtual machines with both placement modes and without placements
A VM can have placements in the both soft and hard modes. In this case, VM placements use the soft mode, that is a VM is placed on a node that has at least the same placements as the VM.
When a VM has no placements assigned, it can be placed either on a node with placements in the soft mode or on a node that is not added to any placements
In the figure above:
- VM7 is created from the Win2k19 image with Placement1 and the Medium flavor with Placement3. The VM inherits Placement1 in the hard mode and Placement3 in the soft mode. VM7 can be placed on Node4 because only this node has both Placement1 and Placement3 assigned.
- VM8 is created from the Win10 image with Placement2 and the Large flavor with Placement4. The VM inherits Placement4 in the hard mode and Placement2 in the soft mode. VM7 can be placed on Node5 and Node6 because these nodes have both Placement2 and Placement4 assigned.
- VM9 is created from the Linux image without placements and the Small flavor without placements. The VM inherits no placements. VM6 can be placed on Node7 because this node has placements in the soft mode. Also, VM6 can be placed on Node8 because this node has no placements assigned.