OpenStack PHP and OVH

Some time ago I built a setup using Amazon’s S3 and Cloudfront that would allow large file uploads/downloads directly from the an S3 bucket, through a Cloudfront endpoint (which provided both a lower latency and allowed using SSL on a custom domain). I recently came across OVH, and two things caught my attention – low… Continue reading OpenStack PHP and OVH

WebSockets – Varnish, Nginx, and Node.js

Like many others I have been drawn in by the appeal of websockets and their use in (near) real-time communication. As such one of my current projects uses Node.js and websockets (via socket.io). To maximize compatibility, I would, of course, like my Node.js site to run on port 80. My server, however, is not used… Continue reading WebSockets – Varnish, Nginx, and Node.js

DRBD on Amazon’s Linux

Note: this was done more as an experiment than for something I intended to use in production – so consider it to be more a compilation of notes than a full out procedure. DRBD – Distributed Replicated Block Device – is a kernel level storage system that replicates data across a network. It uses TCP… Continue reading DRBD on Amazon’s Linux

Windowless VirtualBox VMs (Windows Host)

Since I haven’t gotten around to playing with VMware or xen yet – VirtualBox is what I am using for virtualization in my test environment. Under Windows I like to use PuTTy to connect to my VMs – even those running on the same machine. Other than providing a consistent interface, it has a few… Continue reading Windowless VirtualBox VMs (Windows Host)

WordPress – SSL login page without SSL admin

In WordPress (v3.3), FORCE_SSL_LOGIN will transmit login credentials over SSL, however, the login page itself may be accessed over HTTP (as opposed to HTTPS). If the login page is accessed via HTTP, the user has no (easy) way of verifying that the page is legitimate and that the credentials will in fact be sent over… Continue reading WordPress – SSL login page without SSL admin

Installing Corosync on EC2

The notes for this have been sitting on my computer for almost 6 months, but a comment from today spurred me onto editing, updating, and posting them. Corosync is a messaging layer used for high-availability. It serves essentially the same purpose as Heartbeat, but appears to be the project that will supersede it. Currently, it… Continue reading Installing Corosync on EC2

Adding Swap Space to an EC2 Instance

The t1.micro instance comes with only 602MB of memory. Especially under high load, it is quite easy to deplete the available memory – and since no swap space is enabled by default, this can quickly lead to a server becoming unresponsive. Swap space can also allow the kernel to move unused data out of memory,… Continue reading Adding Swap Space to an EC2 Instance

Shrink EBS Root

My EC2 instances are setup to have only the operating system and program files on the root volume, with all other data (logs, mail, etc.) on a second EBS volume. This leads to a very stable root volume, which sees a minimum of changes. Fully configured, my root volume (using Amazon’s Linux) is 1.2GB. The… Continue reading Shrink EBS Root

Installing ApacheBench without Apache on Amazon’s Linux

Having recently switched to a setup with only nginx (and no apache), I found myself wanting to run some tests. As nice as siege is, I rather like ApacheBench (ab). However, I really didn’t want to install all of Apache just to get ab. Quick and Easy Way On Amazon’s Linux, the ab binary can… Continue reading Installing ApacheBench without Apache on Amazon’s Linux