Ubuntu 14.04 – No USB keyboard after upgrading kernel

After upgrading my Ubuntu 14.04 LTS install from linux kernel 3.13 to 3.16, USB input devices, particularly my keyboard, stopped working.

On rebooting to an older kernel, the keyboard worked again. The reason for this, is that the base kernel package doesn’t include the usbhid module, which is require for USB input devices.

The solution, is to install the linux-image-extra package for your kernel. In my case it was:

sudo apt-get install linux-image-extra-3.16.0-28-generic

You can either do this via ssh, or boot to an older working kernel first.

Afterwards, you should be able to do modprobe usbhid, or simply reboot, and your usb input devices should function correctly.

Sony’s “cancellation” of The Interview’s cinematic release is a shrewd move

Yesterday, Sony Pictures Entertainment (SPE) announced that it has cancelled the theatrical release of Seth Rogen’s “The Interview”, in the wake of terrorist threats.

In light of the decision by the majority of our exhibitors not to show the film The Interview, we have decided not to move forward with the planned December 25 theatrical release. We respect and understand our partners’ decision and, of course, completely share their paramount interest in the safety of employees and theater-goers.

Apparently, one of the demands of the GoP hackers that breached SPE, was that Sony should not release this film. I’m not making this shit up.

According to the USA’s own Department of Homeland Security, the threat is, unsurprisingly, not credible. Sony therefore, has no reason to cancel the theatrical release. Other than… publicity.

The trailer looks bloody awful, and if I was North Korea I wouldn’t take offense at all. Really, it should damage Seth Rogen’s reputation more than Kim Jong-un.

Cancelling it then, is exactly the right thing to do. Except that it really hasn’t been “cancelled”, as the release will eventually be “re-evaluated” once there is “no longer any threat to innocent lives”. Of course, no one would ever want to see a “highly controversial” film which “incited terrorist threats” and “offended an entire nation”.

Talk about making Lemonade.

Ubuntu Home Server 14.04 – A DIY NAS

It’s been more than 4 years since I wrote about home servers, but my Ubuntu Home Server article was, for a while, the most popular post on this blog. Since moving to the UK though, I’ve taken a more appliance-based approach to my home network. For the last few years I’ve been using a Boxee Box for media playback, and a 4-bay Netgear ReadyNAS duo NV2+ for storage, mainly to keep the bulk of my possessions to a minimum.

The appliance approach does have advantages. It is power efficient, easy to setup, and very low maintenance. But after getting an internet connection with decent upload speed, I wanted to run CrashPlan on the NAS without having to have another PC running. I managed to get it running by following directions I found here.

There’s just one problem:

3.3 months to upload 350GB is a little too long

3.3 months to upload 350GB is a little too long

Performance is abysmal, and I’ve only selected the most important data – my photos. I’m limited not by my internet connection, but by the NAS’s anaemic CPU and lack of ram (just 256Mb). Furthermore, it’s always had very slow read and write speeds – generally around 2Mb/sec, and loading a large directory via its Samba shares can take a while.

So I started to look for a replacement. My requirements:

  • Minimum 2GB ram
  • Strong CPU, preferably x86
  • 4+ drive bays
  • Linux based OS
  • Root access to said OS

The best pre-built option I could find which meets those requirements is the Thecus N5550, but at £383 it is a long way from cheap. And it barely meets the specs; an Atom CPU is strong for a NAS but not by modern x86 standards.

While the customised software shipped with a NAS does offer some conveniences, it also gets in the way of using newer Linux features such as BTFS RAID 5/6 (which is currently not considered stable but should be within the next 12 months). You’re also reliant on the vendor for distribution upgrades, and the priority is going to be shiny features which consumers will appreciate, not keeping the foundation OS up to date. The ReadyNAS NV2+ is currently running Debian Squeeze, and will be until the day support ends.

At this point I realised that a pre-made NAS with the level of power and flexibility I wanted doesn’t exist at a realistic price point. And with the end of Boxee support its days as a useful device are numbered, so a HTPC could be on the cards as well. It’s time to build my own server again.

Continue reading

They used to call this ./’d

Maybe these days it’s “hackernews’d”.

Some kind person posted a link to this article, which resulted in an email alert from Linode about outgoing traffic at midnight this evening.

This blog runs on a single wee Linode instance, but fortunately it’s over-engineered for its usual traffic volume, and served by nginx, php-fpm and the WordPress totalcache plugin.

It seemed to weather the storm really comfortably with load hovering around 0.2.

Network Graph

Wordpress Graph

Dear @Adobe and @Oracle, please stop offering crapware with every Java and Flash Player update. It gets old quick.

Unticking a box might seem like a small thing, but consider the following:

  • The number of Flash Player and Java updates are frequent due to security issues and staying up to date is very important.
  • Updating Java or the Flash Player is anything but a frictionless process as it is. For Flash, upon clicking the update prompt I am taken to a download page, where I must untick the box for whatever crapware is on offer, click download, open downloads, launch the download, close web browsers (and possibly other applications), click retry, finish. Java is a little better, but not much.
  • Many people have multiple devices to update which magnifies the annoyance factor.

We are not in the 90s any more. Apple, Microsoft and Google have all managed to make updates a 1 touch process (or less), and this is the expectation of your users.

So stop being precious about distribution, but in the very least, stop abusing the update process as a marketing opportunity. It is irresponsible and annoying to millions of people every day.

Sony Xperia Z3 Compact Review

z3c-1

Flagship smart-phones have been getting progressively larger. My first high-end Android device was a Samsung/Google Nexus S, which was comparable to an iPhone 3GS in dimensions. By modern standards it is chunky, yet it remains a good tradeoff between screen size, pocketability, and handling.

The two phones I’ve owned since the Nexus S have had progressively larger screens – I went to a Galaxy SII, and then a Galaxy SIII. But I never wanted a larger device than the Nexus S, just a faster one.

Continue reading

Google commits privacy seppuku at BT’s request

Update – Since this was posted, Max Allan and Damion Yates have investigated further and found that BT are intercepting DNS queries and replying with doctored DNS results, which I didn’t notice when originally researching this article. The title is therefore not entirely accurate, and BT are most probably doing this without any special treatment from Google, but the point that Google is facilitating this (by performing http redirects) stands. Please keep this in mind as you read :)

–Alex 25/11/2014

As I’m currently in temporary accommodation I have found myself without a permanent internet connection. 3G service in the area is pretty spotty, so I bit the bullet and ended up purchasing a single month BT Wifi pass, effectively piggy-backing a neighbours connection. I’m guessing they see very little of the £39 I paid.

It is well-known that BT has filtering in place, supposedly for the protection of children, as required by the UK government. I don’t agree with this policy, but accept that many do.

However when it starts to affect privacy, I feel that BT’s meddling of my internet connection has gone too far.

Case in point, when using Google on BT Wifi I happened to notice a new message on the side:

SSL search is off

This network has turned off SSL search, so you cannot see personalised results.

The security features of SSL search are not available. Content filtering may be in place.

Learn More | Dismiss

After digging into it, I’ve found that statement to be demonstrably false. In actual fact what it should say is; “We have disabled SSL search on behalf of your network provider.”

To which I say, thank you for giving me another reason to use duckduckgo.

Continue reading

Safely running bulk operations on Redis with lua scripts

This article was also posted on the Gumtree devteam blog

If there was one golden rule when working with redis in production, it would be

“Don’t use KEYS”

The reason for this is that it blocks the redis event loop until it completes, i.e. while it’s busy scanning its entire keyspace, it can’t serve any other clients.

Recently, we had a situation where code was storing keys in redis without setting an expiry time, with the result that our keyspace started to grow:
Continue reading

Host switch

This blog has just moved from a Rackspace Cloud host to Linode, which offers a lot more specification for the pound (quadruple the ram for one).

At the same time I’ve migrated from CentOS + Apache to an nginx + php-fpm setup, which is not exactly easy for WordPress, but it feels good to be in the modern era!

Let me know if you notice any problems :)