having fun

OK - this is going to be the geekiest post ever, so I recommend you just skip it. I'll be posting about some other interesting articles soon, so there's no need to read this post.

Still here? OK, you asked for it: tomorrow I have an interview, and as part of the interview they asked me to show them I can actually use PHP. Now, I can use PHP, but it's been a year and a half since I did so, so I decided it probably made good sense to bone up a little. So I set up my little windows test environment using the Abyss web server, then installed PHP. So far this is still relatively normal stuff.

So here's where my geek got loose: I have, upstairs, a device which was originally designed to make hard drives available on the network without attaching them to a computer. It's called the NSLU2, or more affectionately a 'slug'. Due to the fact that it originally shipped with some open source software installed, the makers of the device were required to open its source code, and the device has become popular with home-brew people all over. One of the fun things you can do with it is install Linux, and use the device as a server. Which I did recently.

Now, thanks to the wonderful legions of crazy people with more skill at compiling than I have, you can install MySQL, the database server often used for web development, on the slug with a simple one-line command. Of course, then you get to configure it, but that's the easy part (?).

So now I have PHP working on my laptop, and MySQL running upstairs on a hacked piece of hardware originally meant to do nothing even remotely related to what I'm using it for. After some fiddling, I managed to get PHP talking to the database, and I have just successfully run my first query on the sample database I created, pulling in four addresses from the fake address book.

That's it - no big story, just geeky excitement over a success using crazy tools.

David commented:

Ironically, all of this was to prepare for an interview in which one of the questions was 'how do you create a hyperlink?' Sasha pointed out I may have worked a little too hard to prepare. But now my slug runs MySQL!!!

By the way - this is one of the sites I used to get this all running. It's really great. So if you're a slug user who needs some help, head there!


on Wed Dec 10 00:07:44 2008

Bruce Fields commented:

That's awesome.  If I was you I would've taken the nslu2 in!

on Tue Dec 16 18:51:23 2008

Add a Comment
Back to the Blog