Archive for Free Software

LLXC: My little python3-lxc based project

// September 29th, 2012 // 7 Comments » // Free Software

My foray into the world of LXC and RLXC

A few months ago, I started trying out LXC (Linux Containers). Before that I used to use OpenVZ, which is an older and more mature contextualization implementation. I was pleased with how well LXC worked and started replacing my personal OpenVZ hosts with LXC.

It worked great, but it had a few quirks. While LXC itself works well, the user scripts that ship with it has some space for improvement. The lxc-list command lists anything that’s a directory in /var/lib/lxc, so if you have a lost+found directory, it will list it as a container (This has since been fixed upstream). Also, in some cases it would list containers twice or not at all. I was a bit annoyed with that, since OpenVZ’s “vzlist” tool prints out a nice table of your containers along with their IP addresses and other information. Since it’s very trivial to implement what I want in a shell script, I went ahead and did just that and called it RLXC.

I also missed the “vzctl exec <containername> command” to execute commands in containers and “vzctl enter <containername>” to gain a shell inside the container, so I added some more functionality to it so that I could configure ssh keys for these containers and use “rlxc enter” and “rlxc exec” like I used to do with the OpenVZ tools, but by using SSH.

I also realised that there are others too who wanted similar improvements in the LXC scripts and decided to continue improving RLXC and making it public.

Enter LLXC

I spoke to Stéphane about my ideas at the time and he introduced me to python3-lxc that he introduced on his blog yesterday. It provides Python bindings for liblxc, so I took the advantage of that and mostly re-implemented RLXC in Python and called it LLXC. The name doesn’t particularly mean anything, I’m open to suggestions for what to call it, if anyone cares.

Here are some screenshots that explains some of it better than I could do in words:

How to get it

As Stéphane mentioned in the python3-lxc blog entry, the API hasn’t yet been finalized and llxc itself is in an early state and many changes are planned, so it’s definitely not meant for production use yet, but since we believe in “release early, release often” in the free software community, here goes…

Currently, itself is *very* Ubuntu specific and its only been tested on Ubuntu 12.04, but that will be fixed once more of its kinks have been ironed out. Some people are also working on getting python3-lxc on other distributions, which will help a lot.

The script itself is hosted on Github:

For python3-lxc and friends, you need to enable Stéphane’s experimental PPA:

You will then need to install the following packages: lxc, python3-lxc, python3-crypto, lvm, btrfs-tools

To generate the ssh keys used for ssh interaction between the containers, you need to run “llxc gensshkeys”.  The “enter” and “exec” commands also rely on your containers being in dns or in your /etc/hosts file, at least for now, which you may have to configure manually.

The Future

There is a lot that I’m planning to add, mostly to scratch my own itches. These include:

  • Awareness of other hosts, so that the list command can show you all containers in the “awareness”. You’d also be able to clone, move, etc containers between hosts.
  • Easily modify container configuration
  • Hooks everywhere, and at least one hook for configuring a configuration management system such as salt, bcfg2, puppet or chef.
  • More checks and tips everywhere. Is the host running low on memory? Disk space? Perhaps list available resources on variable hosts and make some suggestions based on that.
  • There a not-very-descriptive ROADMAP file in the distribution, check that for more details.

I’ll have some packaging for this available soon and work on making more things work right out of the box, updates will follow. Also, feedback and patches are very welcome!

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon


// September 5th, 2012 // 2 Comments » // Free Software

If there’s one thing that I’ve had missing in my life for way too long, it’s hacking on small silly stupid amusing little things. When I was young I used to write dozens of little pointless programs a week and forget about them, only to found them a few months later and be incredibly amused by them.

This afternoon I noticed that one of my machines didn’t have my default .bashrc loaded, which colourises (or ‘colorizes’ for Americans or ‘colourizes’ for Canadians) my shell so that I know on which machine I am so that I don’t accidentally do something silly like reboot the wrong host. One problem I’ve had with this is that there are limited colours available that makes sense to use for a shell prompt. Right as I was thinking this, I was looking at my Byobu screen sessions and thinking “Hmm! I like those logos, maybe I could use them in my shell!”.

So in just a few minutes I had a little script to help you configure those for your shell. Here is a screenshot of the shell logos in action. On my laptop I use a red background when I have a root shell:

This is what the shello script looks like that sets it up:

I might get bored by seeing it soon and get rid of it, but at least I had a little fun with it.

If you’d like to try it out, then you can get the script right here:

It doesn’t do anything like validating input yet, I’d also like to add something that creates some kind of a checksum of your hostname and choose a unicode character based on that. Maybe I’ll finish it up this weekend, or maybe I’ll have new things to write about!

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon

Wheezy Theme Updates

// August 24th, 2012 // 7 Comments » // Free Software

Joy Theme

When the Joy theme was picked as the chosen theme for Debian 7.0 (Wheezy), I wanted to do what I could to get as much of it in the archive as possible before the freeze that occurred in June. I’ve been working with Paul Tagliamonte and Vagrant Cascadian and I’m glad that it resulted in some nice things!

The Joy theme is modest and beautiful and I think Debian 7.0 is going to be one of the best looking Debian releases so far.

Joy Plymouth Theme

Plymouth is the part that provides the boot splash. It also takes care of a few other things, like showing prompts and progress indicators for filesystem checks, password prompts for encrypted devices and more so that the splash doesn’t need to exit to show those. It’s very scriptable, The installers for the Genesi Efika range of devices even use it for it’s front-end.

I needed to start with a Plymouth theme where I knew the prompts for all the things that happen during boot was at least more or less implemented, so I started off with one that I know works well, the Edubuntu one. So, fun fact: Debian 7.0’s Plymouth theme is actually based on the Edubuntu one.

I had to play with the colours a bit to get it right, Edubuntu has a light background so I had to invert contrast for things like the input box, but I think it came out nicely.

Splashy isn’t in the archives anymore and it’s not widely used anymore, so I cleaned it up from the desktop-base package so that there’s less clutter shipped with it.

Joy LTSP/LDM Theme

This screenshot actually looks a bit uglier than it should because I took it on a VM that doesn’t have 24bit colour, but we’re looking into what we can do to make it look better on 16bit colour as well.

During Debconf in Nigaragua, Vagrant and I worked on getting the LDM theme in shape. I have already done what I thought was most of the work by the time Debconf started, but it turns out there was a lot more to it to do it properly. We managed to get rid of the gtk2-engines-murrine dependency, which in itself is quite tiny, but it’s a bit backwards in that it depends on the whole rest of the murrine-themes which brings in too much. We took the time to get the dependencies/recommends/etc right and to make it the default theme in Debian without messing it up for any Debian derivatives. It all came together and now when you install LTSP on Debian, you get the Joy theme by default! I’m really glad about that because I didn’t get the Spacefun LDM theme done in time for the Squeeze release. Enjoy!

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon

Debconf 12 – Managua, Nicaragua

// July 14th, 2012 // 3 Comments » // Free Software

It’s the last day of Debconf 12 in Managua, it’s the first ever Debconf I’ve attended and it has been just awesome.


There’s so much I could talk about and it would take forever to put down, but here’s a few highlights for me:

  • My first time in Nicaragua and also Central America! First time I’ve ever seen a vulcano!
  • The Bits from the DPL talk was great, Zack pretty much hit several nails on the head of why I love the Debian project so much
  • The Debian Cheese and Wine party was off the wall, the food and the drinks were awesome and it was a lot of fun
  • I’ve been attending some of the Debconf  organising sessions, I was considering getting a few people together so that we could put in a bit for Sherbrooke for 2016, but then I learned that a bunch of people are already getting together to put a bid together for Montréal in 2014, so I’ll get involved with that instead. Stefano and I have also been talking about a hypothetical Debconf in 2018 or 2020 in Cape Town or Stellenbosch. As much as we want a Debconf in Africa, neither of us will have time to organise a team for that in the short term. I’m hoping that being involved in the Montréal bid (and hopefully an event) will give me good experience for the Cape Town one.
  • The day trip in the middle of the week was great. I just spent the whole day lying in a hammock, drinking beer and staring at the ocean. I think I needed that.
  • The Debian key signing party was good,  I got my key signed by more than 20 Debian contributors this week.
  • The sessions and BoFs were great. I learned a lot about the Debian project this week and filled up a few gaps in my knowledge.
  • I got involved with the video team and played camera man for a few sessions for the live video feeds. It was surprisingly fun. I took some photos too during the week but my camera is really awful, I need to get a new one by the next Debconf.
  • The people of Nicaragua are awesome. Everyone here is so friendly and helpful. The local team has been absolute professionals from start to finish.
  • There’s probably too much other things to mention and I’ll never get a blog entry out if I even try, but thanks to everyone who made this Debconf possible, even Pollito.


SociBook Digg Facebook Google Yahoo Buzz StumbleUpon

Facebook ads for MOTU?

// July 4th, 2012 // 6 Comments » // Free Software

MOTU Outreach

During the last Ubuntu Developer Summit, developer and contributor outreach was a topic that came up in a wide variety of sessions. In one of the sessions where we discussed the future of MOTU (the Ubuntu Masters of the Universe team), Evan Broder suggested that we try channels that might not necessarily be the usual geeky channels, like just taking $25 and buying some Facebook ads.

I’ve never bought any Facebook ads before and thought I’d give it a shot. I didn’t have time to prepare a nice campaign, or a nice landing page or anything fancy, but instead of putting it off until I can I decided to just run with it and see what happens.

I merely created an ad that said “Want to improve Ubuntu? Join the  Ubuntu Masters of the Universe team and help fix bug and upload packages!”. It linked back the the Ubuntu MOTU wiki page, which isn’t exactly glamorous, but it contains a lot of useful information on how to get involved.

Impressions and Clicks

Facebook lets you choose which targets you want to focus on. It even suggested a few, I mostly stuck with the defaults that it suggested and tweaked a little. This ended up being the targets:

This advert targets 129,520 users:

  • who live in one of the countries: United States or United Kingdom
  • who like ubuntu, linux or #OMG! Ubuntu!
  • who speak English (UK) or English (US)
  • who are in the category Science/Technology or the category Computer Programming
The ad was displayed a total of 20 661 times. That’s what Facebook considers it’s “outreach”. So out of the 129 520 users who were targeted, it was displayed for 20 661 of them.  59 people clicked on the link (that’s about as far as you can get with $25).

Did it work?

Well, did it get more people interested in contributing to Ubuntu? I have no idea. This experiment was mostly to see what $25 gets you in ads. Evan said he’s still up for contributing $25 for something like that, so perhaps we’ll do another round and make it more campaign like and more targeted. I’m actually somewhat dissapointed with the stats that Facebook provides. I was hoping for something more like Google Analytics where you could see where your visitors are from, which language they speak and which interest lead them to the ad. Maybe we’ll just try out Google ads next.

I actually think that it’s easy enough to target people via social networks like Google+. There are so many geeky people on there and from what I’ve seen, people are quite eager to share information that’s put together well and worth while sharing. It’s probably possible to put together a really good, effective campaign without even spending any money on it.

Any thoughts? Please share!

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon

I’m going to Debconf 12!

// June 18th, 2012 // 1 Comment » // Free Software

After wanting to attend Debconf for so long, things finally got real. No visa issues this time (Nicaragua is nice like that), tickets are booked… everything is ready! I’m excited to finally be able to attend one of these and meet some new Debian people and learn more about how Debian works.

  • Arrival: Landing in Managua on 7 July,  13:20 local time
  • Departure: Leaving from Managua on 14 July, 12:10 local time
New times:
  • Arrival: Landing in Managua on 7 July,  19:00 local time
  • Departure: Leaving from Managua on 14 July, 07:10 local time

See you there!

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon bug 1 000 000

// May 16th, 2012 // 1 Comment » // Education, Free Software


First off, congratulations to the team for reaching bug #1000000. They’ve managed to build a huge platform that scales very well. Very few bug trackers live to that milestone and it’s amazing how they have managed to keep it snappy and also keep downtime so low by doing continuous roll-out.

1 000 000 x 67

A million bugs are a lot, but even more mind-blowing: for every bug filed in, 67 iPads have been sold. Educational institutions everywhere are jumping on the iPad bandwagon, and in the Edubuntu project, we believe that the tools are quickly coming together that allows us to deliver a product that can be truly competitive with the iPad in educational environments.

We’re currently re-designing the Edubuntu website and will soon have a dedicated section to this project, but in the meantime, please join us on the edubuntu-devel mailing list and introduce yourself, or on the #edubuntu IRC channel on Freenode.

SociBook Digg Facebook Google Yahoo Buzz StumbleUpon