• My little article Cleaning up a Debian GNU/Linux was published at Debian Administration where lot’s of people replied with other ways to achieve the same goals. It was very nice to see all the different approaches with all the different pros and cons.

    In the end I ended up changing my own approach for one that is faster and cleaner so I wanted to share it with you. Still, go to the Debian Administration version of the article and read the comments, they are very cool (thanks to all those who posted!).

    (more…)




  • Cleaning up a Debian GNU/Linux

    by

    You arrive at a Linux server which has some history of neglect. Let’s suppose someone else neglected it but if your new-year resolution is to stop neglecting your beloved server, this applies as well.

    One form of neglect is to install, install, install and never un-install any package. The common utility to perform installation and un-installation of packages is apt-get which adds to the problem because it doesn’t have automatic removal of non-needed dependences.

    PHP and ton of other packages. phpMyAdmin was removed when it was no longer needed but Apache, PHP and the ton of packages remain there.

    Aptitude to the rescue. Aptitude is another package manager front-end like apt-get but it can keep track of automatically and non-automatically installed packages. That means that when you installed phpMyAdmin it was marked as non-auto while Apache and company was marked as auto. When you remove phpMyAdmin all the non-needed automatically installed packages like Apache would be removed.

    (more…)




  • Coders, please, make libraries!

    by

    I am sick and tired of pieces of code arbitrary put together when they do very different things, so I shout:
    Coders, please, make libraries!
    (more…)




  • Much is being said about the excellent capabilities of Erlang to write distributed fault-tolerant programs, but little has been said about how easy and fun it is to write servers (those programs at the other end of the line) with it. And by easy I don’t just mean that you can put up a web server in two lines of code and hope it’ll work, I mean it’ll be easy to built robust servers.

    One example of this is ejabberd, a free Jabber server.

    I’ll start this second part, the one with real networking programming, with a bet. Think about the IPv4 protocol, its header is like this:

    0                   1                   2                   30
      1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |Version|  IHL  |Type of Service|          Total Length         |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |         Identification        |Flags|      Fragment Offset    |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |  Time to Live |    Protocol   |         Header Checksum       |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |                       Source Address                          |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |                    Destination Address                        |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |                    Options                    |    Padding    |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

    you can check RFC791, page 11 for more information. At a glance, the first 4 bits are the version, the next 4 bits the IHL (Internet Header Length), then we have a whole byte, 8 bits, of Type of Service. The next two bytes are the total length and I am already tired of it, you get the picture right?

    Pick whatever language you want (except Erlang, that’s mine now, but it can be yours latter) and think about how many lines of code would take you to parse that beast, the IP header. Think about how much time it takes you to write those lines, and test them.

    Done? come on! really think about it, otherwise the game is boring. Close your eyes, picture the lines of code. If you can’t, go and write some pseudo-code similar to your favorite language to do the parsing. Done? OK.

    Here’s my bet: I bet that I can do it, in Erlang, in far less lines than you! I bet you that I can code it so fast that I’d be finished of writing the code to parse the whole header before you finish the code to parse the first line. And while you are testing I’ll go to the beach because I’ll just trust my code to run without problems.
    (more…)




  • Much is being said about the excellent capabilities of Erlang to write distributed fault-tolerant programs, but little has been said about how easy and fun it is to write servers (those programs at the other end of the line) with it. And by easy I don’t just mean that you can put up a web server in two lines of code and hope it’ll work, I mean it’ll be easy to built robust servers.

    One example of this is ejabberd, a free Jabber server.

    One of the Erlang features that let us write servers is its binary pattern matching. But to understand binary pattern matching first you have to understand pattern matching.

    Let’s start with a classic of functional programming: factorial. This is factorial in Erlang

    fac(N) ->
       if N == 0 -> 1;
          true -> N * fac(N - 1)
       end.

    (more…)




  • Software Release Cycle

    by

    Introduction

    I am writing this description to remember what to do when I reach the time to release one of my various projects1, that doesn’t happen often enough for me to remember the whole process and it is tedious enough to hate it when I forget a step. So, I decided to describe it.

    First I will explain the version numbers I use. At one time I used the Linux version numbers but when I worked in KDE I’ve seen the beauty of their version numbers (if there’s place for beauty in such a thing).

    Then I’ll explain how I create and maintain the various branches, tags and tarballs.
    (more…)




  • Two-in-one DNS server with BIND9

    by

    This tutorial shows you how to configure BIND9 DNS server to serve an internal network and a external network at the same time with different set of information. To accomplish that goal, a new feature of BIND9 called view is used. As a tutorial it’ll walk you through the whole set up, but initial knowledge of BIND and DNS is required, there are plenty of documents that cover that information on the Internet.

    (more…)




Hi, I’m Pablo, this is my web site. You can follow me or connect with me:

Or get new content delivered directly to your inbox.

Join 4,044 other subscribers

I’m writing a book

Stack of copies of How to Hire and Manage Remote Teams

How to Hire and Manage Remote Teams, where I distill all the techniques I’ve been using to build and manage distributed teams for the past 10 years.

I write about:

announcement blogging book book review book reviews books building Sano Business C# Clojure ClojureScript Common Lisp database Debian Esperanto Git ham radio history idea Java Keep on Posting Kubuntu Lisp Non-Fiction OpenID programming Python Radio Society of Great Britain Rails rant re-frame release Ruby Ruby on Rails Sano science science fiction security self-help Star Trek startups technology Ubuntu web WordPress

I’ve been writing for a while: