Nicola Asuni

Systems Engineer

Nicola focused on designing, building and integrating the backend for our application platforms, including automatic deployment, monitoring and backups.

Working with Virtual Machine images

CatN engineers spend a lot of time working with virtual machine images. We have put together this useful list of commonly used commands and procedures to help you get started on your next project.

For simplicity we assume to work with VM images created using the centoskvm.sh shell script, as explained on my previous post “Automated CentOS Virtual Machine Image Creation”.

Read More

Add a virtual storage device to a Virtual Machine

Following our previous article about resizing virtual machine images, we now look adding an additional storage device to an existing VM. If instead you wish to extend the existing VM storage volumes, please consult the article “Resize a CentOS Virtual Machine Image“.

For simplicity we assume that the VM image you wish to extend has been created using the centoskvm.sh shell script, as explained on my previous post “Automated CentOS Virtual Machine Image Creation“.

The file-based virtual storage device acts as a virtualized hard drive for virtualized guests and its creation is quite quite straightforward.

Read More

Resize a CentOS Virtual Machine Image

Following our series of articles about virtual machine images, we now look at a common problem faced by system engineers – what happens when you run out of disk space on your virtual machine? This guide addresses this issue and explains how to expand a CentOS Virtual Machine image, resizing any partitions contained within.

We assume that the VM image to resize has been created using the centoskvm.sh shell script, as explained on my previous post “Automated CentOS Virtual Machine Image Creation“. This is because the resizing script (resizevm.sh) assumes details about storage volumes that rely on the centoskvm.sh having be used. In any case all the steps are illustrated here so you can adapt the commands to your needs.

The resizevm.sh shell script is part of the CentOS-KVM-Image-Tools project that you can clone on your machine using the following command:

git clone git://github.com/fubralimited/CentOS-KVM-Image-Tools.git

Read More

Automated CentOS Virtual Machine Image Creation

This article shows how to create a CentOS Virtual Machine (VM) in unattended mode using a shell script and illustrates the main steps and options to reproduce the process manually.

The following script and commands will create a base image that can be used to deploy multiple nodes from a system like Ansible to define roles for each node. It is very useful for creating clustered virtual environments such as the vCluster stack.

Read More

Advanced PHP error handling in the cloud

LogPipe is a PHP extension module that extends the default PHP error messages with additional information and allows you to pipe the logs to an external program or write them to a syslog facility.

When a user connects to a PHP website hosted on a cloud platform like vCluster, the response may come from different web servers running on different virtual and physical machines. This introduced the problem of needing to aggregate the PHP error logs from different cluster nodes and then split them up again based on the virtual host. Unfortunately the default PHP error message handler does not provide the information or ability to pipe the error logs to an external program, unlike the CustomLog directive in Apache does.

Read More

TCPWebLog – Collecting and Aggregating Web Logs on the Cloud

TCPWebLog is a Free Open Source Software system to collect and aggregate Web-type logs (i.e. Apache, Varnish, PHP, FTP …) from multiple GNU/Linux computers running on a Cloud.

When a user connects to a Website hosted at CatN, the response may come from different Web servers running on different virtual and physical machines. This first introduced the problem of needing to aggregate the logs from multiple cluster nodes to a central log server, and then split them up again based on the virtual host. Here at CatN, for each virtual host we used to write on a central place distinct log files for Apache Access log, Apache Error Log, Varnish, etc. These files are then rotated and processed using other software tools which required a significant administrative overhead.

Read More

How to create TCPWebLog RPM packages for Enterprise Linux

This is a short hands-on tutorial on creating TCPWebLog RPM packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL).

TCPWebLog is a Free Open Source Software system designed to collect and aggregate Web logs (i.e. Apache and Varnish) from multiple GNU/Linux computers running on a Cloud. For more information please read the blog post: TCPWebLog – Collecting and Aggregating Web Logs on the Cloud.

Read More

ServerUsage – Measuring users’ activity on Linux hosts

ServerUsage is a Free Open Source Software system to collect and process usage statistic information from multiple computers running a GNU-Linux Operating System.

Since CatN is a “cluster” hosting company, one of the challenges is to track and analyse the customers’ activity spread on multiple physical hosts for both monitoring and billing purposes. From each physical host we need to collect at regular intervals the total disk I/O, the network traffic and the CPU ticks used by each system user, process and IP address. This “raw” log data must be then aggregated and processed on a central point to extract relevant information.

After spending some time searching for a ready-made solution I decided to start the ServerUsage project to best-fit our needs. This project is now available as a Free Open Source Software, so anyone can freely use and contribute to it.

Read More

How to create ServerUsage RPM packages for Enterprise Linux

This is a short hands-on tutorial on creating ServerUsage RPM packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL).

ServerUsage is a Free Open Source Software system to collect and process usage statistic information from multiple computers running a GNU-Linux Operating System. For more information please read the blog post: ServerUsage – Measuring users’ activity on Linux hosts.

Read More

How to create SystemTap 7 RPM packages for Enterprise Linux

This is a short hands-on tutorial on creating SystemTap 7 RPM packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL).

SystemTap provides free software (GPL) infrastructure to simplify the gathering of information about the running Linux system. This assists diagnosis of a performance or functional problem. SystemTap eliminates the need for the developer to go through the tedious and disruptive instrument, recompile, install, and reboot sequence that may be otherwise required to collect data. SystemTap provides a simple command line interface and scripting language for writing instrumentation for a live running kernel plus user-space applications.” — source http://sourceware.org/systemtap/.

Read More