Changing default font size for Wireshark on OS X

Wireshark is an awesome tool, I am sure you all know that, but when you run it on Mac OS X it looks pretty horrible. Font sizes are disproportionate, it looks ugly. It all comes from the default gtk configuration it uses.

In order to make it look better, just change your gtk settings by running this on the command line:

echo 'gtk-font-name = "Sans 10"' > ~/.gtkrc-2.0

Note: This will change the font size for all your gtk apps, but I bet you don’t have many. There are other things you can do which involve changing the default settings shipped inside the package, but you’d lose those after every upgrade.

Thats it.

Check the PageRank of your site, and some more things

Bicing BarcelonaI’ve been migrating some old projects I haven’t been maintaining for a while from my old Linode Xen server to my new OVH dedicated server. In case you missed them, check them out:

I’m keeping secret for a while two more surprises on the new server. Stay tuned during the following weeks.

Run Django apps using Gunicorn and nginx

Some days ago, I read this tweet by @jessenoller (via @DZPM):

The future is DUNG: Django, Unix, Nginx, Gunicorn. I plan on asking HR to look for DUNG on all resumes.

What the heck is Gunicorn, I wondered… In short, Gunicorn is a Python WSGI HTTP Server easy to set up that gets on well with Django. Running Django apps using my beloved nginx gets faster and easier using Ubuntu Lucid Lynx. Look below…

  • Install packages (I assume you’ve already set up nginx)
# apt-add-repository ppa:bchesneau/gunicorn
# aptitude update
# aptitude install gunicorn supervisor python-setuptools
  • Edit in your Django app and add gunicorn to your INSTALLED_APPS
  • Setup the supervisor of Django process in /etc/supervisor/conf.d/djangoapp.conf
command=/usr/bin/python /path/to/your/app/ run_gunicorn
  • Restart supervisor
  • Setup nginx
upstream app_server_djangoapp {
    server localhost:8000 fail_timeout=0;

server {
	listen X.X.X.X:80;

	access_log  /var/log/nginx/;
	error_log  /var/log/nginx/ info;

    keepalive_timeout 5;

    # path for static files
    root /path/to/your/app/media;

    location / {
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header Host $http_host;
        proxy_redirect off;

        if (!-f $request_filename) {
            proxy_pass http://app_server_djangoapp;
  • Have fun

It was crystal clear LAMP’s time was over, could DUNG be the next fashionable acronym in free software web apps world?

Multiple Solr Instances: The Clean (Ubuntu) Way

If you need to run multiple instances (multiCore) of Solr in an Ubuntu Lucid Lynx, and you don’t want to mess your system (you want to do it the aptitude way), follow this recipe:

  • Install Solr
# aptitude install solr-jetty openjdk-6-jdk
  • Edit /etc/default/jetty and enable autostart
  • Create /usr/share/solr/solr.xml and specify your instances
<solr persistent="true" sharedLib="lib">
  <cores adminPath="/admin/cores">
    <core name="core0" instanceDir="core0" />
    <core name="core1" instanceDir="core1" />
  • Create configuration directories for both instances
# cp -Rp /etc/solr/conf /etc/solr/conf-core0
# cp -Rp /etc/solr/conf /etc/solr/conf-core1
# mkdir /usr/share/solr/core0
# mkdir /usr/share/solr/core1
# ln -s /etc/solr/conf-core0 /usr/share/solr/core0/conf
# ln -s /etc/solr/conf-core1 /usr/share/solr/core1/conf
  • Get rid of old stuff
# rm -rf /etc/solr/conf
# rm /usr/share/solr/conf
# rm -rf /var/lib/solr/data
  • Change path of dataDir in /etc/solr/conf-core{0,1}/solrconfig.xml for each instance
  • Configure each instance by editing /etc/solr/conf-core{0,1}/solrconfig.xml
  • Start Solr
# /etc/init.d/jetty start
  • Have fun in http://localhost:8080/solr/core0/admin/ and http://localhost:8080/solr/core1/admin/.

I take pity on the Gmail sysadmins

I work as a sysadmin for money and for fun and I’m quite used to getting complaints when things are not working properly. That’s ok. But most of the times, I’m also quite used not to getting any kind of recognition when I keep things up and running and when I fix important issues (often not caused by me). So, now that Gmails not been working properly for a few hours, more than ever, keep up the great work Google guys.

You managed to create the best webmail service with weekly new features and with the best spam control one could imagine. Congratulations for your work.