0% found this document useful (0 votes)
50 views12 pages

Apache CloudStack Deployment Guide

This report details the deployment and management of a cloud environment using Apache CloudStack, covering installation, network and storage setup, and key features like virtual machine provisioning. It outlines the requirements, terminology, installation steps, and configuration of zones, pods, and clusters, as well as networking and storage management. The findings indicate successful access to the Apache CloudStack interface and the creation of virtual machines, though challenges were encountered in installation and configuration.

Uploaded by

todoroki7725
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views12 pages

Apache CloudStack Deployment Guide

This report details the deployment and management of a cloud environment using Apache CloudStack, covering installation, network and storage setup, and key features like virtual machine provisioning. It outlines the requirements, terminology, installation steps, and configuration of zones, pods, and clusters, as well as networking and storage management. The findings indicate successful access to the Apache CloudStack interface and the creation of virtual machines, though challenges were encountered in installation and configuration.

Uploaded by

todoroki7725
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

CAMBODIA ACADEMY OF DIGITAL TECHNOLOGY

INSTITUTE OF DIGIAL TECHNOLOGY


COMPUTER SCIENCE
DATA SCIENCE GROUP 2

Apache Cloud Stack

Author: Sang Haksou

Cloud Computing

Lect. Try Vitou

Team Member: Sang Haksou, Oung Chhunheng, Saveourn Devin, Mom Monychot
Abstract

This report describes the deployment and management of a cloud environment using Apache

CloudStack. It covers the installation process, network and storage setup, and demonstrates key

features such as provisioning virtual machines. The aim is to provide a clear understanding of

how to utilize Apache CloudStack for cloud infrastructure management.

I. Introduction

Apache CloudStack™ is an open-source software system designed to deploy and manage

large networks of virtual machines, as a highly available, highly scalable Infrastructure as a

Service (IaaS) cloud computing platform.

II. Requirements

Guest OS: Choose "CentOS (64-bit)" or any compatible Linux distribution.

Disk Space: Allocate at least 30+ GB of disk space for one VM.

RAM: Allocate at least 6 GB of RAM for the virtual machine.

CPU Cores: Assign at least 3 CPU cores to the virtual machine.

Network Interface Controller (NIC): Add at least 1 NIC to the virtual machine.

Promiscuous Mode: Set the NIC in Promiscuous Mode (Allow All or Allow Instances), which is

required for passing traffic from CloudStack’s system VMs to the gateway.

Network Bridging: Make sure the VM's NIC is bridged to the physical NIC on your

laptop/desktop.

Avoid bridging to a wireless adapter to prevent connectivity issues; use a wired adapter instead.

Nested Virtualization: Enable Nested VT-x/AMD-V: Enable this feature in the settings of the

virtual machine to support nested virtualization. This setting is crucial for running virtualized

environments within the VM.


III. Terminology

1. Region

 Definition: The highest level of organization in a cloud environment, typically representing a

geographic area that contains multiple zones.

2. Zone

 Definition: A logical grouping of resources within a region. Zones can be designed for high

availability and disaster recovery.

 Example in the Picture: There are two zones (Zone 1 and Zone 2) depicted.
3. Pod

 Definition: A collection of hosts within a zone that share common resources, such as

networking and storage.

 Example in the Picture: Pod 2 is illustrated within Zone 1, containing clusters.

4. Cluster

 Definition: A grouping of hypervisors (hosts) within a pod that work together to provide

resources for virtual machines.

 Example in the Picture: Cluster 3 and Cluster 4 are shown within Pod 2, each containing

hosts.

5. Host

 Definition: A physical server or hypervisor that runs virtual machines.

 Example in the Picture: Hosts 1 and 2 are displayed under Cluster 3, and Host 1 is under

Cluster 4.

6. Primary Storage

 Definition: Storage used to hold virtual machine disk images and volumes, directly

accessible by the hosts.

 Example in the Picture: Primary storage is indicated next to each cluster.


7. Secondary Storage

 Definition: Storage used for holding backups, snapshots, and templates. It is not directly

attached to the hosts but is accessible for management tasks.

 Example in the Picture: Secondary storage is shown next to Zone 2.

IV. Installation of Apache CloudStack

Environment Setup

We started by creating several Virtual Machines (VMs) to host:

o Management Server: Controls the cloud.

o Database: Stores important data.

o Hypervisors: Run the virtual machines.

Installation Steps

1. Install the Management Server:

a. Download the Apache CloudStack package.

b. Follow the installation instructions [1].

2. Set Up the Database:

a. Install MySQL or MariaDB.

b. Create a database and user for CloudStack.

3. Install Hypervisors:

a. Install the chosen hypervisor on the VMs.


4. Configure CloudStack:

a. Use the CloudStack interface to connect the management server to

the database and hypervisors.

Configuration of Zones, Pods, Clusters

o Zones: A zone is a large area for resources. We created a main zone for our cloud.

o Pods: Each zone can have multiple pods, which group together hosts for better

management.

o Clusters: Inside each pod, we created clusters to group hypervisors, helping with

resource sharing.

V. Networking Configuration

Network Offering

We set up two types of networks:

 Isolated Networks: Private networks for security.

 Shared Networks: Networks that allow multiple VMs to connect easily.

Network Setup

Network configurations were performed through the CloudStack interface, allowing

administrators to define the parameters for each network offering, including IP ranges,

VLANs, and associated firewall rules.


VI. Storage Management

o Primary Storage Pools: Used to store VM disk images and volumes. NFS is

typically utilized for easy access and scalability.

o Secondary Storage Pools: Used for storing templates and snapshots, configured to

ensure data redundancy.

VII. Demonstration

Source Code

Network Configuration

To create a bridge for CloudStack networking and set a static IP, use the following commands:

 nmcli connection add type bridge con-name cloudbr0 ifname cloudbr0

 nmcli connection modify eth0 master cloudbr0

 nmcli connection up eth0


 nmcli connection modify cloudbr0 [Link] '[Link]/24' [Link]

'[Link]' [Link] '[Link]' [Link] manual && nmcli connection up cloudbr0

Note: Replace [Link] with your actual gateway IP if different.

Set Hostname

Set your hostname to haksou:

 hostnamectl set-hostname haksou --static

Configure SELinux

To set SELinux to permissive mode:

 # Edit /etc/selinux/config

 SELINUX=permissive

 NTP Configuration

To install and start the NTP service:

 systemctl enable chronyd

 systemctl start chronyd

Configure CloudStack Package Repository

Create a repository file:

 echo "[cloudstack]

 name=cloudstack

 baseurl=[Link]

 enabled=1

 gpgcheck=0" > /etc/[Link].d/[Link]

NFS Setup

Install NFS utilities:


 dnf -y install nfs-utils

Configure NFS exports:

 echo "/export/secondary *(rw,async,no_root_squash,no_subtree_check)

 /export/primary *(rw,async,no_root_squash,no_subtree_check)" > /etc/exports

Create directories for NFS:

 mkdir -p /export/primary

 mkdir /export/secondary

Start NFS services:

 systemctl enable rpcbind

 systemctl enable nfs-server

 systemctl start rpcbind

 systemctl start nfs-server

MySQL Installation and Configuration

Install MySQL:

dnf -y install mysql-server

Edit MySQL configuration:

 # Add to /etc/[Link].d/[Link]

 innodb_rollback_on_timeout=1

 innodb_lock_wait_timeout=600

 max_connections=350

 log-bin=mysql-bin

 binlog-format = 'ROW'

Start MySQL:

 systemctl enable mysqld


 systemctl start mysqld

Install CloudStack Management Server

 dnf -y install cloudstack-management

Setup Database

 cloudstack-setup-databases cloud:password@localhost --deploy-as=root

Setup Management Server

 cloudstack-setup-management

Download System Template

Copy code

 /usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m

/export/secondary -u [Link]

[Link]-x86_64-kvm.qcow2.bz2 -h kvm -F

Install KVM Agent

Open In Editor

 dnf -y install cloudstack-agent

Configure Libvirt

 Sudo nano /etc/libvirt/[Link]:

Add the following script

listen_tls = 0

listen_tcp = 1

tcp_port = "16509"

auth_tcp = "none"

mdns_adv = 0

Uncomment in /etc/sysconfig/libvirtd:
#LIBVIRTD_ARGS="--listen"

Restart libvirt:

 systemctl restart libvirtd

Access CloudStack UI

Access the UI at:

[Link]

Default username: admin, Default password: password.

VIII. Challenges

 Hard to install cloudstack management and find the right source

 The Cloudstack repository for CentOS 8 was not available, resulting in 404 Not Found.

 KVM is not working

 Network Configuration in Apache Cloudstack are complicated

 Issues with MariaDB configuration, such as socket errors, access denied, or service failures.

 Lack of resource

 Host VM doesn't know Server VM

IX. Results

 Able to access Apache CloudStack Interface

 Able to create 2 VMs for Host and Server

 Able to create Primary Storage, Zones, Pods, Clusters, Hosts, Template and add images

 Able to mount 2disks in 1VM but Apache Cloudstack do not recognize the 2nd disk

 Unable to create secondary storage, instance and other services due to unknown secondary

storage and system requirements (CPU, RAM, ROM).


X. Team Contributions

Team Member Responsibilities


Sang Haksou Report Writer, Technical
Oung Chhunheng Technical
Saveourn Devin Technical
Mom Monychot Slide & Document Preparation

XI. Conclusion

Setting up and managing a cloud environment with Apache CloudStack shows its strong

capabilities in handling virtual resources. The configuration of zones, pods, and clusters,

along with network and storage management, highlights its flexibility and scalability.

Future work will focus on improving and adding more services to the cloud.

References

[1] Apache CloudStack Documentation. (n.d.). Retrieved from

[Link]

[2] Apache CloudStack Installation and Configuration Guide

[Link]

[3] How To Install Apache Cloud Stack v4.15 On Centos 8

[Link]

You might also like