Intel wifi led blinking AGAIN on Ubuntu 12.04

I previously posted about this on previous versions of Ubuntu, but despite updating the instructions for 11.10 the instructions are once again obsolete. It seems Intel changes the name of its wifi kernel module every release…

On my Dell E4300 with “Intel Corporation WiFi Link 5100″ (as reported by lspci), the module name is now “iwlwifi”. This means the kernel options you add to /etc/modprobe.d should be against this module rather than iwlcore (11.04) or iwlagn (11.10).

So the instructions once again:

sudo echo 'options iwlwifi led_mode=1' >> /etc/modprobe.d/wlan.conf
sudo modprobe -r iwlwifi && modprobe iwlwifi

Bear in mind that the second line removes the wifi kernel module temporarily which will disconnect your wifi. It should automatically reconnect, if not reboot.

I Sincerely Hope I Never Write a Script like this Again

This sort of stuff destroys your soul:

#!/bin/bash
logfile=~/slave-watcher.log

while true; do
	status=$(mysql --execute="show slave status\G"|grep "Seconds_Behind_Master:"|awk '{print $2}')

	if [ $status == "NULL" ]; then
		mysql --execute="show slave status\G" | grep "Last_SQL_Error:" | tee -a $logfile
		mysql --execute="set global sql_slave_skip_counter=1; start slave;"
	fi

	sleep 1
done

What it’s doing is looking at MySQL’s slave status and skipping over any statement that causes an error. There are so many reasons why you should never do this, and I won’t go into detail on what necessitated it here, but you’ll be glad to know the slave I set this loose on was not in production!

Buying a PC Power Supply in the UK, January 2012

In the process of building my first desktop PC in about 4 years, I’ve come to realise that I no longer know anything about PC hardware. At one stage I considered myself, perhaps incorrectly, to be fairly knowledgeable about the subject of PC power supplies, even writing a PSU guide for a forum I used to frequent. Most of that guide is now irrelevant but looking back it wasn’t terrible advice for a newbie looking to buy a PSU at that time.
Read more »

Adding a swap file on Linux

At work some of our Red Hat (RHEL5) servers with 32GB of ram were configured with only 2 Gb swap files. For some workloads this might be fine, but a 2-in-1 Apache and MySQL server is not one of them.
Read more »

LinkedIn Android “bug fix” update includes invasive permissions change

LinkedIn was an app I hesitated to install initially because of the long list of permissions it requires. The December 19th update also added one more:

Read more »

Viber battery life – an update

My impromptu post about Viber gained a little more attention than I thought it would, prompting a discussion about battery usage and even attracting a response from the Viber development team.

I’ve said it before and I’ll say it again, it was never a proper review, just a highly subjective and unscientific personal impression of the app! My main complaint was and remains that it looks like an iPhone app (I probably should have complained about the purple colour while I was at it).

They did ask that I test the new version (2.1.2), released on October 12, 2011, so naturally I feel as though I should test it in the same fashion as before. That is to say, open Android’s battery life screen after Viber has run for a while and take a screenshot. :)
Read more »

It had to be done…

No one expected it to be Stephen Donald that kicked New Zealand's winning points!

Q: How does well does adsense perform on a site like this?

A: Haha:

Not quitting my day job.

Despite increasing revenue by 50% over the previous month I still need to increase revenue a further 500% to cover the costs of running this site. And at the moment it’s a tiny 256MB instance on Rackspace Cloud which, traffic depending, costs me a bit under £10 a month. To run WordPress properly however you really need 512MB minimum, even with the meagre traffic this site receives… so the cost should be closer to £20.

What I’d like to do is be able to justify running a cloud load balancer with two front-end web nodes and a separate DB node at the backend. Assuming all 256mb instances the cost of that setup would be about £1 per day, which should be too hard to deliver on an affiliate site, even if it isn’t this one. Hmm. Project time. :D

While this site does reasonably well on a few Ubuntu-related terms, it’s not hard to see why this site has such a poor click-through rate. For one thing the articles are mostly tech-focused, and I know myself when I’m Googling for a solution I literally skim the article for the code blocks, maybe think “that looks right”, and I’m gone in 10 seconds.

If it was a particularly tricky problem or the solution was a good one I might hang around long enough to leave a comment but most of the time I don’t, even though I like receiving comments myself.

The other reason it does badly is that I don’t really want the ad banner to get in the way, you’ll notice there’s only one banner, and its to the right and not even at the top.

Plus I’m using a stock theme and update once in a blue moon.

This site needs some love.

Or for more people to click the following link and spend lots of money with Rackspace. ;)

Powered by Rackspace Cloud Computing

Slow desktop performance on Ubuntu 11.10 with nvidia graphics cards

11.10 has been a bit of a mixed bag. On the plus side it has Gnome 3, giving me a practical (and in my opinion superior) alternative to Unity. On the minus side I had upgrade glitches on both my work and personal machines, and they were unrelated issues! Might be wise to wipe and reinstall for this one (you did separate your home partition when you installed didn’t you :) ).

Anyway after getting it working on my work PC (which has an 8400GS), the desktop was quite laggy in both Unity and Gnome3. It was still usable but I didn’t realise how bad it was until I went home and noticed how much smoother my laptop was, with its lowly 2009-era Intel integrated graphics…

The solution was to install the latest 285.05 Nvidia driver, but trust me when I tell you that you do not want the hassle of using the Nvidia installer from the Nvidia website.

It is much simpler to use the X Updates ppa.

So assuming you already have the default binary Nvidia driver installed and activated (nvidia-current), the quick command line solution to your performance woes should hopefully be:

sudo -i
add-apt-repository ppa:ubuntu-x-swat/x-updates
apt-get update && apt-get upgrade
reboot

You should notice an update for the nvidia-current package being installed.

That wasn’t too bad was it? :)

Viber – a nice VoIP app that I don’t really like

Viber (the kiwi/brit in me really wants to spell it “Vibre”), is a VoIP app for cell phones that uses a data connection to make free calls, much like Skype and other VoIP systems. The idea is great in principle, but in practice it doesn’t quite gel with how I use my phone.
Read more »