Monday, 28 December 2015

*WARNING* URLGET set to use LWP but perl module is not installed, reverting to HTTP::Tiny in Ubuntu Linux server while configuring Config Server Firewall

If you are getting this warning message while configuring Config Server Firewall (CSF), you can fix it by installing the missing perl module.

To install this perl module, use below command :

apt-get install libwww-perl

Friday, 18 December 2015

Install node.js on Ubuntu 14.04 linux server and configure a hello world node.js application using pm2 and varnish

Node.js is an open-source, cross-platform runtime environment for developing server-side web applications. Node.js applications are written in JavaScript and can be run within the Node.js runtime.

Node.js is primarily used to build network programs such as web servers, making it similar to PHP.The biggest difference between PHP and Node.js is that PHP is a blocking language, where commands execute only after the previous command has completed, while Node.js is a non-blocking language where commands execute in parallel, and use callbacks to signal completion.

Saturday, 5 December 2015

Fatal error: Call to undefined function pcntl_fork() while running pcntl_fork as apache module

In the last post, we have seen that how to install pcntl modules in php and enable them. But if we are running php as an Apache module, you will get the following error :

Fatal error: Call to undefined function pcntl_fork()


Friday, 4 December 2015

Install and enable "pcntl_fork" php module in ubuntu 14.04 LTS

pcntl_fork is a php module which will enable the parallel processing and multi threading in php programs. To install it use the below steps:


Sunday, 22 November 2015

How to upgrade drupal using drush command line tool?

Drupal can be upgraded using nice command line tool called "drush" (drupal shell). If you are using Ubuntu, you can install it by the following command :

$ apt-get install drush

Now change the site to maintenance mode using below command :

Sunday, 8 November 2015

Wire App - A Skype alternative from the people behind Skype

Skype has been sold to Microsoft. It is one of the most used communication platform among people. Your nanny to your new born baby uses Skype to connect with each other, especially if your family spread across the globe.

But the people behind Skype were not yet happy and so went ahead and created another communication app this time called Wire . You can just visit their pages to see how beautiful the app is.


Saturday, 7 November 2015

Breach - A modular Web Brower

I have recently stumbled upon an alternative browser based on Chromium called Breach.

It is a modular browser which can easily be modified using HTML and CSS


Thursday, 5 November 2015

Dooscape - QtWebKit browser inspired on Modern UI

Dooscape is a new browser which has a beautiful UI and it is based on Qt.  The features include :


  • Lock the web browser using password, just like locking your computer screen
  • Beautiful UI
You can download Dooscape from the GitHub repository.

Tuesday, 3 November 2015

Babun - Linux like shell for Windows

If you have to use Windows occasionally during your sysadmin tasks and feels like you are missing the linux terminal, worry not. A new application aims to fix this for you.


Wednesday, 28 October 2015

How to fix mod_fcgid: read data timeout in 40 seconds error in cPanel

I was getting the below errors in one of my cPanel servers:

[Wed Aug 26 17:33:54 2015] [warn] [client 111.222.33.456] mod_fcgid: read data timeout in 40 seconds
[Wed Aug 26 17:33:54 2015] [error] [client 111.222.33.456] Premature end of script headers: update.php

To fix this error, we can follow the below steps:

Monday, 26 October 2015

Install HHVM in Ubuntu Linux Server for high performance PHP applications and high performance wordpress websites

HHVM (HipHop Virtual Machine) is an open-source virtual machine designed for executing programs written in Hack and PHP developed at Facebook. HHVM uses a just-in-time (JIT) compilation approach to achieve superior performance while maintaining the development flexibility that PHP provides.

HHVM runs much of the world’s existing PHP. Developers and hosts are adopting HHVM. It can run the top 20 Github PHP frameworks out of the box. The HHVM team, along with many wonderful community members, has made it a stated, high priority goal to run all existing PHP code existing out in the wild.

Friday, 23 October 2015

How to set up a CentOS 7 server (systemd) with basic services installed

Here is the step by step guide to install and configure CentOS 7 server which uses SystemD for the service management. So the commands are slightly different from what we are used:

Tuesday, 20 October 2015

Saturday, 17 October 2015

Install and configure Monit for automated monitoring, alerting and restarting of services in Linux

Monit is a utility for managing and monitoring processes, programs, files, directories and filesystems on a Unix system. Monit conducts automatic maintenance and repair and can execute meaningful causal actions in error situations. E.g. Monit can start a process if it does not run, restart a process if it does not respond and stop a process if it uses too much resources. You can use Monit to monitor files, directories and filesystems for changes, such as timestamps changes, checksum changes or size changes.

Monit is controlled via an easy to configure control file based on a free-format, token-oriented syntax. Monit logs to syslog or to its own log file and notifies you about error conditions via customisable alert messages. Monit can perform various TCP/IP network checks, protocol checks and can utilise SSL for such checks. Monit provides a HTTP(S) interface and you may use a browser to access the Monit program.

Friday, 16 October 2015

How to force HTML to run as PHP

We can use Apache Handlers to force HTML pages to execute as PHP scripts.

So to do this. add the below line to .htaccess file:

AddHandler application/x-httpd-php5 .html .htm


Thursday, 15 October 2015

Set up a server using Webmin Control Panel

We will be using below steps to set up a server using Webmin Control Panel and Ubuntu.

Operating System : Ubuntu 14.04 LTS
Control Panel : Webmin
Database : MySQL Server 5.6
Web Server : Apache web server
Database Management : PhpMyAdmin
DNS : BIND Name Server
FTP : ProFTP server

Saturday, 12 September 2015

How to manually edit the httpd.conf in cPanel to change the Document Root for configuring SSL certificate for a sub domain?

I have faced this issue after installing an SSL certificate for a sub domain (sub.domain.com). The certificate was correctly installed but it is redirecting to default cPanel page. On further inspection I found out that it was because the Document Root of the https (SSL) version of the sub.domain.com is set to default /usr/local/apache/htdocs .

How to fix this issue? If we edit the DocumentRoot in /usr/local/apache/conf/httpd.conf for the sub.domain.com:443 and then running

How to configure HA Proxy Load Balancer for HTTPS connections by SSL forwarding and without using SSL termination?

Here I'm showing how to configure ha proxy for https connection. How ever, this is not showing ssl termination at load balancer end. Here the load balancer will listen for https connections on port 443 and forward them to web01 and web02 servers to 443 port.

Pre-requisite is that you need to install SSL certificates on web01 and web02 servers.
If you are using cPanel server like me, you can generate the ssl certificate on web01 server and install it there.Then copy paste the private key, cert and ca bundle on web02 server to install it there too.

Saturday, 13 June 2015

Install aspell dictionary in linux

To install "aspell" in linux, follow the below steps:


cd /usr/local/src
wget ftp://ftp.gnu.org/gnu/aspell/aspell-0.60.6.tar.gz
tar -xvzf aspell-0.60.6.tar.gz