Convert mailman translation to UTF-8

Why is the Swedish translation in ISO8859-1? Sooooo 20th century! 🙂

Templates

cd /usr/share/mailman/sv
for f in *; do
  mv $f $f.old; iconv -f iso8859-1 -t utf-8 $f.old > $f
done
rm *.old

Translations

cd /var/lib/mailman/messages/sv/LC_MESSAGES
mv mailman.po mailman.po.original
iconv -f iso8859-1 -t utf-8 mailman.po.original > mailman.po
msgfmt mailman.po -o mailman.mo

/etc/mailman/mm_cfg.py

DEFAULT_CHARSET = 'utf-8'

def _(s):
  return s
add_language('sv',    _('Swedish'),       'utf-8')
del _

Update On Ubuntu 8.04 LTS it is also a good idea to apply the patch for Logrotate is noisy with: Re-opening all log files. (It’s a issue with the mailman 2.1.9-9 package, which is the latest one released for Hardy.)

New hardware ordered: printer and kitchen computer

The kitchen computer project will be powered by a black ASUS EeeBox B203! The ancient 800 MHz (VIA Samuel 2 crap CPU) Mini-ITX machine I use for the prototype is very slow, has issues with the USB network adapter (NetGear WG111v3, ID 0846:4260),  and freezes occasionally so it will be retired soon! I will try to use Ubuntu Netbook Remix on the EeeBox.

I also ordered a new network laser printer, and actually not an HP! It’s a Samsung ML-2851NDR. The OpenPrinting database says that the very similar model Samsung-ML-2851ND works perfectly so I hope that the “R” does not mean “Requires Microsoft Windows”. It was cheaper than the HP LaserJet P1505N, even though the Samsung has duplex support and the HP does not.  Hopefully I will not share the experiences in this negative Samsung ML-2851NDR review.

Firefox 3.0 freezes waiting to resolve safebrowsing-cache.google.com in DNS

My current daytime setup is for various reasons a Windows XP installation with Ubuntu Jaunty running inside VirtualBox. I use Microsoft Windows for Outlook, SQL Navigator and some web browsing while using the Linux installation for development. This morning I started Firefox in Windows XP, changed focus to VirtualBox or some other window, and when I returned to Firefox it was frozen. I followed the standard Windows trouble-shooting procedure: reboot and get a coffee. When I was logged in again in both Windows and Ubuntu I got the same issue with Firefox in Linux. WTF?

At least I have the tools in Ubuntu to debug this issue. This is a simplified version and approximate order of what I did.

First, create ~/.gdbinit to make GDB a tad more user-friendly:

set pagination off
set radix 16
set print pretty
set history save on

Second, add ddebs.ubuntu.com to /etc/apt/sources.list:

deb //ddebs.ubuntu.com/ jaunty main restricted universe multiverse
deb //ddebs.ubuntu.com/ jaunty-updates main restricted universe multiverse
deb //ddebs.ubuntu.com/ jaunty-security main restricted universe multiverse
deb //ddebs.ubuntu.com/ jaunty-proposed main restricted universe multiverse

Install some debug symbols:

sudo apt-get install firefox-3.0-dbgsym libnspr4-0d-dbgsym xulrunner-1.9-dbgsym

Debugging time!

$ gdb `which firefox` `pidof firefox`

(gdb) thread apply all bt

Thread 2 (Thread 0xb08eab90 (LWP 4253)):

#9  0xb7e16c7f in getaddrinfo () from /lib/tls/i686/cmov/libc.so.6
#10 0xb7c8d739 in PR_GetAddrInfoByName (hostname=0xbc01ff4 “safebrowsing-cache.google.com”, af=0x0, flags=0x8020) at prnetdb.c:2026
#11 0xb7267940 in nsHostResolver::ThreadFunc (arg=0x92d9fd8) at nsHostResolver.cpp:697

Thread 1 (Thread 0xb7d4b6d0 (LWP 4243)):
#0  0xb8003422 in __kernel_vsyscall ()
#1  0xb7fe30e5 in [email protected]@GLIBC_2.3.2 () from /lib/tls/i686/cmov/libpthread.so.0
#2  0xb7c94ed9 in PR_WaitCondVar (cvar=0xcd1ebf8, timeout=0xffffffff) at ptsynch.c:405
#3  0xb7c94f57 in PR_Wait (mon=0xd47d178, timeout=0xffffffff) at ptsynch.c:584
#4  0xb726621b in nsDNSService::Resolve (this=0x92d4b00, [email protected], flags=<value optimized out>, result=0xbff19ac0) at nsDNSService2.cpp:49

So, we have a thread that is resolving “safebrowsing-cache.google.com” and another thread waiting for this hostname to be resolved. Could this be an issue?

Back at the command line, is there an issue with this domain name? Checking on my local computer:

$ host safebrowsing-cache.google.com
;; connection timed out; no servers could be reached

Trouble at Google? I must confirm that, so I login to one of my servers and run the same command:

$ host safebrowsing-cache.google.com
;; Truncated, retrying in TCP mode.
safebrowsing-cache.google.com is an alias for safebrowsing.cache.l.google.com.
safebrowsing.cache.l.google.com has address 74.125.10.92

Works fine, but what does Truncated, retrying in TCP mode mean? I will investigate that later.

Apparently the company firewall is unable to resolve this domain name, at least for the time being. Google Safe Browsing is built into Firefox 3, so how do I disable it? I looked in about:config and yes, there was a setting called browser.safebrowsing.enabled set to true. I set it to false and… Firefox still froze. Looking at about:config again, I found browser.safebrowsing.malware.enabled and set that one to false as well. Now I am able to write this blog post!

Disabling these configuration options is only curing the symptoms, not the disease. But can I cure an enterprise DNS server that fails to handle truncated responses? I doubt it.

Google Talk in Pidgin working behind enterprisey proxy

When I configured Pidgin 2.5.5 to use talk.google.com as Jabber server, the proxy said:

HTTP/1.1 403 This URL is explicitly denied from being proxied

Fortunately it was a very stupid proxy, so resolving talk.google.com to an IP address worked fine! Here is the advanced settings screen for the working connection:

screenshot-modify-account

To upgrade or not to upgrade?

I have updated a couple of my Ubuntu 8.10 (Intrepid) installations to Ubuntu 9.04 (Jaunty) but not yet my primary laptop. I was about to do that tonight (isn’t starting something at 22:00 a grea idea?) but the upgrade procedure showed me the message below, making me postpone the upgrade and write this blog post instead:

This computer is currently using the AMD ‘fglrx’ graphics driver. No version of this driver is available that works with your hardware in Ubuntu 9.04.

My graphics card (three years old by now) is described by lspci as an ATI Technologies Inc M56GL [Mobility FireGL V5200] and apparently these are no longer supported by the properitary fglrx driver. The Open Source radeon driver is rumoured to be pretty good these days but “never change something that works” is pretty useful on laptop where for example Suspend should work.

Speaking of the graphics card, dual-head with my LG L1510SF touch screen monitor works, but the touch stuff needs some tweaking and I’ll get back to that in another blog post.

Touch screen monitor arriving this week

Last summer I outlined the components needed to build a kitchen computer but I never created one. (If you know Swedish you can read my blog post Köksdator?) One of my requirements was a touch screen interface.

Right now an LG L1510SF touch screen monitor is in the mail, heading my way! I actually have two uses for it now, because except for building a kitchen computer I plan to put UltraMixer on the touch screen when I will pretend to be a selector (reggae/dancehall disc jockey) next weekend.

The touch screen functionality is supposed to work properly with the evtouch driver and before next weekend I hope to get the touch screen working as a secondary monitor connected to my laptop.

I will use an old Mini-ITX box to create a prototype of the kitchen computer in order to get a better grasp on the toughest issue: how to make it pass the wife acceptance test.

The kitchen computer will probably mostly run Ubuntu with a web browser for easy access to:

  • Current date and time
  • Weather forecast
  • Train status
  • Calendar

Hopefully I can take some time to evaluate Ubuntu Mobile and see if it is a suitable interface for this purpose.

For a proper implementation I have thought of using a an ALIX-based system (just like for my firewall). It would be really small but probably pretty slow. I’m now thinking of using an Asus Eee Box. It is small, pretty quiet, and has built-in WLAN. I might also get use for its VESA mount feature. The Eee Box would require an DVI to VGA adapter though. Some Eee Box version seem to include a remote control and that could be useful too!

Even with a touch screen a keyboard and a mouse will be needed for some purposes. They should of course be wireless.

So why not get an EeeTop right away as a kitchen computer? Truth to be told, if I knew about it previously I had forgotten when I ordered the touch screen! Maybe it is perfect for UltraMixer too? And maybe it would pass the wife acceptance test with ease? I will probably never know.