Climbing into the cloud with Apache CloudStack
Enabling the Graphical User Interface
I am now ready to start the management server. The server is initialized by the cloudstack-setup-management
command, which also handles the firewall setup and other things:
cloudstack-setup-management Starting to configure CloudStack Management Server: Configure sudoers ... [OK] Configure Firewall ... [OK] Configure CloudStack Management Server ... [OK] CloudStack Management Server setup is Done! /etc/init.d/cloudstack-management start
CloudStack provides a management front end that you can access via http://Management-Server-IP:8080/client/. The combination for the initial login is admin/password. Unfortunately, initialization will take up to 10 minutes – even on a fast machine. Check the logfile in /var/log/cloudstack/management/management-server.log
if you experience problems logging in.
Using Hardware Virtualization
Hardware virtualization is tricky – and not only on Unix. System integrators have the unpleasant tendency to deliver workstations with the VT feature disabled. Fortunately, you can check virtualization support by typing kvm-ok
– the script identifies any errors in the system configuration:
~$kvm-ok INFO: /dev/kvm exists KVM acceleration can be used
Following the initial login, the management server offers an installation wizard. The wizard is particularly useful for people moving from other systems, because it complains about CloudStack configuration errors occurring in the scope of setting up the zone. In this case, the setup fails because CloudStack was unable to create a host, which is only logical because I have not enabled KVM yet.
Granting External Access to KVM
By default, KVM does not accept any external commands. To change this behavior, open the /etc/libvirt/libvirtd.conf
file and add the following five properties:
listen_tls = 0 listen_tcp = 1 tcp_port = "16509" mdns_adv = 0 auth_tcp = "none"
On the newly installed version of Ubuntu, these attributes are disabled by #
. Add the properties in a block below the "Network Connectivity controls" header to save yourself some work. The daemon responsible for monitoring the virtualization service does not listen for sockets arriving via TCP by default. I can change this in the /etc/default/libvirt-bin
file by adding the -l
parameter:
# options passed to libvirtd, add "-l" to listen on tcp libvirtd_opts="-d -l"
After completing this work, you need to restart libvirt
and get rid of AppArmor. You can reboot by entering service libvirt-bin restart
at the command line.
The interaction between the management server and the KVM host can be facilitated if the management server logs in to the KVM host as root using SSH. Ubuntu makes this difficult because it does not support root logins and does not automatically launch an SSH server:
sudo apt-get install openssh-server
You need to modify /etc/ssh/sshd_config
to support root logins. Then restart the server as follows:
sudo /etc/init.d/ssh restart: PermitRootLogin yes
Finally, assign a password to the root user:
/usr/share/cloudstack-management/webapps/client/WEB-INF# passwd Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully
Now click on Infrastructure | Hosts | Add Host in the management window to add new worker machines to the system. If the host cannot log in, you can start looking for an error in the network infrastructure. KVM and CloudStack assume a specific bridge exists in /etc/network/interfaces
. If this is not the case, the cloud management agent prevents the deployment. You can check this out by running the cloud-stack-setup-agent
command on the system acting as the virtual machine server. If the Python script returns errors, see the online documentation and commentary for more details [4].
The management server dumps the commands coming from the host in its logfile. In case of hard-to-solve problems, it makes sense to track logfile entries with tail -f
.
« Previous 1 2 3 4 Next »
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
TUXEDO Computers Unveils Linux Laptop Featuring AMD Ryzen CPU
This latest release is the first laptop to include the new CPU from Ryzen and Linux preinstalled.
-
XZ Gets the All-Clear
The back door xz vulnerability has been officially reverted for Fedora 40 and versions 38 and 39 were never affected.
-
Canonical Collaborates with Qualcomm on New Venture
This new joint effort is geared toward bringing Ubuntu and Ubuntu Core to Qualcomm-powered devices.
-
Kodi 21.0 Open-Source Entertainment Hub Released
After a year of development, the award-winning Kodi cross-platform, media center software is now available with many new additions and improvements.
-
Linux Usage Increases in Two Key Areas
If market share is your thing, you'll be happy to know that Linux is on the rise in two areas that, if they keep climbing, could have serious meaning for Linux's future.
-
Vulnerability Discovered in xz Libraries
An urgent alert for Fedora 40 has been posted and users should pay attention.
-
Canonical Bumps LTS Support to 12 years
If you're worried that your Ubuntu LTS release won't be supported long enough to last, Canonical has a surprise for you in the form of 12 years of security coverage.
-
Fedora 40 Beta Released Soon
With the official release of Fedora 40 coming in April, it's almost time to download the beta and see what's new.
-
New Pentesting Distribution to Compete with Kali Linux
SnoopGod is now available for your testing needs
-
Juno Computers Launches Another Linux Laptop
If you're looking for a powerhouse laptop that runs Ubuntu, the Juno Computers Neptune 17 v6 should be on your radar.