davidrickard.net

Random stuff, randomly updated.

Archive for August, 2006

Me Vs Zen Vs BT – Part two

Monday, August 28th, 2006

So, after all my carping about BT being useless, the line has since been fine! It’s rained a few times, and the connection has been fine. I’ve been hammering it a bit lately doing various downloads, and it’s pootled along quite happily. I’m a little perplexed now!

Still, if it’s working, I’m not going to knock it. I’m just very close to my bandwidth limit this month, so I’m trying not to download anything now. Oh the injustice of it all!

I just noticed the dates are displaying wierdly. Have to fix that sometime.

Me Vs Zen Vs BT – Part one

Sunday, August 20th, 2006

Well, kind of. I upgraded to Zen’s ADSL Max-based service a few months back. I’d been using Zen for about a year and a half, first on their 512k package, then the 1Mb service. I decided to move to the Max service because, even though it was capped, faster was good. I don’t download a fantastic amount (I know some people who have almost managed to leech the internet many times over), but I do like things to download fast. We have a 15mb link at work and my 1Mb ADSL was starting to look slow by comparison.

I’ve had the ADSL Max product since May, and there’s been a few problems. It was fine for some time, but then started dropping out intermittently. The problems went away, and I thought no more of it. Then it came back, and I was barely able to get online. I spoke to Zen Internet’s excellent support, and went through all the obligatory steps to diagnose the fault. BT did a line test, and the problem went away. About a month later it came back. I’d noticed that if my router synced at a speed above 4Mb, it would end up being quite unstable. I mentioned this to Zen support, and again we diagnosed the line again.

Zen escalated the fault to BT, who faffed about first wanting an engineer visit, which I duly booked, and took time off work, only for them to change their mind about a day later, and change the settings on my line, to make it connect at a lower speed. This seemed to solve the problem.

All has been well since, until this week. I’d started to notice a pattern though. The last time I had all the problems, the weather was blisteringly hot. This time, every time it’s rained, the connection dies. It was fine Thursday, until rain on Friday, when it was useless all Friday night. Saturday daytime it was perfectly fine, until the night, when it rained again. This morning I could barely use it. As the day went on, it’s dried up outside, and lo’, it works! I mentioned this to Zen support, and they have elevated it to BT again. I’m hoping BT take an engineer visit, and then I can tell the engineer about this.

I also reckon the electricity people messed something up too. O2 installed a phone mast nearby, and pulled a power feed from a lamppost outside our house, which is co-incidentally right next to a BT junction box. They actually dug around it to pull the power. I personally think they’ve breached it slightly, and water is getting into the junction box. Whatever it is, it’s annoying me no end!

I’m hoping it gets solved!

I like the concept, but…

Saturday, August 19th, 2006

The BBC have this little article about Channel 4 making a documentary whereby they take some members of a pygmy tribe, and see how they cope living in London. It’s a reversal of the usual method of dropping some random urbanite into the wilderness with some ancient tribe and seeing how they cope.

A nice idea, I first thought, but as I mulled it over more, I realised it is going to be on Channel 4. If it was Discovery, National Geographic or the BBC making it, it would be a worthwhile programme. Channel 4 are probably likely to do their usual thing of making the show 50% worthwhile, and then doing some other totally stupid things. Stupid OBVIOUS things. So, my current bets for the silly things they’ll try and make their pygmies do are:

  • Take them out on the town for a night and get them totally drunk/in fights.
  • Send them out on the pull.
  • Send them on a parachute fall.

I could be wrong about this – I hope I am – but Channel 4′s documentaries aren’t exactly known for being all that great. Then again, it could be worse. It could be Channel 5.

The Secret Life of Hoodies

Thursday, August 17th, 2006

I got this in an email newsletter from Paramount Comedy. It’s a small collection of shorts Paramount tend to whack in when there’s some slack in the schedules. I saw them a while ago and they really are very funny. I hoped they’d end up online so more people could see them. So now they are! Go watch them!

When I first saw them I thought they were real bits of film, but having seen them all together it’s obvious that it’s two possible actors who know what’s going on. I wonder if they were originally filmed to be doing something else, or something. Either way, I like these!

Bad code. Just bad, bad, bad

Wednesday, August 9th, 2006

I’m no code guru, but I do like messing around with languages. I’ve managed to write a whole ‘application’ in the form of a little php app to manage a DHCP server. The ISC DHCPD is one of the main DHCP servers out there, but being a unixy app, it has zero in the way of a management interface. It’s plain-text config files or nothing. I’ve got nothing against hacking text files, as I do it all the time, but at work we have a need to get stuff done quickly, and having to show all and sundry how to hack the files isn’t easy. Plus you’d need a copy of PuTTY to access the server, and if you manage to bungle the config file, DHCPD gets very upset and refuses to start. Then you have to go into the system logs and find out why. Explaining this to people who aren’t experienced with Linux is fair enough, but expecting people to remember this stuff (especially if they do it once in a blue moon) isn’t. So I thought I’d have a whack at writing a web interface to enable some simple management of the config files.

My method was simple: a simple web interface, store the information in a database, then use a command to flush it out to a config file. Simple!

I wrote the thing, and it all worked OK. You could add, delete and change MAC addresses. It would happily do this stuff. I’ve recently come back to trying to use it, and the damn thing just doesn’t work! My mess of bad code and even worse regular expressions has resulted in a mishmash of useless code that just doesn’t really work. I tried to change a MAC address for a PC it had in the datase, and it told me it already existed! I know that, hence clicking ‘change’ instead of ‘add’.

I’ve resolved to do something about it though and completely re-write it. I’ve got two options; one is to use a pre-existing framework, such as Cake PHP, OR write it all from scratch as an object-orientated application. I’m leaning towards the latter, as it would be a good learning experience. I do plan on, well, planning things this time! It grew a bit like topsy last time. The core feature of being able to add a node started, and from there bits just got woven in the sides. I was constantly going back to existing functions to add in bits, and breaking stuff in the process. Using OO tends to force you into planning and designing things better anyway, so I’m sure it’ll be possible. I’ve toyed with the notion of trying something like Python or maybe even Perl. I’m used to PHP though, and Perl is just plain wierd as far as I’m concerned (PHP is syntaxically very similar, but more straight-forward).

It’s something I want to work on and get up as a proper GPL’d project on Sourceforge. That’s my ultimate goal anyway!