← Back to the blog

Redirect TCP connections from one IP address and port to another

We’ve just performed a migration from one data centre to another and thus one IP range to another.

We wanted to minimise the amount of down time our clients had as we moved servers between data centres, and also wanted to ensure DNS for their domain names repointed to the new IP addresses in a timely manner.

To minimise the amount of downtime we decided to first repoint our clients’ domain names to their new IP addresses, and then proxy the requests to the old location of the servers.  Then, a week later we would move the servers to the new data centre, give the servers their new IP addresses and then disable the redirection.  This would mean that the downtime would be limited as much as possible.

All in all this worked very well and was very straightforward.

The only hurdle was finding a piece of software that we could install at the new data centre that would allow us to proxy all web traffic requests from one server to another keeping all headers intact.

Fortunately our friends at Firstserv recommended a command line tool called rinetd.  It’s a great little tool that will allow you to redirect any TCP connections from one IP address and port to another IP address and port.

We did give Apache Reverse Proxy a go but it wasn’t easy to get SSL to redirect, and that’s where rinetd came and saved the day.

I hope this helps someone else!

Posted by Niklas Richardson on 14 Oct 2008

blog comments powered by Disqus

From our portfolio

Jo's Trust
Website
JoTrust-Thumbnail
Charis Grants
Application
charis_thumbnail
iMoneymanager
Application
imoneymanager_small
www.flickr.com

Archives

From our blog

We’re looking for Ruby on Rails (RoR) developers to join our team!

Posted by Niklas Richardson on 12 Apr 2012

Monochrome are looking for a couple of enthusiastic Ruby on Rails developers to join the team – Both Lead and Junior/graduate roles. You don’t need to have years of Ruby on Rails...

The need for applications just keeps on growing

Posted by Adrian Munn on 24 May 2011

After 12 years in the industry experience has always told us to adapt and modify strategies in your business in order to survive and thrive. Monochrome are not adverse to taking on new challenges...

Places we would like to go...

Posted by Neil Middleton on 21 Jan 2011

Quite often in the office we will end up having a conversation about some particular company, that does something on a massive scale, and has a relevance to either technology or some sort of large...