Category Archives: Linux - Page 16

Loading different website content based on country with GeoDNS

Have you ever wanted to serve different DNS records out based on the location of the originating request?

Using the GeoDNS Bind patch we can have example.com resolve to a server in the US only if the requesting IP address loading the page is based in the US, and then have all other requests forward onto a server based in another country. You will be able to point a request for a domain from any country code to specified DNS records with this method.

This can be beneficial for many reasons, it will allow faster website page load times in different countries due to all content being served by the nearest server. It also allows you to run up different websites for the same domain in different countries as these will be running on different servers.

Read more »

Compiling the Haskell Warp web server

In my process of benchmarking various web servers I have come across the Warp web server, which runs using Haskell. Warp is supposedly the fastest Haskell based web server and having learned Haskell a few years ago I was keen to see what it could do.

I will be going through the process I took to get Warp up and running as this is my first time using a Haskell web server and I had some problems getting it going.

Read more »

Compiling Synergy from source on the Raspberry Pi

Recently I set up my Raspberry Pi and the first thing I wanted to do to make it usable was to get Synergy working. Synergy is a program which you can use to essentially connect two computers together so that you can interact with both using just one keyboard and mouse.

I’ve previously used Synergy on x86_64 based operating systems without problems, but never on ARM – which involved compiling Synergy from source. As I had a few problems along the way to solve I figured this post would be useful for people going through the same process.

Read more »

Unboxing and setting up the Raspberry Pi

Raspberry Pi unboxed

I recently purchased a Raspberry Pi as a cheap and low power alternative PC to leave online 24/7. This is just a quick post covering with a few pictures of the unboxing and set up process I went through with the Raspberry Pi.

Read more »

Installing Apache 2.4 and PHP 5.4 from source

I’ve just been through the process of installing the latest versions (as of this writing) of Apache 2.4.2 and PHP 5.4.5 from source on a new Debian 6 virtual machine for the first time.

I had some small issues along the way and thought I’d do a short post on the process I went through to get it working and resolve various errors which may help someone out. First we will install Apache, followed by PHP.

Read more »

Introduction to Varnish caching

Over the last week I’ve had my first attempt at setting up a Varnish environment which is something I’ve wanted to have a go at for a long time and I thought it would be worth sharing what I’ve learnt during that process. I was quite surprised at how simple it was to get going, and by the performance provided. This will just be a brief introduction that will probably be expanded on in future Varnish related postings.

What is Varnish caching?

First off for those that do not know, Varnish is a web application accelerator that will cache content from any web server such as Apache, Nginx or IIS and serve it up much faster. Varnish is able to do this because it caches various contents meaning that less resource intensive strain is placed on the web / database server, providing a more responsive and stable server environment with higher capacity. Put simply, Varnish will speed up a website quite significantly.

Rather than having to execute PHP scripts, run MySQL queries or perform some other tasks on the server for every page view received you can have Varnish with the content cached and ready to serve out over the Internet.

Varnish can be run on different flavours of Linux and does not require it’s own server to run. You could easily set up Varnish on the same server you have the web server running on, however I was more keen to set up a test that can be expanded in the future if needed by adding either more varnish cache servers, or web servers.

Read more »