server outage

sorry for the short server outage here. I wasn’t paying attention to what I was doing and managed to drive the load of the server up “a little bit”

ipx10737:/usr/local# w
13:22:25 up 64 days, 7:35, 3 users, load average: 122.84, 110.94, 96.51

fixed the problem, shouldn’t happen again.

sun, debian, nagios and phpBB

Ok ok, I haven’t updated this here for a while. So let’s have a quick simmary of what I’ve been doing the last weeks …

Nagios
Nagios is software to monitor networked “things”. Actually you could probably write plugins for it to monitor just about anything, evenstuff not networked, but that is what it basically aims at. Anyway, basically it’s advantage is that it has a robust basic framework that is highly modular and extendable. So you can do anything as basic as “ping that host and tell my when you get timeouts” or do anything as strange as “alert me if my mailserver gets more than x spam per min”. As you may have guessed, in the default installation, the tool is not only very powerful, but it also has very ugly gui (I wasn’t really surprised). Luckily admins out there have already written some excellent plugins to make the gui very nice. I installed NagVis and am completely pleased with it. My “Nagios ToDo List” still has “gathering performace data” on it so I hope I get around to doing that sometime the next few weeks.

SUN + Debian
I needed a nice piece of hardware that wasn’t prone to go and die on me the next time a power outage happens to put nagios on (ok, I’m writing this in the wrong order, 1st I installed the hardware, then nagios). Since this little project here is at work to monitor some of our systems, but we don’t have any budget, I had to improvise a bit. The official software we should use for monitoring sucks … real, real hard. a system could be offline for hours before we get notified. So I have this nice little SUN Netra T1 laying around. Actually it has been just laying around at least since 2001 when it landed in our department by chance. It’s not much, 2x400Mhz CPU, I can’t remember how much RAM, and I put 2x36GB disk drives in it. Personally, I love the Netra because it is only 1U big, you can fit this thing in just about anywhere, we call it “the pizza box”.
So now is where Debian enters the story. Normally I would just install Solaris 8 or 9 on the Netra. But I decided on Debian for 2 reasons: 1) It should be possible and I have never done it before and 2) sorry SUN, but your package management tools are crap. yeah, that is maybe mean and harsh, but also very true. sunfreeware is probably the only reason so many solaris admins have been able to keep their sanity. Hooking up the console port to my linux pc was no problem (just use a standard cisco console cable), the Debian installer worked pretty cleanly. There was just one bump, a pretty big one too. The installer works great if you don’t want to do any fancy partitioning. Unfortunatly I wanted both drives running in a software raid 1 in case one of my drives decides to die. I’ll omit the long story of me trying to get this to work. I managed to get my raid running, (no thanks to the installer). And after that everything was a breeze. I’m very satisfied with the performance. The rest of the installation was no problem (basic security hardening, installaing apache, mysql and php), everyday stuff. The only thing left on my “Netra ToDo List” is setting up PAM to use OTP for authentication.

phpBB
Version 3 of phpBB (forum software) went gold a bout a week ago. So I started preparing the upgrade and pulled it through today. Weighhing out the pros and cons of trying to convert the phpBB 2 database to phpBB 3 I decided to not try. Well, I did actually look at the database structure of the new version, but the phpbb_user_group table is still as starnge as ever (people with a multiple personality disorder would feel at home here since every user is at least in a group consisting of himself alone). Yeah, so instead of risking a broken database I decided to set the old forum to read only and have the people register again for the new forum.
Ok, this is definatly very un-ryan-like. I must be getting older 😉

Bash scripting

Before I forget it again, a quick and dirty way to have a shell script do some stuff parallel (forking off and having the parent wait till they are all done)

PSP Radio

Yeah, having a bit of fun with the program PSP Radio. For those who don’t know the program, its a homebrew application for the PSP that allows you to listen to radio streams from the Internet (surf over to shoutcast.com for a nice listing of many stations).

PSPSo anyway, while I was in the kitchen today i kinda got tired of the normal radio stations so I grabbed my PSP, fired up the application, connected to the Internet via Wifi and went searching the house for a cable to hook up my PSP to the radio (trust me, you don’t want to use the built in speakers of the PSP).

Found a cable, and in the picture you can see the whole setup.

Worked like a charm. Internet radio streamed directly into the radio in the kitchen, thanks to the PSP (and of course unofficial firmware that is required to use homebrew software).

Synchronizing files over the internet

I have some files I like to keep current between my 2 computers. The problem is that those 2 computers are about 30km apart from each other. Simply copying the files to a USB Stick manually was out of the question since the files in question are configuration/plugins/… from an application and a) I have no idea which ones change when and b) there are about 9000 files. So I went on a search in the Internet and found Allway Sync, works like a charm. I’ve been using it for the last few months, but as the number of files it has to monitor grows I more and more often run into warning messages from the program, that I should consider using the “Pro” version that costs $$$.

Since the files all aren’t big, just numerous. And since I more and more often forget to sync my USB stick I decided to build myself an own solution that works over the Internet with freeware. no more forgetting to sync the USB stick (or syncing and then forgetting to take the USB stick with me. doh.).
My new solution is basically based on 3 components. Storing the files online, connecting the online storage to the computers, and syncing the files. Storing and accessing the online storage with windows … well since my Linux server was going to be the storage and my windows clients were going to be accessing it, I couldn’t get around looking at Samba. Samba is not a good idea. Sure it’s nice for windows, just throw the IP, username and password at it and presto, it pops up as a drive letter. But trust me, anyone will tell you samba (or any windows shares for that matter) are not a good idea in the Internet. While searching for alternatives I found a program called Netdrive that allows you to connect a webdav directory as a drive letter. Very nice. So I set up webdav on my webserver and use a Microsoft program Synctoy for synchronisation.

So that was basically what I did this morning between watching comics in TV and waiting for lunch.