File: placement_group.rst

package info (click to toggle)
python-softlayer 6.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,508 kB
  • sloc: python: 57,195; makefile: 133; xml: 97; sh: 59
file content (132 lines) | stat: -rw-r--r-- 6,390 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
.. _vs_placement_group_user_docs:

Working with Placement Groups
=============================
A `Placement Group <https://cloud.ibm.com/docs/vsi/vsi_placegroup.html#placement-groups>`_  is a way to control which physical servers your virtual servers get provisioned onto. 

To create a  `Virtual_PlacementGroup <https://softlayer.github.io/reference/services/SoftLayer_Virtual_PlacementGroup/>`_ object, you will need to know the following:

- backendRouterId,  from `getAvailableRouters <https://softlayer.github.io/reference/services/SoftLayer_Virtual_PlacementGroup/getAvailableRouters>`_
- ruleId, from `getAllObjects <https://softlayer.github.io/reference/services/SoftLayer_Virtual_PlacementGroup_Rule/getAllObjects/>`_
- name, can be any string, but most be unique on your account

Once a placement group is created, you can create new virtual servers in that group. Existing VSIs cannot be moved into a placement group. When ordering a VSI in a placement group, make sure to set the `placementGroupId <https://softlayer.github.io/reference/datatypes/SoftLayer_Virtual_Guest/#placementGroupId>`_ for each guest in your order. 

use the --placementgroup option with `vs create` to specify creating a VSI in a specific group.

::

    
    $ slcli  vs create -H testGroup001 -D test.com -f  B1_1X2X25 -d mex01 -o DEBIAN_LATEST --placementgroup testGroup

Placement groups can only be deleted once all the virtual guests in the group have been reclaimed.

.. _cli_vs_placementgroup_create:

vs placementgroup create
------------------------
This command will create a placement group. 

::

    $ slcli vs placementgroup create --name testGroup -b bcr02a.dal06 -r SPREAD

Options
^^^^^^^
--name TEXT                     Name for this new placement group.  [required]
-b, --backend_router TEXT       backendRouter, can be either the hostname or id.  [required]
-r, --rule TEXT            The keyName or Id of the rule to govern this placement group.  [required]


.. _cli_vs_placementgroup_create_options:

vs placementgroup create-options
--------------------------------
This command will print out the available routers and rule sets for use in creating a placement group.

::

    $ slcli vs placementgroup create-options
    :.................................................:
    :                Available Routers                :
    :..............:..............:...................:
    :  Datacenter  :   Hostname   : Backend Router Id :
    :..............:..............:...................:
    : Washington 1 : bcr01.wdc01  :       16358       :
    :   Tokyo 5    : bcr01a.tok05 :      1587015      :
    :..............:..............:...................:
    :..............:
    :    Rules     :
    :....:.........:
    : Id : KeyName :
    :....:.........:
    : 1  :  SPREAD :
    :....:.........:

.. _cli_vs_placementgroup_delete:

vs placementgroup delete
------------------------
This command will remove a placement group. The placement group needs to be empty for this command to succeed.

Options
^^^^^^^
--purge     Delete all guests in this placement group. The group itself can be deleted once all VMs are fully reclaimed

::

    $ slcli vs placementgroup delete testGroup

You can use the flag --purge to auto-cancel all VSIs in a placement group. You will still need to wait for them to be reclaimed before proceeding to delete the group itself.

::

    $ slcli vs placementgroup delete testGroup --purge
        You are about to delete the following guests!
        issues10691547768562.test.com, issues10691547768572.test.com, issues10691547768552.test.com, issues10691548718280.test.com
        This action will cancel all guests! Continue? [y/N]: y
        Deleting issues10691547768562.test.com...
        Deleting issues10691547768572.test.com...
        Deleting issues10691547768552.test.com...
        Deleting issues10691548718280.test.com...


.. _cli_vs_placementgroup_list:

vs placementgroup list
----------------------
This command will list all placement groups on your account. 

::

    $ slcli vs placementgroup list
    :..........................................................................................:
    :                                     Placement Groups                                     :
    :.......:...................:................:........:........:...........................:
    :   Id  :        Name       : Backend Router :  Rule  : Guests :          Created          :
    :.......:...................:................:........:........:...........................:
    : 31741 :       fotest      :  bcr01a.tor01  : SPREAD :   1    : 2018-11-22T14:36:10-06:00 :
    : 64535 :     testGroup     :  bcr01a.mex01  : SPREAD :   3    : 2019-01-17T14:36:42-06:00 :
    :.......:...................:................:........:........:...........................:

.. _cli_vs_placementgroup_detail:

vs placementgroup detail
------------------------
This command will provide some detailed information about a specific placement group

::

    $ slcli vs placementgroup detail testGroup
    :.......:............:................:........:...........................:
    :   Id  :     Name   : Backend Router :  Rule  :          Created          :
    :.......:............:................:........:...........................:
    : 64535 : testGroup  :  bcr01a.mex01  : SPREAD : 2019-01-17T14:36:42-06:00 :
    :.......:............:................:........:...........................:
    :..........:........................:...............:..............:.....:........:...........................:.............:
    :    Id    :           FQDN         :   Primary IP  :  Backend IP  : CPU : Memory :        Provisioned        : Transaction :
    :..........:........................:...............:..............:.....:........:...........................:.............:
    : 69134895 : testGroup62.test.com   : 169.57.70.166 : 10.131.11.32 :  1  :  1024  : 2019-01-17T17:44:50-06:00 :      -      :
    : 69134901 : testGroup72.test.com   : 169.57.70.184 : 10.131.11.59 :  1  :  1024  : 2019-01-17T17:44:53-06:00 :      -      :
    : 69134887 : testGroup52.test.com   : 169.57.70.187 : 10.131.11.25 :  1  :  1024  : 2019-01-17T17:44:43-06:00 :      -      :
    :..........:........................:...............:..............:.....:........:...........................:.............: