Archive for the ‘Life’ Category

Gnome fails to start after switching Nvidia drivers on Ubuntu

Thursday, March 21st, 2013 | Life, Tech

If you’ve tried to switch to a different Nvidia graphics driver on Ubuntu and suddenly found that X / Gnome will no longer load and all you have is a command line, you can fix it by switching back to the original driver.

jockey-text -l
jockey-text -e xorg:nvidia_current

These commands will show you a list of drivers available, and then activate the standard Nvidia driver.

Selenium Cannot assign requested address

Friday, March 15th, 2013 | Life, Tech

If you’re using BDD (Cucumber or Behat for example) with Selenium, you may find you occasionally get an error where the framework is unable to communicate with the Selenium server.

Failed to connect to 127.0.0.1: Cannot assign requested address

This seems to occur when there are two many requests going to Selenium. This can be alleviated be rewriting your tests to ensure you are now sending too many requests at once.

For example, if you’re using Behat/Mink, then avoid using the wait() function on the Session object, as this can cause excessive requests to be sent to Selenium.

Hollins Hall

Sunday, March 10th, 2013 | Life, Photos

Last weekend, we headed up to the Yorkshire Dales for Elina’s birthday. We stayed at Hollins Hall, which is part of the Marriot chain.

It was quite a nice hotel, they have a big pool, although there were people in it which was always annoying and their spa bath was a bit rubbish. It was nice to have a decent length pool though.

The service was excellent, and the staff were friendly.

We dined in their Heathcliff’s Restaurant, which was OK, though I was a little disappointed by the roast, as the Yorkshire pudding was a bit hard and crispy. The white chocolate sauce that came with the profiteroles was a winner though.

IMG_0321 IMG_0324 IMG_0329 IMG_0323 IMG_0322 IMG_0314

MacPorts mysql5-server not working on boot

Friday, February 22nd, 2013 | Life, Tech

If you’ve installed MacPorts’ mysql5-server, you may find that it doesn’t work after a restart.

This can be resolved by running the following commands to make sure you’ve killed off everything MySQL related.

sudo port unload mysql5-server
ps -ax | grep mysql
sudo kill 

Once you have done this, load it again.

sudo port load mysql5-server

Not it should be working. This is fine, but quickly gets very annoying every time you restart your computer! A common cause is that you have a MySQL sock file in your tmp directory. Removing this may allow it to start automatically.

cd /tmp
rm -f mysql.sock

Once removed, restart your computer and see if MySQL works first time – hopefully, it will.

Install an MSI from a user account

Wednesday, February 20th, 2013 | Life, Tech

Sometimes you might want to install an MSI on your Windows system, without being logged in as an administrator. Normally, you would just right click and select “Run as Administrator” but this option is not available on MSIs.

Instead, right click on “Command Prompt” in the start menu, then select “Run as Administrator”. Once this is running, use the msiexec command to execute the MSI.

msiexec /i Filename.msi

This will then run the installer using administrative privileges.

Copernicus Day

Tuesday, February 19th, 2013 | Life

Copernicus

Happy Copernicus Day!

Data missing from MySQL replication due to column mismatch

Saturday, February 16th, 2013 | Life, Tech

If you are running MySQL replication, you may find that the structure of a table is brought over, but not the data. You can troubleshoot this by logging into the slave MySQL and showing the status.

SHOW SLAVE STATUS \G;

You may find an error similar to the following.

Table definition on master and slave does not match: 
Column 1 size mismatch - master has size 150, example_db.test_table 
on slave has size 50. Master's column size should be <= the slave's column size.

This is usually caused because you are using different character sets. In the example above, the master is set to UTF8 (utf8_general_ci) while the slave database is set up in Latin1. You can fix this in two ways (and should probably do both).

First, to change the database, log into phpMyAdmin and go to the operations tab. Here you change it from the dropdown and then hit save.

Secondly, you should change the default charset in MySQL to be UTF8 (you could also change it to Latin1 if that is what your master is running but in this day and age, everything should really be running UTF8). You can do this by editing your my.cnf.

[mysqld]
default-character-set=utf8

After editing it, you will need to restart MySQL. Any databases created from then on will default to UTF8.

Galileo Day 2013

Friday, February 15th, 2013 | Foundation, Life

galileo-day

Happy Galileo Day! Leeds is lucky enough to be hosting two Feasts in honour of the man – one at Fazenda at lunchtime and one at Browns this evening. Tomorrow, also sees Leeds Skeptics host the 2013 Galileo Day Lecture, Brian Quinn with a talk entitled “Superstition – The Odd Delusion”.

Super Bowl

Wednesday, February 13th, 2013 | Distractions, Life

Last week, we all gathered round to watch the third most watched sporting event in the world – the Super Bowl.

Actually, I don’t know where those figures are from. The reality is, we have almost no idea what the most watched events in the world are, but if we did, it probably would point to the Olympics. But it’s safe to say a fair few people were watching with us.

While ultimately, my favourite team, the San Francisco 49ers, lost to the Baltimore Ravens, a good night was had by all, and no one went away bitter about the fact that the 49ers only lost because the judges refused to throw a flag for the blatant pass interference against Michael Crabtree on the 4th and goal that decided the match. No one.

As usual at these sorts of events, we made too much food, allowing us to spend another two days living off ribs and wings – and what a happy two days they were.

It is also worth noting that Chris Culliver netted himself $40,000 for his appearance – more than a lot of my friends earn in an entire year. I guess homophobia does pay after all. I hate it when life works out like that.

Darwin Day 2013

Tuesday, February 12th, 2013 | Life

charles-d

Happy Darwin Day! To celebrate, why not attend a talk by Professor Steven French of the University of Leeds, entitled “Scientific Theory as Art”. Full details.