Installation of Usage Server on Apache CloudStack 

Installation of Usage Server on Apache CloudStack
This tutorial focuses on the steps to install and configure the Usage Server on Apache CloudStack. 

 

Apache CloudStack is a free and open-source Infrastructure as a Service (IaaS) platform that orchestrates and manages pools of the network, storage, and other computer resources to build a private or public IaaS compute cloud. Apache CloudStack allows any IT service provider to offer public cloud services to their customers. It can also be used by companies who wish to offer hybrid and private cloud services to their users. 

In this tutorial, we will learn the steps to install and configure the Usage Server on the Apache CloudStack server. 

 

Installing the Usage Server 

 Once the Management Server is installed in Apache CloudStack, users can install the Usage Server. The Usage Server helps transfer data from the system’s events and enables usage-based billing for its accounts.

When there are multiple Management Servers, users can install the Usage Server on any number of them. The Usage Servers will adjust and coordinate the usage processing in the server. A website that is concerned about its availability should install Usage Servers on at least 2 Management Servers.

 

Requirements for Installing the Usage Server 

The requirements to install the Usage Server on the Management Server of Apache CloudStack are: 

  • The Management Server should run even after the installation of the Usage Server.
  • The Management Server and the Usage Server must be installed on the same server.

 

Steps to Install the Usage Server 

To install the Usage Server on Apache CloudStack, follow the below steps: 

  • First, make sure that the package repository is already configured. If not, configure the package repository before moving forward. 
  • Next, install the cloudstack-usage package by executing the following command:

          On RHEL/CentOS systems, use:

 # yum install cloudstack-usage

 

          On Debian/Ubuntu systems, use:

# apt-get install cloudstack-usage

 

  • Once the installation is completed, start the Usage Server by executing the following command:
 # service cloudstack-usage start

 

  • After that, enable the service at boot by executing the following command:

          On RHEL/CentOS systems, use:

 # chkconfig cloudstack-usage on

 

         On Debian/Ubuntu systems, use:

# update-rc.d cloudstack-usage defaults

 

Configure the Usage Server 

To configure the Usage Server, follow the below steps: 

  • First, log in to the CloudStack User Interface as administrator.
  • Go to the Global Settings.
  • In the Search tab, search for Usage. Find the configuration parameter that controls the behavior the user wants to set. See the following table for a description of the available parameters.

 

Parameter NameDefinition
enable.usage.serverWhether the Usage Server is active.
usage.aggregation.timezoneTime zone of usage records. Set this if the daily job execution and usage records are in different time zones. Default: GMT
usage.execution.timezoneThe time zone of usage.stats.job.exec.time. Default: Time zone of the Management Server.
usage.sanity.check.intervalThe number of days between sanity checks. Set this to periodically search for records with erroneous data before issuing user invoices.
usage.stats.job.aggregation.rangeThe time period in minutes between Usage Server processing jobs. Default: 1440
usage.stats.job.exec.timeThe time when the Usage Server processing will start. It is specified in HH:MM (24-hour) format in the time zone of the server, which should be GMT. Default: 00:15

 

  •  For example: 
enable.usage.server = true
usage.execution.timezone = America/New_York
usage.stats.job.exec.time = 07:00
usage.stats.job.aggregation.range = 1440

 

  • After that, click the Edit icon in the Action section.
  • Enter the desired value and click the Save icon.
  • Finally, restart the Management Server and the Usage Server:
# service cloudstack-management restart
# service cloudstack-usage restart

 

Limiting Resource Usage in a Domain

To set a domain limit in Apache CloudStack, follow the below steps:

  • First, log in to the Apache CloudStack UI.
  • In the left navigation tree, click Domains and select the domain that the user wants to modify. The current domain limits are displayed (the value of -1 points that no limit is set).
  • Next, click the Edit button and edit the following as per the user requirement:

 

Parameter NameDescription
Instance LimitsThe number of instances that can be used in a domain. Default: 20
Volume LimitsThe number of disk volumes that can be created in a domain. Default: 20
Public IP LimitsThe number of public IP addresses that can be used in a domain. Default: 20
Snapshot LimitsThe number of snapshots that can be created in a domain. Default: 20
Template LimitsThe number of templates that can be registered in a domain. Default: 20
VPC limitsThe number of VPCs that can be created in a domain. Default: 20
Secondary Storage limits (GB)The secondary storage space that can be used for a domain. Default: 400
Memory limits (MB)The number of RAM that can be used for a domain. Default: 40960
CPU limitsThe number of CPU cores that can be used for a domain. Default: 40
Primary Storage limits (GB)The primary storage space that can be used for a domain. Default: 200

  

  •  Finally, click the Apply button to set the domain limits.

 

Conclusion 

This tutorial presents the steps to install and configure the User Server on Apache CloudStack. Hope this tutorial was helpful, and do reach out to us if you have any query or suggestions.

 

Share this post

Services to Explore

Stay up to date!

Stay up to date with the Web Hosting, Cloud and Server Management Industry News and Tutorials!

We will send you only the relevant emails, and we respect your privacy. Please review our privacy policy for more info.

Apache CloudStack Management

Focus on your business, and let us take care of your Apache CloudStack!
From what you are reading, it seems you are interested in Apache CloudStack and related technologies. If you have a moment to spare, please take a look at our Apache CloudStack Management plan, which might interest you even more!
Apache CloudStack Management

Value-Added Services

We have services that can help you run a successful business. With us, you don't have to worry about these areas because our experts will take care of it for you.

ServerHealers uses cookies.