Server Backups with s3cmd

I've been asked a few times how I back up my servers at Digital Ocean. It seems this topic is quite popular due to the fact they just started charging for automated backups on the 1st of July. In this article I'm going to go through the process of using s3cmd with Amazon S3 to easily backup and restore your servers. Although I use Digital Ocean as my own hosting company, and this is where this backup system is in place, it can just as easily be transferred to any hosting provider.

Install RabbitMQ on Ubuntu 12.04 Quickly

I've put together this simple install script that I compiled from the various tutorials on the rabbitmq site. It's not intended to be anything new or that isn't easily accessible; It's simply the quickest way I've found to get up and running with the web interface out of the box.

Awesome Tools I've Been Using

I recently just passed my probation period and got hired full time at Performance Horizon which means I get to work on awesome technology with a great team for the foreseeable future! Over the last 3 months I've met really interesting people, attended conferences and meetups, worked on complex edge cases and compiled quite an inventory of tools I use in my daily work. This post is pretty much a summary of those tools and my opinion on why I think you should give them a try. I've included all the links to the mentioned projects at the bottom of this post.

Beware of Hamachi IPv4 Subnet

Today I found a major flaw with a piece of software I use heavily every single day, as do a lot of people I know. Logmein Hamachi is currently using the 5.0.0.0/8 subnet, which has recently (Novermber 2011) been assigned to real users and conflicts are beginning to happen which is a major issue. Basically, the problem makes any service running in this subnet to appear invisible to Hamachi users, and webhosts are starting to assign these addresses to real users by the looks of it. I stumbled across this issue when connecting to a demo server at the company I now work for. Other people in the office could connect, yet I couldn't. The machine just appeared dead until I noticed the IP was in the 5.0.0.0/8 range! Of course the easy way to fix this is to enable IPv6 only mode from within Hamachi. Luckily for me, all of my servers and Macbooks support this so the transition was easy, however a lot of people who use Hamachi use it for legacy gaming for LAN matches, which certainly won't support IPv6 as many other services won't yet or ever will. The worrying thing right now is this is actually the official “fix” from Logmein for the issue. From my research it turns out other services such as EasyVPN are also using this address range, and it was common ground for this subnet to be used for VPNs so I can imagine quite a few connectivity issues arising when more of these IPs are given to services. People are reporting problems with people connecting to their websites, which is never good. So next time a site is down for no apparent reason, try pinging it to see if the IP is in the above address range, if it is and you have Hamachi (or other VPN service) you might want to think about converting to IPv6 or disabling it all together. Hope this helps someone avoid hours of confusion, as there is no way to really “debug” this unless you are familiar with the fact all Hamachi IPs have the same subnet. Have any of you guys noticed problems with other VPN providers? Feel free to share your thoughts in the comments.

MongoDB MMS via Hamachi VPN

Today, I stumbled across a great way to use 10gen's MMS system with my Macbook Pro today without any kind of router reconfigure, firewall rule changing or even opening up mongod to the outside world. I simply took advantage of my personal Hamachi network with spans across all of my laptops, desktops and deployed servers. This is actually a paid Hamachi Pro account with 32 clients, but you can get a free one that allows up to 5 machines. Since I had the agent running on a server with Hamachi installed, I was simply able to go to the MMS control panel and add the internal network IP of my Macbook Pro. Even though it's an internal network, the MMS python agent makes requests from your agent machine, then connects with MMS separately, so the connection to my Macbook goes entirely through Hamachi and bypasses the outside world. This also has the advantage of being totally encrypted, and follows my machine wherever I go without having to update the IP inside MMS. The advantages of this are amazing, as it allows you to monitor and profile your local development environment without any extra tools and accompanied by mongostat it's a great way to find out what's actually happening on your machine. However, one downside of this is you have to re-enable the host in MMS if you've had your machine turned off for a while, as it becomes deactivated, but that's simple enough just to login and click the re-enable link. I'm always trying to find out useful new ways to make development easier, feel free to share any of your own!

It's September already?

Where has the time gone! I've been working at my new job for almost a whole month now and it still feels like I've just started! For those of you that don't know I'm now a programmer at Performance Horizon which is pretty awesome; quite the change from flash gaming! It's also the main reason I've been neglecting my personal projects and blog updates to concentrate all the cool things I've been working on.

Streaming Media from Linux to Xbox 360

Today I woke up with the vision of watching Dexter while working on my laptop because I'm sick of sitting at my desk. This left me with 4 options; Stream from Desktop, Stream from Laptop, Use USB Stick or Stream from new Linux Server. Each of these options has it downfalls, and one best solution, which I'm going to describe below.