summaryrefslogtreecommitdiffstats
path: root/docs/release/installation/bmdeploy.rst
blob: 43f0837074780c41e29cb67f15b7ad3f48433c9e (plain)
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
.. This work is licensed under a Creative Commons Attribution 4.0 International License.
.. http://creativecommons.org/licenses/by/4.0
.. (c) by Weidong Shao (HUAWEI) and Justin Chi (HUAWEI)

Installation on Bare Metal
==========================

Nodes Configuration (Bare Metal Deployment)
-------------------------------------------

The below file is the inventory template of deployment nodes:

"compass4nfv/deploy/conf/hardware_environment/huawei-pod1/dha.yml"

The "dha.yml" is a collectively name for "os-nosdn-nofeature-ha.yml
os-ocl-nofeature-ha.yml os-odl_l2-moon-ha.yml etc".

You can write your own IPMI IP/User/Password/Mac address/roles reference to it.

        - name -- Host name for deployment node after installation.

        - ipmiVer -- IPMI interface version for deployment node support. IPMI 1.0
          or IPMI 2.0 is available.

        - ipmiIP -- IPMI IP address for deployment node. Make sure it can access
          from Jumphost.

        - ipmiUser -- IPMI Username for deployment node.

        - ipmiPass -- IPMI Password for deployment node.

        - mac -- MAC Address of deployment node PXE NIC.

        - interfaces -- Host NIC renamed according to NIC MAC addresses when OS provisioning.

        - roles -- Components deployed.

**Set TYPE/FLAVOR and POWER TOOL**

E.g.
.. code-block:: yaml

    TYPE: baremetal
    FLAVOR: cluster
    POWER_TOOL: ipmitool

**Set ipmiUser/ipmiPass and ipmiVer**

E.g.

.. code-block:: yaml

    ipmiUser: USER
    ipmiPass: PASSWORD
    ipmiVer: '2.0'

**Assignment of different roles to servers**

E.g. Openstack only deployment roles setting

.. code-block:: yaml

    hosts:
      - name: host1
        mac: 'F8:4A:BF:55:A2:8D'
        interfaces:
           - eth1: 'F8:4A:BF:55:A2:8E'
        ipmiIp: 172.16.130.26
        roles:
          - controller
          - ha

      - name: host2
        mac: 'D8:49:0B:DA:5A:B7'
        interfaces:
          - eth1: 'D8:49:0B:DA:5A:B8'
        ipmiIp: 172.16.130.27
        roles:
          - compute

NOTE:
THE 'ha' role MUST BE SELECT WITH CONTROLLERS, EVEN THERE IS ONLY ONE CONTROLLER NODE.

E.g. Openstack and ceph deployment roles setting

.. code-block:: yaml

    hosts:
      - name: host1
        mac: 'F8:4A:BF:55:A2:8D'
        interfaces:
           - eth1: 'F8:4A:BF:55:A2:8E'
        ipmiIp: 172.16.130.26
        roles:
          - controller
          - ha
          - ceph-adm
          - ceph-mon

      - name: host2
        mac: 'D8:49:0B:DA:5A:B7'
        interfaces:
          - eth1: 'D8:49:0B:DA:5A:B8'
        ipmiIp: 172.16.130.27
        roles:
          - compute
          - ceph-osd

E.g. Openstack and ODL deployment roles setting

.. code-block:: yaml

    hosts:
      - name: host1
        mac: 'F8:4A:BF:55:A2:8D'
        interfaces:
           - eth1: 'F8:4A:BF:55:A2:8E'
        ipmiIp: 172.16.130.26
        roles:
          - controller
          - ha
          - odl

      - name: host2
        mac: 'D8:49:0B:DA:5A:B7'
        interfaces:
          - eth1: 'D8:49:0B:DA:5A:B8'
        ipmiIp: 172.16.130.27
        roles:
          - compute

E.g. Openstack and ONOS deployment roles setting

.. code-block:: yaml

    hosts:
      - name: host1
        mac: 'F8:4A:BF:55:A2:8D'
        interfaces:
           - eth1: 'F8:4A:BF:55:A2:8E'
        ipmiIp: 172.16.130.26
        roles:
          - controller
          - ha
          - onos

      - name: host2
        mac: 'D8:49:0B:DA:5A:B7'
        interfaces:
          - eth1: 'D8:49:0B:DA:5A:B8'
        ipmiIp: 172.16.130.27
        roles:
          - compute

Network Configuration (Bare Metal Deployment)
---------------------------------------------

Before deployment, there are some network configuration to be checked based
on your network topology.Compass4nfv network default configuration file is
"compass4nfv/deploy/conf/hardware_environment/huawei-pod1/network.yml".
This file is an example, you can customize by yourself according to specific network
environment.

In this network.yml, there are several config sections listed following(corresponed to the
ordre of the config file):

Provider Mapping
~~~~~~~~~~~~~~~~

        - name -- provider network name.

        - network -- default as physnet, do not change it.

        - interfaces -- the NIC or Bridge attached by the Network.

        - type -- the type of the NIC or Bridge(vlan for NIC and ovs for Bridge, either).

        - roles -- all the possible roles of the host machines which connected by this
          network(mostly put both controller and compute).

System Interface
~~~~~~~~~~~~~~~~

        - name -- Network name.

        - interfaces -- the NIC or Bridge attached by the Network.

        - vlan_tag -- if type is vlan, add this tag before 'type' tag.

        - type -- the type of the NIC or Bridge(vlan for NIC and ovs for Bridge, either).

        - roles -- all the possible roles of the host machines which connected by this
          network(mostly put both controller and compute).

IP Settings
~~~~~~~~~~~

        - name -- network name corresponding the the network name in System Interface section one by one.

        - ip_ranges -- ip addresses range provided for this network.

        - cidr -- the IPv4 address and its associated routing prefix and subnet mask�

        - gw -- need to add this line only if network is external.

        - roles -- all the possible roles of the host machines which connected by this
          network(mostly put both controller and compute).

Internal VIP(virtual or proxy IP)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

        - ip -- virtual or proxy ip address, must be in the same subnet with mgmt network
          but must not be in the range of mgmt network.

        - netmask -- the length of netmask

        - interface -- mostly mgmt.

Public VIP
~~~~~~~~~~

        - ip -- virtual or proxy ip address, must be in the same subnet with external
          network but must not be in the range of external network.

        - netmask -- the length of netmask

        - interface -- mostly external.

ONOS NIC
~~~~~~~~

        - the NIC for ONOS, if there is no ONOS configured, leave it unchanged.


Public Network
~~~~~~~~~~~~~~

        - enable -- must be True(if False, you need to set up provider network manually).

        - network -- leave it ext-net.

        - type -- the type of the ext-net above, such as flat or vlan.

        - segment_id -- when the type is vlan, this should be id of vlan.

        - subnet -- leave it ext-subnet.

        - provider_network -- leave it physnet.

        - router -- leave it router-ext.

        - enable_dhcp -- must be False.

        - no_gateway -- must be False.

        - external_gw -- same as gw in ip_settings.

        - floating_ip_cidr -- cidr for floating ip, see explanation in ip_settings.

        - floating_ip_start -- define range of floating ip with floating_ip_end(this
          defined range must not be included in ip range of external configured in
          ip_settings section).

        - floating_ip_end -- define range of floating ip with floating_ip_start.


**The following figure shows the default network configuration.**

.. code-block:: console


      +--+                          +--+     +--+
      |  |                          |  |     |  |
      |  |      +------------+      |  |     |  |
      |  +------+  Jumphost  +------+  |     |  |
      |  |      +------+-----+      |  |     |  |
      |  |             |            |  |     |  |
      |  |             +------------+  +-----+  |
      |  |                          |  |     |  |
      |  |      +------------+      |  |     |  |
      |  +------+    host1   +------+  |     |  |
      |  |      +------+-----+      |  |     |  |
      |  |             |            |  |     |  |
      |  |             +------------+  +-----+  |
      |  |                          |  |     |  |
      |  |      +------------+      |  |     |  |
      |  +------+    host2   +------+  |     |  |
      |  |      +------+-----+      |  |     |  |
      |  |             |            |  |     |  |
      |  |             +------------+  +-----+  |
      |  |                          |  |     |  |
      |  |      +------------+      |  |     |  |
      |  +------+    host3   +------+  |     |  |
      |  |      +------+-----+      |  |     |  |
      |  |             |            |  |     |  |
      |  |             +------------+  +-----+  |
      |  |                          |  |     |  |
      |  |                          |  |     |  |
      +-++                          ++-+     +-++
        ^                            ^         ^
        |                            |         |
        |                            |         |
      +-+-------------------------+  |         |
      |      External Network     |  |         |
      +---------------------------+  |         |
             +-----------------------+---+     |
             |       IPMI Network        |     |
             +---------------------------+     |
                     +-------------------------+-+
                     | PXE(Installation) Network |
                     +---------------------------+




**The following figure shows the interfaces and nics of JumpHost and deployment nodes in
huawei-pod1 network configuration(default one nic for openstack networks).**

.. code-block:: console


    +--------------JumpHost-------------+
    |                                   |
    |   +-+Compass+-+                   |
    |   |           +     +--------+    |    External-network
    |   |         eth2+---+br-ext  +-+eth0+----------------------+
    |   |           +     +--------+    |                        |
    |   |           |                   |                        |
    |   |           |                   |                        |
    |   |           +     +--------+    |    Install-network     |
    |   |         eth1+---+install +-+eth1+-----------------+    |
    |   |           +     +--------+    |                   |    |
    |   |           |                   |                   |    |
    |   |           |                   |                   |    |
    |   |           +                   |    IPMI-network   |    |
    |   |         eth0                eth2+-----------+     |    |
    |   |           +                   |             |     |    |
    |   +---+VM+----+                   |             |     |    |
    +-----------------------------------+             |     |    |
                                                      |     |    |
                                                      |     |    |
                                                      |     |    |
                                                      |     |    |
    +---------------Host1---------------+             |     |    |
    |                                   |             |     |    |
    |                                  eth0+----------------+    |
    |                                   |             |     |    |
    |                   mgmt +--------+ |             |     |    |
    |                                 | |             |     |    |
    |                +-----------+    | |             |     |    |
    |   external+----+  br-prv   +----+eth1+---------------------+
    |                +-----------+    | |             |     |    |
    |                                 | |             |     |    |
    |                   storage +-----+ |             |     |    |
    |                                   |             |     |    |
    +-----------------------------------+             |     |    |
    |                                 IPMI+-----------+     |    |
    +-----------------------------------+             |     |    |
                                                      |     |    |
                                                      |     |    |
                                                      |     |    |
    +---------------Host2---------------+             |     |    |
    |                                   |             |     |    |
    |                                  eth0+----------------+    |
    |                                   |             |          |
    |                   mgmt +--------+ |             |          |
    |                                 | |             |          |
    |                +-----------+    | |             |          |
    |   external+----+  br-prv   +----+eth1+---------------------+
    |                +-----------+    | |             |
    |                                 | |             |
    |                   storage +-----+ |             |
    |                                   |             |
    +-----------------------------------+             |
    |                                 IPMI+-----------+
    +-----------------------------------+

**The following figure shows the interfaces and nics of JumpHost and deployment nodes in
intel-pod8 network configuration(openstack networks are seperated by multiple NICs).**

.. code-block:: console


    +-------------+JumpHost+------------+
    |                                   |
    |   +-+Compass+-+                   |
    |   |           +     +--------+    |    External-network
    |   |         eth2+---+br-ext  +-+eth0+----------------------+
    |   |           +     +--------+    |                        |
    |   |           |                   |                        |
    |   |           |                   |                        |
    |   |           +     +--------+    |    Install-network     |
    |   |         eth1+---+install +-+eth1+-----------------+    |
    |   |           +     +--------+    |                   |    |
    |   |           |                   |                   |    |
    |   |           |                   |                   |    |
    |   |           +                   |    IPMI-network   |    |
    |   |         eth0                eth2+-----------+     |    |
    |   |           +                   |             |     |    |
    |   +---+VM+----+                   |             |     |    |
    +-----------------------------------+             |     |    |
                                                      |     |    |
                                                      |     |    |
                                                      |     |    |
                                                      |     |    |
    +--------------+Host1+--------------+             |     |    |
    |                                   |             |     |    |
    |                                  eth0+----------------+    |
    |                                   |             |     |    |
    |                      +--------+   |             |     |    |
    |         external+----+br-prv  +-+eth1+---------------------+
    |                      +--------+   |             |     |    |
    |         storage +---------------+eth2+-------------------------+
    |                                   |             |     |    |   |
    |         Mgmt    +---------------+eth3+----------------------------+
    |                                   |             |     |    |   |  |
    |                                   |             |     |    |   |  |
    +-----------------------------------+             |     |    |   |  |
    |                                 IPMI+-----------+     |    |   |  |
    +-----------------------------------+             |     |    |   |  |
                                                      |     |    |   |  |
                                                      |     |    |   |  |
                                                      |     |    |   |  |
                                                      |     |    |   |  |
    +--------------+Host2+--------------+             |     |    |   |  |
    |                                   |             |     |    |   |  |
    |                                  eth0+----------------+    |   |  |
    |                                   |             |          |   |  |
    |                      +--------+   |             |          |   |  |
    |         external+----+br-prv  +-+eth1+---------------------+   |  |
    |                      +--------+   |             |              |  |
    |         storage +---------------+eth2+-------------------------+  |
    |                                   |             | storage-network |
    |         Mgmt    +---------------+eth3+----------------------------+
    |                                   |             | mgmt-network
    |                                   |             |
    +-----------------------------------+             |
    |                                 IPMI+-----------+
    +-----------------------------------+


Start Deployment (Bare Metal Deployment)
----------------------------------------

1. Edit deploy.sh

1.1. Set OS version for deployment nodes.
     Compass4nfv supports ubuntu and centos based openstack newton.

E.g.

.. code-block:: bash

    # Set OS version for target hosts
    # Ubuntu16.04 or CentOS7
    export OS_VERSION=xenial
    or
    export OS_VERSION=centos7

1.2. Set ISO image corresponding to your code

E.g.

.. code-block:: bash

    # Set ISO image corresponding to your code
    export ISO_URL=file:///home/compass/compass4nfv.iso

1.3. Set hardware deploy jumpserver PXE NIC. (set eth1 E.g.)
     You do not need to set it when virtual deploy.

E.g.

.. code-block:: bash

    # Set hardware deploy jumpserver PXE NIC
    # you need to comment out it when virtual deploy
    export INSTALL_NIC=eth1

1.4. Set scenario that you want to deploy

E.g.

nosdn-nofeature scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-nosdn-nofeature-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network.yml

ocl-nofeature scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-ocl-nofeature-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network_ocl.yml

odl_l2-moon scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-odl_l2-moon-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network.yml

odl_l2-nofeature scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-odl_l2-nofeature-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network.yml

odl_l3-nofeature scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-odl_l3-nofeature-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network.yml

onos-nofeature scenario deploy sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-onos-nofeature-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network_onos.yml

onos-sfc deploy scenario sample

.. code-block:: bash

    # DHA is your dha.yml's path
    export DHA=./deploy/conf/hardware_environment/huawei-pod1/os-onos-sfc-ha.yml

    # NETWORK is your network.yml's path
    export NETWORK=./deploy/conf/hardware_environment/huawei-pod1/network_onos.yml

2. Run ``deploy.sh``

.. code-block:: bash

    ./deploy.sh