Posts Tagged ‘Basic Linux’

Creating an OpenVZ template in Proxmox

Written by admin on March 15, 2015. Posted in Virtualisation

We use Proxmox in our hosted servers (of which 90 % are voip servers) at . At one time i needed to create a template in proxmox of a CT for use in automatic deployments on the server. Most of the templates i had been migrated from SolusVM. I googled around and found this article However every time i tried to use the method i got a message saying

tar: Cowardly refusing to create an empty archive
Try 'tar --help' or 'tar --usage' for more information.

The solution i found was to create it the following way.

Lets say container is number is 132

in command prompt you must stop the container before creating the image:

vzctl stop 132
Stopping container ...
Container was stopped
Container is unmounted

Go to the private folder:

cd /var/lib/vz/private/

Then start image creation:

cd 132/ && tar -zcvf ../centos-v-1.tar.gz . && cd .. 

Then copy your created file to templates folder:

cp centos-v-1.tar.gz /var/lib/vz/private/template/cache

Thats it you can now start using the template. Remember to specify you OS in the name of your template.

How to change your server time

Written by admin on November 22, 2014. Posted in Basic Linux

Many voip applications require you to use server time for certain purposes. These include reminders, time conditions etc. In order to get correct timing your server needs to be synchronised to the correct local time. This article shows how you can achieve this in Linux.

Login to ssh and type the following commands:


# /etc/sysconfig/clock

Edit the file to look like the following and replace GMT with whatever time zone you want


For the time on the machine to reflect the change timezone we need to link the zoneinfo file to /etc/localtime. This can be done as follows :

If you are setting your timezone to "GMT" link the following file to /etc/localtime :
# ln -sf /usr/share/zoneinfo/Brazil/East /etc/localtime
Now by typing the date command to display the time you should see if reflect the newly linked timezone :
# date
Thu Sep 30 10:06:23 GMT 2014
If the time is still not correct but showing correct time zone then you will need to edit the time using 

# date 011923072014 

to change to 19 January 23:07  2014 for example