Installing MaraDNS on CentOS Linux

Linux command line programMaraDNS is a lightweight alternative opensource DNS server for Linux. MaraDNS has some really interesting characteristics:

  • Low memory usage – On an OpenVZ VPS ( CentOS 5.x host node ) MaraDNS uses about 5MB of RAM as opposed to 90-100MB for the venerable BIND.
  • Separation of recursive nameserver and authoritative nameserver – If you only need an authoritative nameserver for your domain names you can skip starting up the recursive nameserver service.
  • Ease of installation – MaraDNS is easier to install than other alternative nameservers like tinydns.
  • Excellent documentation – The documentation on the MaraDNS site is quite good at explaining things in simple language.

So let’s take a look at how we can get started with MaraDNS on CentOS Linux.

Continue reading

Ajax Whois WordPress Plugin

Ajax Whois for WordPressAjax Whois for WordPress is a plugin that allows you to add a domain name lookup form to your WordPress blog posts or pages. This WordPress domain search plugin is fast, supports dozens of Top Level Domain names and has lots of options for customization.
Continue reading

Converting a string to a number consistently using PHP

Say you want to convert strings to numbers such that a string will always convert to the same number. So for example the string
“red” will always convert to 2 or the string “blue” will always convert to 1. You don’t know which strings you are going to get and the exact number they convert to doesn’t matter just that it always converts to the same number. The reason you want to do this is to pick a value from an array based on that string-converted-to-a-number i.e. you want to use the string-converted-to-a-number as the array’s index or key. How do you do that conversion using PHP?
Continue reading