+ All Categories
Home > Documents > OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is...

OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is...

Date post: 20-Jul-2020
Category:
Upload: others
View: 10 times
Download: 1 times
Share this document with a friend
26
Oracle® Communications OCCNE Installation Guide for Openstack Release 1.1 F21387-01 July 2019
Transcript
Page 1: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Oracle® CommunicationsOCCNE Installation Guide for Openstack

Release 1.1F21387-01July 2019

Page 2: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Oracle Communications OCCNE Installation Guide for Openstack, Release 1.1

F21387-01

Copyright © 2019, 2019, Oracle and/or its affiliates. All rights reserved.

This software and related documentation are provided under a license agreement containing restrictions on use anddisclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement orallowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit,perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilationof this software, unless required by law for interoperability, is prohibited.

The information contained herein is subject to change without notice and is not warranted to be error-free. If you findany errors, please report them to us in writing.

If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf ofthe U.S. Government, then the following notice is applicable:

U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software, anyprograms installed on the hardware, and/or documentation, delivered to U.S. Government end users are "commercialcomputer software" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplementalregulations. As such, use, duplication, disclosure, modification, and adaptation of the programs, including any operatingsystem, integrated software, any programs installed on the hardware, and/or documentation, shall be subject to licenseterms and license restrictions applicable to the programs. No other rights are granted to the U.S. Government.

This software or hardware is developed for general use in a variety of information management applications. It is notdeveloped or intended for use in any inherently dangerous applications, including applications that may create a risk ofpersonal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take allappropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliatesdisclaim any liability for any damages caused by use of this software or hardware in dangerous applications.

Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of theirrespective owners.

Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used underlicense and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, andthe AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registeredtrademark of The Open Group.

This software or hardware and documentation may provide access to or information about content, products, andservices from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim allwarranties of any kind with respect to third-party content, products, and services unless otherwise set forth in anapplicable agreement between you and Oracle. Oracle Corporation and its affiliates will not be responsible for any loss,costs, or damages incurred due to your access to or use of third-party content, products, or services, except as set forth inan applicable agreement between you and Oracle.

Page 3: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Contents

1 Introduction

Acronyms and Abbreviations 1-1Limitations and Expectations 1-2References 1-2How to use this document 1-2Documentation Admonishments 1-3Locate Product Documentation on the Oracle Help Center Site 1-4Customer Training 1-4My Oracle Support 1-4Emergency Response 1-5

2 Installation Prerequisites

3 Installation procedure for OCCNE in Openstack environment

4 Scaling Worker Nodes

5 Configuration Parameters

iii

Page 4: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

List of Figures

1-1 Openstack Topology 1-1

1-2 Example of a Procedure Steps Used in This Document 1-3

2-1 Sample Network Topology 2-2

iv

Page 5: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

List of Tables

1-1 Key Acronyms and Abbreviations 1-1

1-2 Admonishments 1-3

2-1 Network and Description 2-1

3-1 Installing OCCNE in Openstack 3-1

4-1 Scaling worker nodes 4-1

5-1 Configuration Parameters for kubernetes clusters 5-1

5-2 Configuration Parameters for Mysql NDB clusters 5-1

v

Page 6: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

1Introduction

The document provides information about the procedure for installing an OCCNE 1.1 usingheat template in Openstack environment. The installation procedure covers both MySQLcluster and kubernetes cluster with common services.

The kubernetes cluster described in this document contains three masters and three workernodes. The GEO-redundancy is achieved in database layer, there are two MySQL clusters withMySQL GEO replication, every cluster has two management, three SQL and two data nodes.

The sample topology is illustrated below:

Figure 1-1 Openstack Topology

Acronyms and AbbreviationsThis table below lists abbreviations, and acronyms specific to this document.

Table 1-1 Key Acronyms and Abbreviations

Acronym/Abbreviation/Term

Definition

CLI Command Line InterfaceCNE Cloud Native EnvironmentDB DatabaseDBMS Database Management SystemEFK Elasticsearch, Fluentd, Kibana

1-1

Page 7: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 1-1 (Cont.) Key Acronyms and Abbreviations

GUI Graphical User InterfaceHTTP Hyper Text Transfer ProtocolIP Internet Protocol; may be used as shorthand to refer to an IP layer 3 address.IPv4 Internet Protocol version 4IPv6 Internet Protocol version 6K8s Shorthand alias for KubernetesNFS Network File SystemNTP Network Time ProtocolOAM Operations, Administration, MaintenanceOCCNE Oracle Communications Signaling, Network Function Cloud Native

EnvironmentOS Operating SystemOSDC Oracle Software Download CenterTAR Short for Tape Archive, and sometimes referred to as tarball, a file that has the

TAR file extension is a file in the Consolidated Unix Archive format.URL Uniform Resource LocatorVM Virtual MachineVIM Virtual Infrastructure Manager

Limitations and Expectations1. This procedure only supports one VIM per one OCCNE environment. If customer requires

cross-cloud k8s cluster, then extra orchestrator tool needs to be used.

2. This procedure assumes four networks. The heat template can be modified to supportdifferent network layouts, such as one or two networks.

3. Local disk is used for prometheus and EFK, the heat template can be modified to usekubespray openstack cloud provider to allocate volume for prometheus and EFK directly.The procedure is not included in this document.

References1. Design of Virtualize CNE on Openstack.

2. OC-CNE Installation Guide.

How to use this documentAlthough this document is primarily to be used as an initial installation guide, its secondarypurpose is to be used as a reference for Disaster Recovery procedures.

When executing this document for either purpose, there are a few points which help to ensurethat the user understands the author’s intent. These points are as follows:

1. Before beginning a procedure, completely read the instructional text (it will appearimmediately after the Section heading for each procedure) and all associated proceduralWARNINGS or NOTES.

Chapter 1Limitations and Expectations

1-2

Page 8: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

2. Before execution of a STEP within a procedure, completely read the left and right columnsincluding any STEP specific WARNINGS or NOTES.

If a procedural STEP fails to execute successfully, STOP and contact Oracle’s CustomerService for assistance before attempting to continue. My Oracle Support for information oncontacting Oracle Customer Support.

Figure 1-2 Example of a Procedure Steps Used in This Document

Documentation AdmonishmentsAdmonishments are icons and text throughout this manual that alert the reader to assurepersonal safety, to minimize possible service interruptions, and to warn of the potential forequipment damage.

Table 1-2 Admonishments

Icon Description

Danger:(This icon and text indicate the possibility ofpersonal injury.)

Warning:(This icon and text indicate the possibility ofequipment damage.)

Chapter 1Documentation Admonishments

1-3

Page 9: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 1-2 (Cont.) Admonishments

Icon Description

Caution:(This icon and text indicate the possibility ofservice interruption.)

Locate Product Documentation on the Oracle HelpCenter Site

Oracle Communications customer documentation is available on the web at the Oracle HelpCenter site, http://docs.oracle.com. You do not have to register to access these documents.Viewing these files requires Adobe Acrobat Reader, which can be downloaded at http://www.adobe.com.

1. Access the Oracle Help Center site at http://docs.oracle.com.

2. Click Industries.

3. Under the Oracle Communications subheading, click Oracle Communicationsdocumentation link.

The Communications Documentation page displays.

4. Click on your product and then the release number.

A list of the documentation set for the selected product and release displays.

5. To download a file to your location, right-click the PDF link, select Save target as (orsimilar command based on your browser), and save to a local folder.

Customer TrainingOracle University offers training for service providers and enterprises. Visit our web site toview, and register for, Oracle Communications training at http://education.oracle.com/communication.

To obtain contact phone numbers for countries or regions, visit the Oracle University Educationweb site at www.oracle.com/education/contacts.

My Oracle SupportMy Oracle Support (https://support.oracle.com) is your initial point of contact for all productsupport and training needs. A representative at Customer Access Support can assist you withMy Oracle Support registration.

Call the Customer Access Support main number at 1-800-223-1711 (toll-free in the US), or callthe Oracle Support hotline for your local country from the list at http://www.oracle.com/us/support/contact/index.html. When calling, make the selections in the sequence shown below onthe Support telephone menu:

1. Select 2 for New Service Request.

2. Select 3 for Hardware, Networking and Solaris Operating System Support.

Chapter 1Locate Product Documentation on the Oracle Help Center Site

1-4

Page 10: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

3. Select one of the following options:

• For Technical issues such as creating a new Service Request (SR), select 1.

• For Non-technical issues such as registration or assistance with My Oracle Support,select 2.

You are connected to a live agent who can assist you with My Oracle Support registration andopening a support ticket.

My Oracle Support is available 24 hours a day, 7 days a week, 365 days a year.

Emergency ResponseIn the event of a critical service situation, emergency response is offered by the CustomerAccess Support (CAS) main number at 1-800-223-1711 (toll-free in the US), or by calling theOracle Support hotline for your local country from the list at http://www.oracle.com/us/support/contact/index.html. The emergency response provides immediate coverage, automaticescalation, and other features to ensure that the critical situation is resolved as rapidly aspossible.

A critical situation is defined as a problem with the installed equipment that severely affectsservice, traffic, or maintenance capabilities, and requires immediate corrective action. Criticalsituations affect service and/or system operation resulting in one or several of these situations:

• A total system failure that results in loss of all transaction processing capability

• Significant reduction in system capacity or traffic handling capability

• Loss of the system’s ability to perform automatic system reconfiguration

• Inability to restart a processor or the system

• Corruption of system databases that requires service affecting corrective actions

• Loss of access for maintenance or recovery operations

• Loss of the system ability to provide any required critical or major trouble notification

Any other problem severely affecting service, capacity/traffic, billing, and maintenancecapabilities may be defined as critical by prior discussion and agreement with Oracle.

Chapter 1Emergency Response

1-5

Page 11: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

2Installation Prerequisites

1. The Openstack image is pre-created and is available for download from OSDC.

2. The following table includes information about flavors and volumes:

VM VM Type Instance

VM Profile Notes

k8scluster

k8s master node 3 4 vCPU, 8 GB RAM, 60GB disk

Master node can be small size

k8s workernode

3 12 vCPU, 64 GB RAM ,60 GB disk

Bastion node 1 4 vCPU, 8 GB RAM, 60GB disk

Provides docker registry andhelm repository

DBcluster

DB LayerManagementnode

2 4 vCPU, 8 GB RAM, 60GB disk

DB Layer SQLnode

2 12 vCPU, 16 GB RAM,60 GB disk

DB Layer datanode

2 12 vCPU, 32 GB RAM,60 GB disk

Bastion node 1 4 vCPU, 8 GB RAM, 60GB disk

Provides MySQL MCM productto automate cluster management.

Note:

Fo storage requirement, the current deployment supports local disk, volumes, orboth, for mixed usage, and can be defined in the heat template.

3. The networks should be created before kubernetes setup. The network design can becustomized as per the customer requirements.

Table 2-1 Network and Description

Network Description

DATA For internal access between services and DB nodesOAM Management networkREST Application service network, for example, REST service or SOAP serviceSIG Application service network, for example, diameter services provided by cloud

native PCRF product

The following setup uses four networks per site, and different site uses different tenants inOpenstack.

2-1

Page 12: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Figure 2-1 Sample Network Topology

Chapter 2

2-2

Page 13: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

3Installation procedure for OCCNE inOpenstack environment

Table 3-1 Installing OCCNE in Openstack

Step # Procedure Description

1 Build images forOpenstack

This release comes with qcow2 image that includes, Oracle Linux,OCCNE tools, kubernetes, common services and MySQL NDB clusterinstall files.

2 Prepare the packageand environment

1. Download the package occne-1.1.0.1.tar.gz from OSDC andput it to the jump server and decompress it.

$ tar -zxvf occne-1.1.0.1.tar.gz$ cd occne-1.1.0.1

2. Prepare RC file for Openstack authentication.Download and source the Openstack RC file on both sites(Openstack projects). Seehttps://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux_OpenStack_Platform/4/html/End_User_Guide/cli_openrc.html

3. Import the image occne-bastion-1.1.0.1.qcow2 to Openstackon the jumpbox which can access Openstack environment.Usually the operator can find a jumpbox server inside Openstackenvironment, and this jumpbox connects to the networks used by theproduct.#openstack image create --disk-format qcow2 --container-format bare --file occne-bastion-1.1.0.1.qcow2 occne-bastion-1.1.0.1Note: Perform step 2 and 3 on both site 1 and 2, since different sitesusually are in different Openstack project.

4. Verify the image in openstack glance service, by executing:

#openstack image list | grep occne-bastion

3-1

Page 14: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

3 Generate ssh keypair to access VMs

1. Login to the jumpserver and generate ssh key on jump server.

$ ssh-keygenGenerating public/private rsa key pair.Enter file in which to save the key (/home/admusr/.ssh/id_rsa):Enter passphrase (empty for no passphrase):Enter same passphrase again:Your identification has been saved in /home/admusr/.ssh/id_rsa.Your public key has been saved in /home/admusr/.ssh/id_rsa.pub.The key fingerprint is:SHA256:bkS/NDkdorlKYbROmYNdbkV1YVq2uFi0dvIe+pj5sOo [email protected] key's randomart image is:+---[RSA 2048]----+| ..o *. || . . O . || . o o O o || + B = B * || . X S B o o || + * o + o . || o + . o . || . o B || . .E.=.o |+----[SHA256]-----+

2. Use the content of id_rsa.pub to import the ssh key pair in theopenstack GUI.Go to the directory '$HOME/.ssh' of the jump server.The directory contains three files: authorized_keys/id_rsa/id_rsa.pub.Copy content of the file 'id_rsa.pub' that needs to be used in step3.

3. Import the ssh key pair in the Openstack GUI.On the VIM, click the menu key pairs.For Openstack, navigate to the key pairs menu under project, andthen compute, and then keypair.Click Import key pair to import a ssh key to the openstack.As below, the Public Key should be the public key of jumpserverwhich is generated in step 1 above. Give it a key pair name, forexample, vpcrf-key-pair.

Chapter 3

3-2

Page 15: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

Note: Perform the step 3 on both site 1 and site 2.

Chapter 3

3-3

Page 16: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

4 Deploy Kubernetesclusters

Install kubernetes clusters on both site1 and site 2:

1. Configure heat template parameters to match with Openstackenvironments and performance requirements.For information on configurable parameters required while installingkubernetes clusters, see table Configuration Parameters forkubernetes clusters, in section Configuration Parameters.

2. Installing OCCNE on site 1:

a. Source the RC file of Site 1. The RC file is for Openstackauthentication, refer to step 2.

b. Modify file occne_install.sh.

c. Go to the directory ~/occne-1.1.0.1/k8s-cluster andmodify the file parameters in occne_install.sh, as describedbelow:

$ vim occne_install.sh #!/bin/bashimage=occne-bastion-1.1.0.1master_flavor=Oracle_vPCRF-k8s-masterworker_flavor=Oracle_vPCRF-k8s-workerbastion_image=occne-bastion-1.1.0.1bastion_flavor=Oracle_vPCRF-k8s-masternetwork1=PN-Oracle_vPCRF_Site1-OAMnetwork2=PN-Oracle_vPCRF_Site1-RESTnetwork3=PN-Oracle_vPCRF_Site1-DIAMnetwork4=PN-Oracle_vPCRF_Site1-DATAk8s_cluster_name=vpcrf-site1volume_size=60ssh_key=vpcrf-key-pairavailability_zone=qpstack_name=vpcrf-site1 openstack stack create -e environment.yaml -t occne_install.yaml \ --parameter image=$image \ --parameter master_flavor=$master_flavor \ --parameter worker_flavor=$worker_flavor \ --parameter bastion_image=$bastion_image \ --parameter bastion_flavor=$bastion_flavor \ --parameter network1=$network1 \ --parameter network2=$network2 \ --parameter network3=$network3 \ --parameter network4=$network4 \ --parameter ssh_key=$ssh_key \ --parameter k8s_cluster_name=$k8s_cluster_name \ --parameter availability_zone=$availability_zone \ --parameter master_num=3 \ --parameter worker_num=3 \

Chapter 3

3-4

Page 17: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

--parameter volume_size=$volume_size \ --parameter action_flag=1 $stack_name

Note: Modify the parameters as per the requirement:• action_flag: the value is 1, which indicates it is a

progress of installing k8s cluster.• ssh_key: Its value should be the key-name generate in

step 3 Generate ssh key pair. It is important, otherwisethe new created vms will not be logged in.

• availability_zone: It can be obtained by executing thebelow command in the jump server and get the availablezone:$ openstack availability zone list

• Run the file occne_install.sh, by executing:$ ./occne_install.sh

Note: Installing OCCNE on site 2 is similar to site 1,except for the following differences:– Source the RC file of site 2, as the RC file is for

Openstack authentication and the project can bedifferent with RC file of site 1.

– Change the following parameters, as they are differentfrom site 1:availability_zone/stack_name/network1/network2/network3/network4.Usually it takes 15 minutes to complete theinstallation of OCCNE.

3. Verify the cluster status on the master node:

a. Login to the master node and execute:

# kubectl get nodes

The status of all the nodes must be Ready.

# kubectl get pods --all-namespaces

The status of all the pods must be running.

Chapter 3

3-5

Page 18: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

5 Deploy MysqlNDB Cluster

Install Mysql cluster on both site 1 and site 2:Note: The Mysql cluster setup and GEO redundancy are configuredautomatically.

1. Configure heat template parameters to match with Openstackenvironments and performance requirements.For information on configurable parameters required while installingMysql NDB clusters, see table Configuration Parameters for MysqlNDB clusters, in section Configuration Parameters.

2. Install Mysql cluster on site 1:

a. Source the RC file of site 1.

b. Modify the file occne_db_install.shGo to the directory ~/occne-1.0.1.1.0/mysql-cluster andmodify the file parameters in occne_db_install.sh.

$ vim occne_db_install.sh #!/bin/bashmgmt_flavor=Oracle_vPCRF-db-mgmtndb_flavor=Oracle_vPCRF-db-datamysql_flavor=Oracle_vPCRF-db-sqlbastion_flavor=Oracle_vPCRF-db-mgmtdb_image=occne-bastion-1.1.0.1db_cluster_name=vpcrf-site1-dbnetwork1=OAMnetwork2=SIGAssh_key=vpcrf-key-pairavailability_zone=qpbastion_image=occne-bastion-1.1.0.1 read -p "Enter the master host for cluster replication: " master_hostread -p "Enter the stack name: " stack_name#master_host=master_hostopenstack stack create -e environment.yaml -t occne_db.yaml \ --parameter db_image=$db_image \ --parameter bastion_image=$bastion_image \ --parameter mgmt_flavor=$mgmt_flavor \ --parameter ndb_flavor=$ndb_flavor \ --parameter mysql_flavor=$mysql_flavor \ --parameter bastion_flavor=$bastion_flavor \ --parameter ssh_key=$ssh_key \ --parameter network1=$network1 \ --parameter network2=$network2 \ --parameter db_cluster_name=$db_cluster_name \ --parameter availability_zone=$availability_zone \ --parameter master_host=$master_host $stack_name

Note: Modify the parameters per environment configurations.

Chapter 3

3-6

Page 19: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

For example:ssh_key: Its value should be the key-name generate in Step 3Generate ssh key pair. It is necessary for every new VM to login.

c. Run the file occne_db_install.sh, by executing:

$ ./occne_db_install.sh

Note: The following two parameters must be provided:• master_host is used by Mysql cluster GEO redundancy

and it takes effect while creating the second Mysql cluster.So when creating the first one that is site 1, the parametermaster_host must be null.When you see the message Enter the master hostfor cluster replication:, on the terminal afterrunning the script occne_db_install.sh, press Enter.

• stack_name is the name of the stack, such as, vpcrf-site1-db.

d. Check if the mysql cluster has been created:SSH to the host of vpcrf-site1-db-mysql-0 (mysql-0 is forthe replication node).Assuming the ip is 192.168.0.62, execute:

$ ssh [email protected]$ sudo su -$ mysql -h127.0.0.1 -udemo -pdemo

Note:It takes about 15 minutes to install Mysql cluster.Once the Mysql cluster is created and confirmed, the Mysqlconnection can be established, and Mysql cluster can beinstalled on site 2.

Chapter 3

3-7

Page 20: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

3. Install Mysql cluster on site 2:

a. Source RC files of site 2.

b. Modify the file occne_db_install.sh:Go to the directory ~/occne-1.0.1.1.0/mysql-cluster andmodify the file parameters in occne_db_install.sh.The change the following parameters:availability_zone/stack_name/network1/network2.

c. Run the file occne_db_install.sh, by executing:

$ ./occne_db_install.sh

Note: The following two parameters must be provided:• master_host, the value of this parameter is the OAM ip

of vpcrf-site1-db-mysql-0 (created in step 2.c,mysql-0 is for the replication node). If the parameterreturns error, the GEO redundancy between site 1 and site2 fails.

• stack_name is the name of the stack, such as, vpcrf-site2-db.

d. Check if the Mysql Cluster and GEO redundancy is created.SSH to the host of vpcrf-site2-db-mysql-0 (mysql-0 is forthe replication node).Assuming the ip is 192.168.0.36, execute:

$ ssh [email protected]$ sudo su -$ mysql -h127.0.0.1 -udemo -pdemo

Execute sql command:

> show master status \G;> show slave status \G;

Chapter 3

3-8

Page 21: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

The slave sql running state is normal.

e. Check the slave status on mysql-0 of site 1.SSH to the host of vpcrf-site1-db-mysql-0 (mysql-0 is forthe replication node).Assuming the ip is 192.168.0.62, execute:

$ ssh [email protected]$ sudo su -$ mysql -h127.0.0.1 -udemo -pdemo

Execute sql command:

> show master status \G;> show slave status \G;

Chapter 3

3-9

Page 22: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 3-1 (Cont.) Installing OCCNE in Openstack

Step # Procedure Description

The slave sql running state is normal on site 1. So the GEOredundancy has been created between site 1 and site 2.

Chapter 3

3-10

Page 23: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

4Scaling Worker Nodes

The following procedure informs about Scaling in and scaling out the worker nodes ofkubernetes cluster:

Table 4-1 Scaling worker nodes

Step # Procedure Description

1 Scale out theworker nodes

1. Identify the stack of Openstack and the number of worker nodes ofkubernetes cluster that needs to be scaled out.

2. Run the file, occne_scaleout.sh and provide the parameters at theprompt:

$ ./occne_scaleout.sh

Note:The parameters must be provided, including the stack name, resourcegroup and scaling out number.In the example screen above, the first parameters (stack name)entered is heat-new1-k8s, the second parameter (resource group) isworker_num and the third parameter (scale num) is '4'. It indicatesthat the worker number of kubernetes cluster that is created by thestack heat-new1-k8s will be scaled out to 4.Usually, it takes 10 minutes to complete the scaling out of kubernetescluster.Scaling out support is enabled for both master and worker nodes ofkubernetes cluster.

4-1

Page 24: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 4-1 (Cont.) Scaling worker nodes

Step # Procedure Description

2 Scale in workernodes

1. Identify the stack of Openstack and the number of worker nodes ofkubernetes cluster that needs to be scaled out.

2. Run the file occne_scaleout.sh and enter the parameters at theprompt:

$ ./occne_scalein.sh

Note: The parameters must be provided, including stack name,resource group and scaling in number.In the example screen above, the first parameter (stack name)provided is heat-new1-k8s, the second parameter (resource group)is worker_num and the third parameter (scale num) is '3'. It indicatesthat the worker number of kubernetes cluster that is created by thestack heat-new1-k8s will be scaled in to 3.Usually, it takes 5 minutes to complete the scaling out of kubernetescluster.The scaling in support is enabled only for worker nodes ofkubernetes cluster, and not for master nodes.

3 Verify if the scalingis successful

To verify if the scaling is successful, execute:

kubectl get nodes

The status of all the nodes must be Ready.Operator can also monitor Openstack dashboard output for changes increated VMs.

Chapter 4

4-2

Page 25: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

5Configuration Parameters

Table 5-1 Configuration Parameters for kubernetes clusters

Catalog Parameters Description

VM flavor master_flavor master VM profile, including CPU,Memory, Disk definitions

worker_flavor worker VM profile, including CPU,Memory, Disk definitions

bastion_flavor bastion VM profile, including CPU,Memory, Disk definitions

VM image image image for VMs in kubernetes clusterbastion_image image for bastion VM

Network network1 Node networks of kubernetes cluster.network1 is also the network of bastionserver

network2network3network4k8s_cluster_name Kubernetes cluster namevolume_size Volume size attached to the VMs of

kubernetes cluster, default is 60 GBssh_key ssh key pair name, which used to login to

the VMsavailability_zone availability zone to create kubernetes

clusterstack_name openstack stack name of being created

Table 5-2 Configuration Parameters for Mysql NDB clusters

Catalog Parameters Description

VMflavor

mgmt_flavor Management VM profile, including CPU, Memory, Disk definitionsndb_flavor NDB VM profile, including CPU, Memory, Disk definitionsmysql_flavor MYSQL VM profile, including CPU, Memory, Disk definitionsbastion_flavor Bastion VM profile, including CPU, Memory, Disk definitions

VMimage

db_image image for VMs in mysql ndb clusterbastion_image image for bastion VM

Network network1 Node networks of kubernetes cluster. network1 is also the network of bastionserver,network2

db_cluster_name

Mysql cluster name

ssh_key ssh key pair name, which used to login to the VMsavailability_zone

availability zone to create kubernetes cluster

stack_name openstack stack name of being created

5-1

Page 26: OCCNE Installation Guide for Openstack - Oracle...The Openstack image is pre-created and is available for download from OSDC. 2. The following table includes information about flavors

Table 5-2 (Cont.) Configuration Parameters for Mysql NDB clusters

Catalog Parameters Description

master_host The master ip of the GEO redundancy, the opposite is replicate ip. It takeseffect while creating the second site mysql cluster and then the mysql0 of thefirst site mysql cluster will be the master host for replication.

Chapter 5

5-2


Recommended