Monday, November 26, 2007

Self Help

So after not having used the perl module Petal for a few years, I find I'm a bit rusty. Rusty in the software industry means using google a lot to find answers. And when I searched to find how to iterate over an array, and use the array as hash keys or sub keys, I was interested to find a question that I had posted to the Petal mailing list 2 years ago.

Unfortunately, at that time no-one helped me, but I figured it out. Fortunately I posted the answer myself.

Just goes to show how important it is to fill out an answer on a forum/list. How many times can you find people with the same problems as you, but no answers....?

Saturday, November 17, 2007

WRC - Rally Ireland 2007

This year the World Rally Championship came to Ireland for the first time. Last night we set off in a camper van to Magheralough Primary School, near Trillick, Co Tyrone. This is part of the country I'm not very familiar with, but it certainly seems to be a very scenic place.

We arrived last night, parked up and had a poor nights sleep, before the alarm woke us at 7am. After a quick breakfast we ventured outside into the cold to pick out a spot to stand. The roads had been closed at 6am, and were not due to open until 6pm. We managed to get a good place, behind a fence where we could see the cars approach, then come down a small hill, cross the bridge, and then past us.

It turned out to be great, we didn't move a lot for the first stage (stage 12). The stage started at around 9:15am, and cars continued until about 11am. The drivers were clearly timid of the greasy roads, but there was plenty of quality entertainment.

After 3pm another stage (15) was run round the same course. After the first few cars we decided to take a wander up the fields a bit, and found a few other good places to watch the group 'N' and other trailing cars from. We didn't get as wet as expected, fortunately it seemed to rain it all away during lunch, when we were safely inside the motor-home.

All in all a great day.
Other info here : http://www.rallyireland.org

Monday, November 05, 2007

MySql Performance

After disappointment with how Oracle developer edition runs on my PC I decided to give an old acquaintance a whirl. I downloaded the latest MySql source, and built it in the cygwin environment (using the instructions in the DBD::mysql perl package).

It all installed nicely, and I downloaded TOAD to help set up my tables - another great (and free) tool.

My requirement is a simple lookup, so I set up a simple table, and a perl script to loop and insert values into it. I was reading a bit about optimising inserts, and found that dropping the index before all the inserts, and then adding it again is significantly quicker than keeping it enabled during the inserts.

Then I discovered that it is possible to insert multiple records at once. So I started to play around with this, and made the number of rows inserted at a time a configuration variable. The sql syntax is like "insert into table_name values(?,?,?), (?,?,?)" etc... where there are 3 columns in the table.

Not surprisingly inserting 10 at once rather than one speeded the times up from 2000/sec to 5000 a sec with significantly less trips to the database. Continuing the trend, I discovered that about 10,000 at a time was quite a good number, with around 130,000 inserts per second! Now that's pretty good!

After adding a single index on the 5 parameters I needed to search on, I was able to run well over 1000 queries per second, which is pretty good whenever there is over 11 million records in the database.

Another notable difference using MySql was that there seems to be no slowdown in inserts when the dataset grows.

Friday, November 02, 2007

Malin Head

For some time I have wanted to drive the Inishowen 100, a 100 mile tour round the Inishowen peninsula. Today we set out to drive round it, but we took a couple of shortcuts (i.e. got lost), and instead arrived at "Five Finger Strand", which the kids absolutely adored. There are some great sand hills which they enjoyed descending at great speed.


A fantastic beach, well worth a visit if you're in the area. Apparently we missed the coolest thing though, at low tide you can see the wreck of the Twilight which sank in 1889, on route from Newfoundland to Derry, so we'll have to make a return visit!

The other striking thing about the countryside was the sheer number of animals in the road!

Malin Head itself wasn't too exciting, especially as it was blowing a gale, and my company just wanted to "go home".


On the way home we happened to arrive at Greencastle just in time for the ferry. This gave us a quick route home.



Tuesday, October 30, 2007

Fireworks!

Tonight I took the kids into Coleraine for the local firework display. This year it seemed particularly amateur, but that didn't stop the little ones from enjoying it.

We were unsure of the start time, but we figured out that last year started at 8:30. We were there just before 8:30, only to hear several folks telling us that they just announced it was starting at 9pm. An extra long wait, especially with two tired children.



Friday, October 26, 2007

Walking on the beach

One of our favorite local walks is along Castlerock beach. I sometimes wonder if we should spread our wings, explore more, and not stick to the same old walks over and over. But on a night like tonight I remember why we visit so often... never fails to impress.

Sunday, October 21, 2007

Downhill forest

This evening we went for a walk in Downhill Forest. It was a beautiful autumn evening, perfect for the walk, and the changing leaves made it just fantastic.

We spent quite a while rummaging around in the undergrowth too, looking for conkers, but we only found a couple. Seems like all of the village had been there before us. Maybe next year....




Saturday, October 06, 2007

Pacific Coast Highway

Today it was time to go home. Rather than hang around we decided to go to the airport via the coastal route, and headed slightly south, and west to the coast. We followed the Pacific Coast Highway for the miles, stopping briefly at things that were interesting or cool.

One of the most unusual things were the hundreds of oil pumps draining the black gold from the soil, and beaches with oil tankers and oil rigs on the horizon. We also passed by an industrial estate with what seemed to be miles of refinery. Very interesting to see.

With every beach came more great swell, and surfers keenly waiting on the next big wave. All looked very nice, unfortunately we had no time (or equipment) to join in. Made the trip to the airport a lot more interesting though, I'd highly recommend this route to LAX, if you're ever going there.

Friday, October 05, 2007

Mountains

This afternoon we had some time off, so decided to do a bit of exploring. Firstly we went South to Cleveland National Forest, where you could drive through a bit of the mountainside, which was very cool. We thoroughly enjoyed the breathtaking roads and views, coupled with the beautiful sunshine.

After stopping off for some lunch, and having acquired a taste for the mountains we drove North towards "Big Bear Lake" - the local winter sports venue of choice. The cool thing about this part of California is that while the flat plains are only a few hundred feet above sea level they are consistently surrounded by mountains that soar into the clouds. Now, we all love mountains, and we all love a nice stroll in the hills, but we had no time for that. Fortunately, neither do most of the folks from LA, and so they've built great big roads that we can power up in our gas-guzzling V6 trucks.
So, up we went, 1000ft, 2000ft, the markers at the side of the road rolled by. We made our way up to Rolling Springs, the first settlement on the hill, just after the 6000ft marker, and it was cold. Unfortunately our relatively tight schedule didn't permit us to go any further, and I suspect it would have gotten even more spectacular beyond that.


Overall we rarely strayed more than 30-40 miles from the hotel, but we got to see a lot. And the best bit was that although we used thousands of gallons of 'gas', it only cost a few cents...

Silverado - Real America

So, I finally found it. This is what I wanted to see in the US. Silverado, a small village in the hills outside the main LA area in Orange county, California

This town represents a welcome escape from the over-urbanised generic America that we've come to recognise from modern TV.

On the way up here we got lost, and stopped with a guy who seems to live in the most ideal place in the word. He was almost apologetic, that he only lived in a "trailer", but what was cool was that his trailer was in a lovely scenic valley, bounded by conservation areas and national parkland. This means that he is assured that no one else will build around him. Fantastic.

Monday, October 01, 2007

Sunset over the Pacific

After work today we had asked a colleague for recommendations of places to visit. A coastal town called Laguna Beach came highly recommended, and so we decided to go in that direction. Due to the limited daylight we had to get wherever we were going as quickly as possible, but unfortunately we picked the road with an accident, and subsequent tailback. Anyhow, we arrived just in time for the sunset, which I have to say was particularly beautiful, and well worth the wait in the traffic.


Sunday, September 30, 2007

Work Travel - LA, California

Once again it falls to me to travel for work. Today I travelled to LA, California in preparation for a weeks work, and I have to say the 11 hour flight is one I could have done without.

Aer Lingus made the flight all the more enjoyable with a personal TV system available, offering a selection of TV programmes, films and music.

It's a bit annoying travelling at this time of year, as the daylight disappears so soon, but I'm informed that it's never that brilliant in LA anyway - not like midsummer here when it hardly gets dark. But, no doubt I will try to make the most of it over the incoming week....

Wednesday, September 26, 2007

Tax book

The tax book for the car actually arrived today. So now its officially in my name, even if it is to the wrong address. That'll be the next step ;)

Tuesday, September 18, 2007

Beach fun

Tonight we had some time to kill, so we decided to visit the beach. It was completely empty, and all semi-hard, wet sand. So I let the impreza go, and boy it was some serious fun.

Did the whole thing in second, which was a bit weird, as I had to be over the 2500 rpm to get the turbo. It was a completely different experience than I had been expecting - I'd been expecting to go round in circles, but there's just too much grip for that, even in the sand.

Great.

Thursday, September 13, 2007

Tax

At last I have a tax disc. We had to jump through some hoops to get this disc, but the car is finally registered in my name, and I have a valid tax disc.

Today I have insurance, MOT and tax. Great!

Thanks to the hideous brother-in-law for getting it all sorted for me!

Tuesday, September 11, 2007

Sideways - dry

Only very slight drifting, but definitely a landmark. Tonight on the way home I had an opportunity to overtake nicely round a roundabout, as someone went off right. In second I floored it, and felt the tail go slightly before I had to turn to exit the roundabout.

Very reassuring, the amount of grip available

Saturday, September 08, 2007

Boot and numberplate lights

Today I tackled the problem with the rusted rear numberplate lights. The plate that holds them tight to the underside of the bumper had completely rusted away at one side.

I had considered getting some sort of new plate and screwing it all together, but I figured out that if I used the original 2 plastic mounting holes that were now unused because of the rust, I could cable-tie the remaining metal to the bumper.

It's not very beautiful, and certainly temporary at best, but it's definitely a lot better than it was!

When I had the boot open for access I noticed that the light in the boot wasn't working at all. After inspecting the bulb I saw that it wasn't the problem, so I turned to the switch. It seems that corrosion had stopped the switch from closing properly. So I pulled the switch out, and gave the contacts a good clean. All working again!

Friday, September 07, 2007

Perfect wind

Tonight we decided to take the kids to the beach, and I thought I would pack the kites too. Due to the inclement weather we have experienced all "summer" we have hardly been at the beach at all.

Tonight however was superb - the wind was completely steady, and just at the right speed for my 4m buster.

May the pleasant post-summer evenings continue....

Saturday, September 01, 2007

Oil change!

At last the car turned over the anticipated 2000 miles. This meant that the running in oil should be changed for fully synthetic oil.


So I went ahead and got a new filter from Subaru, and some fully synthetic oil, (although I am not completely convinced this is the correct oil) and got it changed today.

Thursday, August 09, 2007

The wisdom that comes with years.....

.... seems to have completely passed me by!

We're just back from a family outing to pick up my new scooby, a MY98 special edition, full uk spec at 208bhp!