Installing HAProxy 1.8 on CentOS6 (With SSL Support)

Haproxy version 1.8 is not available via yum for CentOS 6 so must be compiled manually. Follow the below to do this: Firstly, install pre-requisits sudo yum install gcc pcre-static pcre-devel openssl-devel -y Download and extract Haproxy 1.8 wget https://www.haproxy.org/download/1.8/src/haproxy-1.8.14.tar.gz tar zxfv haproxy-1.8.14.tar.gz cd haproxy-1.8.14 Make and install make TARGET=linux2628 USE_OPENSSL=1 make install Create directories Read more about Installing HAProxy 1.8 on CentOS6 (With SSL Support)[…]

Clearing Docker Container Logs

Finding the large log file To identify the largest log file, run the below command (Based on a standard docker installation): for i in $(docker ps –format ‘{{.Names}}’); do j=$(docker inspect $i -f ‘{{.LogPath}}’); s=$(du -sh $j); echo “$i $s ($j)”; done This will show you the container name, log file size and location for Read more about Clearing Docker Container Logs[…]

Adding a new disk to a linux server without rebooting

This is most useful when using virtualisation platforms such as VMware, Hyper-V etc. When you have added your new disk to your Linux server from your Host, simply run the below command to pick up the new disk without restarting. for HOST in /sys/class/scsi_host/host*/scan; do echo “- – -” >  ${HOST}; done You can now Read more about Adding a new disk to a linux server without rebooting[…]

Downloading Subtitles for all media files on a Server

This guide is based on using CentOS 6 and running Python 2.7. Firstly, install Python 2.7 onto your server: yum install -y centos-release-SCL yum install -y python27 Now enable python27 via scl enable (This will launch a new bash session using the more recent Python version) – You will need to do this again if Read more about Downloading Subtitles for all media files on a Server[…]

Creating a Java Keystore from existing SSL certificate

Follow these instructions if you have an existing SSL certificate from a registered CA (I am using Godaddy in this example) and wish to store these in a Keystore file to be used for Javascript applications. In this instance this was required by Logstash (Part of the ELK Stack). This guide assumes you have already Read more about Creating a Java Keystore from existing SSL certificate[…]

Basic Git commands

Cloning a Repository To clone a repository into a subfolder of your current directory (Eg if you are in /git the repository will be cloned to /git/[repository name]) run the below: git clone [email protected]:project/repository.git Cloning a Repository to a specific directory To clone a repository into a specific directory (Eg /git/example in the below) run Read more about Basic Git commands[…]

Creating AWS EFS Volume and Mounting on AWS Servers

Firstly you will need to create your EFS volume. This can be done from the AWS console, ensure the EFS volume is created within the correct VPC for your servers to access it and note the destination IP addresses provided on the completion page. Now, you will need to install the NFS package on the Read more about Creating AWS EFS Volume and Mounting on AWS Servers[…]