Set Up Your KVM Virtual Machine for a Cloud Server Cluster
First configure the VM on the master node, and then configure the VM on each worker node.
Follow these steps to set up and configure your VM on a cluster of servers in a cloud deployment:
-
Verify that your master node meets the VM requirements.
When using a VM, the following system resources must be allocated:Resource Minimum Requirement Processor Four (4) virtual CPUs Memory 8 GB RAM Local disk storage For NetQ 3.2.x and later: 64 GB (2 TB max)
For NetQ 3.1 and earlier: 32 GB (2 TB max)Network interface speed 1 Gb NIC Hypervisor KVM/QCOW (QEMU Copy on Write) image for servers running CentOS, Ubuntu and RedHat operating systems -
Confirm that the needed ports are open for communications.
You must open the following ports on your NetQ Platforms:
Additionally, for internal cluster communication, you must open these ports:Port or Protocol Number Protocol Component Access 8443 TCP Admin UI 443 TCP NetQ UI 31980 TCP NetQ Agent communication 31982 TCP NetQ Agent SSL communication 32708 TCP API Gateway 22 TCP SSH 179 TCP Calico networking (BGP) 4 IP Protocol Calico networking (IP-in-IP Protocol) 4789 UDP Calico networking (VxLAN) 6443 TCP kube-apiserver 2379 TCP etcd datastore Port Protocol Component Access 8080 TCP Admin API 5000 TCP Docker registry 8472 UDP Flannel port for VXLAN 6443 TCP Kubernetes API server 10250 TCP kubelet health probe 2379 TCP etcd 2380 TCP etcd 7072 TCP Kafka JMX monitoring 9092 TCP Kafka client 7071 TCP Cassandra JMX monitoring 7000 TCP Cassandra cluster communication 9042 TCP Cassandra client 7073 TCP Zookeeper JMX monitoring 2888 TCP Zookeeper cluster communication 3888 TCP Zookeeper cluster communication 2181 TCP Zookeeper client Port 32666 is no longer used for the NetQ UI.
-
Download the NetQ Platform image.
-
Setup and configure your VM.
Open your hypervisor and set up your VM. You can use this example for reference or use your own hypervisor instructions.
KVM Example Configuration
This example shows the VM setup process for a system with Libvirt and KVM/QEMU installed.
-
Log in to the VM and change the password.
Use the default credentials to log in the first time:
- Username: cumulus
- Password: cumulus
$ ssh cumulus@<ipaddr> Warning: Permanently added '<ipaddr>' (ECDSA) to the list of known hosts. Ubuntu 18.04.5 LTS cumulus@<ipaddr>'s password: You are required to change your password immediately (root enforced) System information as of Thu Dec 3 21:35:42 UTC 2020 System load: 0.09 Processes: 120 Usage of /: 8.1% of 61.86GB Users logged in: 0 Memory usage: 5% IP address for eth0: <ipaddr> Swap usage: 0% WARNING: Your password has expired. You must change your password now and login again! Changing password for cumulus. (current) UNIX password: cumulus Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully Connection to <ipaddr> closed.
Log in again with your new password.
$ ssh cumulus@<ipaddr> Warning: Permanently added '<ipaddr>' (ECDSA) to the list of known hosts. Ubuntu 18.04.5 LTS cumulus@<ipaddr>'s password: System information as of Thu Dec 3 21:35:59 UTC 2020 System load: 0.07 Processes: 121 Usage of /: 8.1% of 61.86GB Users logged in: 0 Memory usage: 5% IP address for eth0: <ipaddr> Swap usage: 0% Last login: Thu Dec 3 21:35:43 2020 from <local-ipaddr> cumulus@ubuntu:~$
-
Verify the master node is ready for installation. Fix any errors indicated before installing the NetQ software.
cumulus@hostname:~$ sudo opta-check-cloud
-
Change the hostname for the VM from the default value.
The default hostname for the NetQ Virtual Machines is ubuntu. Change the hostname to fit your naming conventions while meeting Internet and Kubernetes naming standards.
Kubernetes requires that hostnames are composed of a sequence of labels concatenated with dots. For example, “en.wikipedia.org” is a hostname. Each label must be from 1 to 63 characters long. The entire hostname, including the delimiting dots, has a maximum of 253 ASCII characters.
The Internet standards (RFCs) for protocols specify that labels may contain only the ASCII letters a through z (in lower case), the digits 0 through 9, and the hyphen-minus character ('-').
Use the following command:
cumulus@hostname:~$ sudo hostnamectl set-hostname NEW_HOSTNAME
Add the same NEW_HOSTNAME value to /etc/hosts on your VM for the localhost entry. Example:
127.0.0.1 localhost NEW_HOSTNAME
-
Verify that your first worker node meets the VM requirements, as described in Step 1.
-
Confirm that the needed ports are open for communications, as described in Step 2.
-
Open your hypervisor and set up the VM in the same manner as for the master node.
Make a note of the private IP address you assign to the worker node. You need it for later installation steps.
-
Verify the worker node is ready for installation. Fix any errors indicated before installing the NetQ software.
cumulus@hostname:~$ sudo opta-check-cloud
-
Repeat Steps 8 through 11 for each additional worker node you want in your cluster.
-
The final step is to install and activate the NetQ software using the CLI:
After NetQ is installed, you can log in to NetQ from your browser.