Why doesn’t Eclipse/Installation Manager work on Linux?


For the next time I’m grumbling about yet more incompatibilities causing problems with Eclipse on Linux, adding the following properties to the bottom of the launcher configuration file seems to help:

-Dorg.eclipse.swt.internal.gtk.useCairo=false
-Dorg.eclipse.swt.internal.gtk.cairoGraphics=false

For example, edit the install.ini file for Installation Manager, which is where I first encountered problems after updating Red Hat Enterprise Linux last year. The problem appears to be due to incompatible GTK and Cairo versions, and there’s a related IBM technote for Installation Manager on RHEL 6.6.

Unfortunately, while that was enough to get Installation Manager working, the Eclipse IDE still seems somewhat unstable. I been exporting the following environment variable for a while but, based on the SDK Known Issues wiki page, maybe that doesn’t make any difference with recent versions:

export GDK_NATIVE_WINDOWS=true

Another suggestion I’ve seen recently, related to tooltips, is to export another environment variable, although so far I haven’t tried it:

export GRE_HOME=/dev/null

Need to experiment a bit more with those last two, and see if I can narrow down whether there are any other real problems.

Advertisement

Certifiable


I recently switched to a new ISP, who have so far been excellent, however they use certificates signed by CAcert. While I generally agree with the principle behind that decision, it does make life difficult. They cheerfully say, “You can check the certificate is signed by CAcert, if you like, before accepting it.” But how?

Warning: the following approach to checking the certificate is signed by CAcert is quite likely to be rubbish, so it’s probably not a good idea to follow it! In my defense, it seemed like a reasonable balance between just accepting some random certificate and complete paranoia but if you know a better way, please let me know.

They aren’t on Windows but the CAcert root certificates are already included in various places, so it turns out that the simple answer might be to grab the certificate from a suitable Linux distribution. Just to be on the safe side, I wanted to find a distribution I could download securely. The best option I found was Tails, which has a secure download and, for extra peace of mind, can be verified with OpenPGP.

My chosen method for trusting the tails signing key was a tad more interesting on Windows due to the lack of an sha256sum command. Luckily it seems you can do anything in PowerShell, so with a little help from Brian Hartsock’s blog, this did the trick instead:

$ha = [System.Security.Cryptography.HashAlgorithm]::Create(“SHA256”)
$stream = New-Object System.IO.FileStream(“tails-signing.key”, [System.IO.FileMode]::Open, [System.IO.FileAccess]::Read)
$sb = New-Object System.Text.StringBuilder
$ha.ComputeHash($stream) | % { [void] $sb.Append($_.ToString(“x2”)) }
$sb.ToString()

 

All good, certificate verified. I would still rather Andrews & Arnold just used a proper certificate though: there are clearly problems with trusting all the certificate authorities that are included in browsers/operating systems by default but CAcert doesn’t exactly look like a fantastic example either, and normal users really don’t have any chance of making a more informed choice.

Building Mosquitto on a Raspberry Pi


Just a few notes in case anyone wants to build the latest version of Mosquitto on a Raspberry Pi before Roger makes it even easier. Luckily there were already a couple of articles describing how to build Mosquitto, and the comments definitely saved some head scratching:

Hopefully the following steps should get MQTT on your Raspberry Pi in double quick time…

Firstly install a few packages. The unscientific list I went with were these, since Python was definitely installed already:

$ sudo aptitude update
$ sudo aptitude install build-essential quilt libwrap0-dev libssl-dev devscripts python-setuptools

Next the sneaky tweak to avoid Python 2.6 errors while building. You can edit /usr/share/python/debian_defaults by hand to move the python2.6 entry from the list of supported versions, or the following should do the trick:

$ sudo cp /usr/share/python/debian_defaults /usr/share/python/debian_defaults.orig
$ sudo sed -E -e '/^old-versions|^unsupported-versions/ s/$/, python2.6/' -e '/^supported-versions/ s/python2\.6,+ +//' /usr/share/python/debian_defaults.orig | sudo tee /usr/share/python/debian_defaults

Now it’s time to grab all the Mosquitto source and packaging files needed to run the build. These were the latest at the time of writing:

$ mkdir mosquitto-build
$ cd mosquitto-build/
$ wget http://mosquitto.org/files/source/mosquitto-1.1.tar.gz -O mosquitto_1.1.orig.tar.gz
$ tar -xvf mosquitto_1.1.orig.tar.gz
$ wget http://mentors.debian.net/debian/pool/main/m/mosquitto/mosquitto_1.1-1.debian.tar.gz
$ tar -zxf mosquitto_1.1-1.debian.tar.gz -C mosquitto-1.1/

Hopefully everything should be ready to go, so kick off the build:

$ cd mosquitto-1.1/
$ debuild -us -uc

That’s all there is to it. Assuming everything worked, just install the packages:

$ sudo dpkg -i ../*mosquitto*.deb

Update: Alternatively, you could just use the new, experimental, debian repository for mosquitto. (13 January 2013)

Joggler OS


For the last couple of days I’ve finally begun to seriously consider deserting the standard O2 Joggler OS. I’ve tried a few alternatives since I first got the Joggler last year but, despite the limitations of the O2/OpenPeak software, none of them have tempted me to switch permanently. The pros have outweighed the cons enough to keep it in regular use… so far…

Pros:

  • It’s simple
  • It works pretty reliably
  • The traffic app is quite handy
  • The  internet radio is better than DAB
  • It streams music from my router

Cons:

  • It’s limited
  • The traffic/radio/music apps are pretty basic
  • No new apps – O2 are clearly not interested in the Joggler any more
  • The calendar is terrible
  • The SDK is disappointing

The O2 calendar app itself was more usable than many I’ve tried but it ultimately failed, mainly because it never actually shows you what’s in the calendar unless you go looking. It really needed to display reminders on the clock screen. It also relied on the O2 servers for all the data, which tended to be really unresponsive, and was certainly no good with an unreliable broadband connection. As for the SDK, I’ll admit to being a bit biased, not being a Flash developer. It still wasn’t great though.

First up, a couple of strong contenders. There are others but for me the Joggler isn’t just a small server to run some Linux variation on.

Jolicloud

I really like the idea of Jolicloud, and it was pretty simple and finger friendly. Unfortunately it always felt a bit sluggish on the Joggler, and it didn’t seem to replace the combination of O2 apps I was happy with, or open the door to new and interesting possibilities.

MeeGo

MeeGo is another OS that should be well suited to an always on touch screen device. I tried the image hosted on bug10738.openaos.org a while ago and it did work really well but, again, it always felt like the Joggler was struggling a bit. Definitely lots of potential though, and I would probably have spent a bit more time experimenting with MeeGo if I hadn’t tried Android…

Android

I wasn’t really expecting much from Android, having seen less than enthusiastic reviews of previous attempts with Android 1.6, but I tried a more recent 2.2 version. First impression was that it was way more responsive than either Jolicloud or MeeGo, and the Android UI is a perfect fit for the Joggler. The first image I tried did have a couple of problems: the screen was a bit fuzzy and the the replacement for the usual Android buttons wasn’t ideal (I liked the gestures but you have to switch between them and being able to get at the notifications). Still, I had seen my Jogglers future, and it had a little green robot in it.

Downloading the second image was marginally more tricky because it wasn’t in English, but it has been well worth it because the screen is rock solid now. It also has virtual buttons in the status bar, which aren’t as fun as the gestures, but work all the time which is a bonus.

So now I just need to find replacements for the O2 apps I use the most. I’m planning to try out Dale’s traffic checker at some point, but TomTom now make their live traffic service available free on the web, which works ok:

Certainly more detailed than the O2 traffic app! It looks like there are a few music apps to try out as well, and I’m definitely keen to download the Android SDK to finally write my first ‘Joggler’ app!!

New clock radio


I managed to resist temptation during O2’s first Joggler special offer, but after having a look at someone else’s I failed to resist the second time round. If you can find an O2 cashback deal on their mobile broadband dongle, it’s even possible to get a Joggler for £35, although I must admit I’m a bit of a cynic when it comes to cashback offers.

The Joggler doesn’t appear to have got particularly good reviews and in trying to describe what a Joggler is, it’s easy to see why people are skeptical; it’s a bit like a really bad iPhone that you a) can’t use to phone anyone and b) can’t use outside your house. The software that comes with the Joggler is disappointing, which doesn’t help. It’s a shame because I think the basic principles for the apps are good as far as they go, but the execution is just not there yet. For example, the guide rightly notes that a tap-and-hold is not intuitive, but to move or delete apps that is exactly what you have to do. I also quite like being able to tap the time to display the clock screen saver straight away, but that isn’t exactly obvious either. The on screen keyboard is inconsistent, although I have on seen two so far. There’s a ‘commonly used’ information icon, but it’s so uncommon that I don’t think I’ve actually seen it. Right up there next to the home icon for every app would be nice. Browsing through music or photos is painful. The messaging app doesn’t allow short SMS codes. Let’s just say that there’s plenty of areas for improvement, although it is just possible that things will get better: the Joggler does get updates and something decent may yet turn up in the Joggler app store!

You might think that I’m disappointed by the Joggler, but I’m actually very happy with it, especially for the price. One big bonus is that the hardware is excellent, although even here there is one tiny omission… how can it possibly not have some kind of SD card slot? That just seems mad. Still, unlike a few people I know, I’m not quite ready to ditch the O2 software and replace it with something completely different. Despite shortcomings with the current apps, I like the concept and it’s certainly good enough for the (reduced) price. For example, I’ve been using the internet radio a fair bit; it disconnects now and then but is otherwise far better than DAB radio. I’ve also been checking the traffic app most mornings. It’s not great (I wish it at least had motorway junctions marked on the map) but it’s good enough to see when the worst of the morning rush is over. I would really like to use a calendar app as well and, having tried the google one, I may actually sign up for an O2 calendar to see how it compares. Google calendars are fine, but I don’t want to see all my google calendars on the Joggler and I couldn’t see any way to pick which calendar(s) to show in the app.

So for now, apart from a bit of tinkering (downloading Ubuntu for the Joggler at the moment for a quick look), I’m planning to leave it mostly as is. In the future it would be nice to get it to run the few bits I have on my other home server,  some home automation apps would be interesting, a decent feed reader instead of that Sky news rubbish would be handy, an Opera mini app would be great, etc. etc. Thinking about getting hold of the Joggler SDK to see what that’s like.

I was collecting a few handy looking links while investigating whether to buy one…

…but Graham and Nathan have that pretty well covered already.

All in all, £35 for a hackable internet radio isn’t bad. And I do really like the clock!

ThinkPad 240 netbook


I’ve had a ThinkPad 240 for many years and in the past it’s been a bit fiddly to install Linux on due to the lack of a CD drive. It also doesn’t help that the BIOS won’t boot from a USB device, although it is a very old machine so I’ll forgive them that small oversight. In the past I’ve messed around with floppy disks and a USB CD but in comparison the last install was an absolute breeze, and it’s now working the best it ever has with Linux.

This time I used GRUB for DOS and a Knoppix live CD. I had been using Grub in one of my earlier Linux partitions but it was getting a bit messy, so I restored the mbr and added a GRUB for DOS entry to the Windows boot manager BOOT.INI file:

[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)\WINNT
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINNT="Microsoft Windows 2000 Professional" /fastdetect
C:\GRLDR="More..."

I’m much happier handling all the boot configuration from the Windows partition since it’s the most ‘stable’, i.e. the one I mess about with the least! Next I copied the contents of  the Knoppix CD to a directory on the C: drive and created a GRUB for DOS menu.lst file with the following details:

timeout 30
default /default

title Knoppix
root (hd0,0)/Linux/KnoppixCD
kernel /boot/isolinux/linux fromhd=/dev/sda1 knoppix_dir=Linux/KnoppixCD/knoppix ramdisk_size=100000 lang=uk vt.default_utf8=0 apm=power-off vga=788 screen=800x600 nomce quiet loglevel=0 tz=localtime
initrd /boot/isolinux/minirt.g
boot

title Command line
commandline

title Reboot
reboot

title Halt
halt

And that’s pretty much it. In the past that was just the start of getting the wireless card and everything else working, but I’m seriously impressed with the latest Knoppix; it handled the Linksys WPC54G without even blinking and for basic netbook work it’s running on the 240 very nicely. Should have another few years in it yet!

Home server OS


Choosing the hardware took a while but that was nothing compared to tracking down a Linux distribution to use! I’m a big fan of DSL and, being damn small, it runs a treat on the Netvoyager but it’s purpose in life isn’t really as a home server. So began a hunt for a Damn Small Home Server Linux distribution which has eventually led me to…

SLAMPPLite uses the XAMPP server suite, and is low fat version of the “instant home server” SLAMPP. Sounded promising! So far it’s lived up to expectations, running the XAMPP samples without any noticeable delays- here’s how it looked with everything running (though not necessarily doing anything!)…

top - 02:55:44 up 9 min,  1 user,  load average: 0.49, 1.38, 0.94
Tasks:  80 total,   1 running,  79 sleeping,   0 stopped,   0 zombie
Cpu(s):  2.6% us,  3.9% sy,  0.0% ni, 93.6% id,  0.0% wa,  0.0% hi,  0.0% si
Mem:    119544k total,   116608k used,     2936k free,     9428k buffers
Swap:        0k total,        0k used,        0k free,    55916k cached

So a pretty tight squeeze, but on a £95 box (they reduced it after I bought one!) I’m more than happy. As an added bonus, SLAMPP/SLAMPPLite are based on SLAX, which made recompiling the broker for publishing CurrentCost data a snap, plus you get some handy tools for customisation, including the MySlax Creator gui for those of us who spend too long with Windows, so I’ve been tinkering with an extra lite version! (I may well be installing SLAX on my venerable old ThinkPad 240 as well since it seems so flexible.)

Now that I have the LX1000 BIOS password, thanks to the very helpful Netvoyager customer support, I should be able to get it set up to boot back up after a power cut as well. Andy has also been asking about file serving but I haven’t given that a try yet. Plenty more to do!

Update: Another quick look at memory usage, this time after stopping a few unwanted services:

# free -t -m
             total       used       free     shared    buffers     cached
Mem:           116        100         16          0         17         62
-/+ buffers/cache:         19         97
Swap:           78          0         77
Total:         195        100         94

Cheap low power home server options


Unfortunately my CurrentCost meter only gets hooked up to an aging ThinkPad 240 on a time-share arrangement with Jo; she is currently cursing about how slow the web is, so my graph on the power meter page is blank. Other people have a more reliable connection and are tracking down 3KW spikes and 100watt-ish blips. Good excuse for a(nother) gadget I reckon!

Current thoughts, in roughly ascending price order:

  1. SLUG: £57 (as recommended by @andysc)
  2. Netvoyager LX-1000: £130
  3. MicroClient Jr.: $214 (same case as above but includes 2 RS232 ports which is nice. Not sure I can be bothered with importing one… but more than one? Maybe.)

Out of the running (probably) are:

  1. Minifsk: $200+ (Looks neat and claims to have a serial port but in the US again)
  2. TinyTuxBox: cheapest seems to be about £193
  3. Asus EEE PC: better value at around £200?
  4. Linutop 1: €250+

And finally, Dale suggested a Pocket PC option earlier and Steve suggested an ASUS WL-500g. I must admit I’ve not looked in to either of those. I do have a Palm V kicking around but not sure that’d be up to the job! I also have a Linksys WAG354G but that is gainfully employed and doesn’t have any USB/Serial ports.

Decisions decisions.

Update: I’ve been very happy with the choice I made (a Netvoyager) but if I had to make the same decission today, it would be much much simpler: the Viglen MPC-L is a steal at £79! In fact, it’s such a good deal that I caught myself contemplating buying one as a second home server yesterday, which is obviously crazy. (30 November 2008)

Plug and Play


Thanks to Dale, I’ve found something to keep Damn Small Linux company on my USB key (there is a lot of space left after all!) – like Dale, I have an interest in mobile computing (unlike Dale, I have less gadgets, so PortableApps sounds great to me) and I’ve posted a couple of times before on the subject. At the risk of this weblog turning in to Dave, here’s a repeat:

It sounds like, between them, Scott McNealy and Dan Gillmor have got the right idea about access to my data. Hopefully not actually my data though! Scott wants it on the network, Dan wants it with him, and I just want it.

For years, I’ve quite liked the idea that I could have some sort of rfid tag with me (on my key-ring, in my watch, or somewhere I don’t have to worry about it) that would just log me on to my PC (and phone!) when I’m nearby, locking it again when I move away. It would be even better if it worked with any computer, giving me access to the same desktop where-ever I go. Scott seems to agree, although what’s with having to get out a “smart card” to plug it in? Sounds more like a “daft card” to me.

More recently, with the amount of data I can carry around with me (I suspect I’m actually behind the times here with a meagre 1Gb split between a tiny USB key and an MP3 player!) I’ve been leaning towards Dan’s point of view although, again, fumbling around to find something to plug in is just annoying. This is the 21st century! (Isn’t it?!)

The solution should be simple; I have a nice large lump of storage with me, that can wirelessly connect with any computing device (my desktop, thinkpad, PDA, phone, public kiosk, etc. etc.) giving me access to the same data everywhere. The data is also on the network too, luckily for Scott by the sound of it, so the two copies can be synchronised automatically, allowing me to work when I can’t, or don’t want to (it might be slow, insecure or expensive), connect to a network but providing access when I don’t have my storage with me (I could have left it somewhere deliberately or, not for the first time, lost it!). Even better if my storage is on some existing format expansion card so that I can physically plug it in to a) save having to carry around yet another gadget (just plug it in to a phone/PDA) and b) get faster access to the data if the wireless link is too slow.

(Originally posted 29 June 2005)

SoulPad looks pretty interesting too.

Damn Good Linux


Damn Small Linux is a superb Mini Linux distribution which I’ve been using on and off for a while. Like some sort of swiss army knife on steroids, it seems to do everything I expect of much larger distributions despite its tiny size. It is also really well thought out, being remarkably easy to use; this isn’t some bare bones command line only system and everything just seems to work without a struggle.

After getting my latest gadget (see below) I had another look round for alternatives but I’m sticking with DSL. Very handy to have around, and now even easier to carry.

Micro Vault Tiny– much cheaper than an iPhone!

Sony Micro Vault

Keeps my old Thinkpad 240 gainfully employed, but I do keep thinking a Damn Small Machine might be fun, or perhaps a Linutop… resist, resist, might as well give in to the iPod Touch temptation at that point!