Install Amazon AWS awscli

awscli is a command line tool for Amazon AWS. To install, run

You can find more details at

Once installed, you need to configure it

To sync content of a folder to Amazon S3 bucket, run

Whitelist IP in AWS security group using awscli
Amazon AWS create key pair using awscli
AWS Cloud​Formation

See aws


Webmin is an open source control panel to manage Linux and FreeBSD servers.

Download Latest source distribution from

To install webmin in Ubuntu/debian, edit


Add GPG key

Install webmin with apt

LetsEncrypt SSL for webmin server
Webmin create new admin user from command line

See Hosting Control Panel

Enable sar in Ubuntu

On Ubuntu, when i run sar, i get error

This is because sysstat is not enabled by default on Ubuntu, to enable, edit file


Replace with

Now restart sysstat

See sar

Running MySQL inside docker

On a Cpanel Server with old version of PHP, one of the application require MySQL 5.6 to work. Since PHP version is no longer supported, updating MySQL using WHM will upgrade PHP to one of the supported versions, that may break existing sites. So i decided to install MySQL inside docker.

First create a folder for MySQL docker to store data.

Now run

For MairaDB 10.1, run

Here i used “KqAtPd3BpyKjQ” as password, replace it with your password.

-p 3307:3306 -> tell docker to map port 3306 inside the docker container to port 3307 on host machine.

This will pull MySQL docker image and start it.

Once it finished download, you can check if its running with command

To connect to MySQL use

Auto Start on Boot

To start the container on boot, you can run

Or use /etc/rc.local, this may not work with newer versions of Ubuntu/debian


Docker Install

Docker Basics

Docker Delete Conatiner/Image

Run Application in Docker Container

Creating Docker Images

Docker Tools

Using Docker

  • Docker Nginx Proxy
  • To install docker, run

    Install docker compose

    Check docker is working

    To list all running docker containers

Backup with tar

To backup a site using tar, i created a shell script.

With following content

For weekly backup

Make it executable

Create backup folders

Set cronjob


See backup


Auto backup all your MySQL databases daily, weekly and monthly.

To install on Debian/Ubuntu, run

To manually backup, run

MySQL backups will be stored in folder

See backup


Install zfs file system on Ubuntu

Listing ZFS file systems

List pools

Show current IO usage

To see status

Setup ZFS file system in Ubuntu


To test mail using sendmail, use

Dot in last time tell sendmail that message body is ended and it can send mail.