How to build Mercurial 1.5 RPM's on CentOS/Redhat Linux 5

This is pretty easy, but there just a couple things I had to do to make it work so I thought I would document it.

  1. yum install -y rpm-build python-devel
  2. cd /usr/src/redhat/SOURCES
  3. wget http://mercurial.selenic.com/release/mercurial-1.5.2.tar.gz
  4. tar zxvf mercurial-1.5.2.tar.gz
  5. cd mercurial-1.5.2.tar.gz/contrib
  6. edit mercurial.spec and change Version: snapshot to Version: 1.5.2  and then remove the dependency of docutils
  7. rpmbuild -ba mercurial.spec
  8. That’s it - files are now in /usr/src/redhat/RPMS/<arch>/mercurial-1.5.2-0.<arch>.rpm

Posted by Sean Leach 

Finding fastest Ubuntu mirror using CLI

Wrote a quick python script to find me the fastest Ubuntu mirror using only the CLI

% sudo apt-get install python python-beautifulsoup

% wget http://wiggum.com/ubuntu-fastest-mirror

% ./ubuntu-fastest-mirror

Then replace all the hostname’s in /etc/apt/sources.list with the desired mirror

Posted by Sean Leach 

GitHub

https://github.com/

I have been slowly moving from Subversion to Git.  Github is a sweet place to host your repo’s and is a great price

Posted by Sean Leach 

pynids and python pcap development

If you ever need to do pcap development, and you have to support UDP and TCP, pynids is sweet.

We have done some wacky stuff at NeuStar/UltraDNS with it for analysis of some pretty large files (many GB).

Posted by Sean Leach