CloudStack
Installation
Here are my brief notes on getting CloudStack on Rocky Linux 8.4.
Refer to the installation guide at http://docs.cloudstack.apache.org/en/latest/quickinstallationguide/qig.html
Management
The system should have SELinux disabled.
# setenforce 0
# vi /etc/selinux/config
## disable selinux
Setup networking
# yum -y install epel-release
# yum -y install bridge-utils net-tools
# cat > /etc/sysconfig/network-scripts/ifcfg-cloudbr0 <<EOF
DEVICE=cloudbr0
TYPE=Bridge
ONBOOT=yes
BOOTPROTO=static
IPV6INIT=no
IPV6_AUTOCONF=no
DELAY=5
IPADDR=172.16.10.2
GATEWAY=172.16.10.1
NETMASK=255.255.255.0
DNS1=8.8.8.8
DNS2=8.8.4.4
STP=yes
USERCTL=no
NM_CONTROLLED=no
EOF
# systemctl stop firewalld
# systemctl disable firewalld
Install CloudStack repos, then the CloudStack management package.
# cat > /etc/yum.repos.d/cloudstack.repo <<EOF
[cloudstack]
name=cloudstack
baseurl=http://download.cloudstack.org/centos/8/4.15/
enabled=1
gpgcheck=0
EOF
# yum -y install cloudstack-management
Install MySQL (cannot be MariaDB):
# rpm -ivh http://repo.mysql.com/mysql80-community-release-el8.rpm
# yum -y install mysql-server
# yum -y install mysql-connector-python
## edit /etc/my.cnf to have the following lines.
cat >> /etc/my.cnf <<EOF
[mysqld]
innodb_rollback_on_timeout=1
innodb_lock_wait_timeout=600
max_connections=350
log-bin=mysql-bin
binlog-format = 'ROW'
EOF
# systemctl enable mysqld
# systemctl start mysqld
Setup storage
# mkdir -p /export/primary /export/secondary
# yum -y install nfs-utils
# cat > /etc/exports <<EOF
/export/secondary *(rw,async,no_root_squash,no_subtree_check)
/export/primary *(rw,async,no_root_squash,no_subtree_check)
EOF
# systemctl start nfs-server
# systemctl enable nfs-server
Setup CloudStack.
# /usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /export/secondary -u https://download.cloudstack.org/systemvm/4.15/systemvmtemplate-4.15.1-kvm.qcow2.bz2 -h kvm -F
# cloudstack-setup-databases cloud:password@localhost --deploy-as=root
# cloudstack-setup-management
# systemctl start cloudstack-management
# systemctl enable cloudstack-management
At this point, you should have the CloudStack web UI available at http://cloudstack:8080/client. Login as admin / password. Continue the setup process via the web interface.
Setup a zone
Setup a pod. Use 172.16.10.0/24 is the bridge network that was created. We will use 172.16.10.1 as gateway and guest gateway. 172.16.10.10 through 172.16.10.20 as reserved IPs and 172.16.10.30 through 172.16.10.200 as guest IPs.
Setup a cluster. Use 172.16.10.2 as the host and enter your root credentials. For both primary and secondary storage, use the host's NFS storage at 172.16.10.2 at /export/primary and /export/secondary.
Glossary
- Zone - largest entity in CloudStack.
- Pod - ???