Archive for November, 2004

Second-Story Roof Terror for the Sake of Christmas Lights

2004-11-29 Leave a comment

I have a two story house. Its tall and it has a fairly-steeply sloped roof. Last year, I strung Christmas lights from the main story roofline, above the porch and the front of the garage, from a nice safe step ladder on the ground, and things were good.

This year, my neighbours, the Griswolds, have installed 20,000 lights of various colours, dimming my house into obscurity by the glare. My wife would not settle for this state of affairs and insisted on us having lights on the front of the upper roof. So, fear of heights choked to a meek whimper, I climbed out my son’s bedroom window and hopped up on the upper roof yesterday carrying strings of lights and extension cords and with little clips filling my pockets.

With a precarious hold on the edge of my roof, and lying gingerly in pidgeon poop, I carefully clipped the lights onto the roof while trying not to plunge to my death. I kissed the floor in my son’s room upon climbing back in through the window. After having done that, I have no problem seeing why people leave those damn things up all year round.

They do look great though.

Categories: Personal

Update to Java Fun and Games

2004-11-25 Leave a comment

Bloody hell! Java Runtime.exec() sucks royally. Or maybe it doesn’t, I’m not sure. What I do know is that it has annoyed me to no end. I’m trying to get rsync to run multiple times sequentially on NetWare. If you run rsync sequentially on NetWare in a script (ncf file) it runs all instances concurrently. In other words, the script doesn’t wait for the first instance of rsync to return, it plows right through and launches them all, causing major CPU hoggage. We thought to get around this we could write a java wrapper that would use the Runtime.exe() with waitFor() to force the system to wait for the first rsync command to complete before starting the second, and so on. Unfortunately, even using that method, rsync returns a zero to the p.waitFor() call immediately, and then proceeds to run, causing my java wrapper to execute all my rsync statements concurrently. Frak! as they say on Battlestar Galactica.

It seems like when you launch rsync on NetWare, it immediately detaches from stdin, stdout, stderr, and the controlling terminal, leaving you in the lurch with no way to interact with the running program, or to act on the return code. This makes rsync eminently un-scriptable. I was kind-of counting on the return code being usable to automatically send a “Success” or “Failure” email to my status account.

I guess it’s back to the drawing board.

Categories: Storage and Backup

Back to Java Programming for Rsync

2004-11-23 4 comments

Now that I’m mostly done my work reviewing another office’s project, I can return to my work in deploying our new backup solution based on Rsync. I still have some work to do on the project review but now I’m waiting for documentation, so I have some time to work on my rsync stuff.

The new backup system will replace most tape in our organization by using disk-to-disk replication. I’ve talked about this before so see my article on Novell Cool Solutions or my previous posts about this. The backup system works like this:

A server that needs to be backed up will run a program to retrieve instructions for backing itself up from a centralized server. It will then execute those instructions to perform the backup. It will then email the results of the backup to the network administrator. Pretty simple. I’m doing this with java code as the managing code, and rsync as the replicator. The java program called ae_bu is started by cron, and uses rsync to download it’s instructions from the centralized server. It then executes the instructions line by line (which are a bunch of rsync commands) and keeps track of the success or failure of each command. Then it emails these results to the administrator. The reason that I’m using java instead of shell scripting or something like that is because on NetWare, you can’t make a script wait for an rsync command, so three rsync commands end up executing concurrently, which hogs the cpu. In addition it seemed like it would be a hassle to send email from a NetWare script so we just use javamail. It works pretty good.

Today I got the code finished on the java piece and we’re starting to deploy it for real.

Categories: Storage and Backup

Emily’s Teaching Me Handwriting

2004-11-22 Leave a comment

In Grade 3 you get to learn handwriting (ie script) as opposed to printing. Emily is happily showing me all the words she knows how to write, both in English and in French. Its been so long since I did handwriting in school (or indeed even did a lot of handwriting in the course of doing work) so I’m relearning as we go. She learned the last three letters today, “j”, “k”, “x” and “z”, which are presumably the least-used letters, and so come last in the sequence.

She has picked it up pretty quickly. I think my kids are going to have the same problems as me in school: Not enough challenge, and bored out of their trees.

Categories: Personal

Scum Sucking Spammers

2004-11-22 1 comment

I had a bit of fun with spammers on my weblog today. I run several things on this server, one of which I access on a semi-continuous basis throughout the day. Therefore I notice when the server is having problems. I was trying to talk to the server at about 10:00 this morning and I noticed it was pretty sluggish. I went over to the server room and looked at it and noticed that the hard drive light was lit solidly, which is unusual for this box. Then I tried logging into the text console, and it took a very long time. Running the UNIX command top showed that there were many instances of perl running, and perl is the program that handles this weblog.

I suspected that somebody or multiple somebodies were spamming the comment section of the server. I have already had to disable trackback pings because of spammers. I couldn’t get to the management console of the weblog, because the server was overloaded, so I used grep to look through the comment files for unsavory content, and sure enough, my comments were laced with references to pornographic websites.

I shut down apache, reconfigured the access control to only allow access to my local network, and then got onto the blog management interface, and deleted over 1700 new comments that were posted today. Then, I changed the commenting section to require administrative approval on the first post, so that people could still comment but I’d have editorial control over what appeared on the site. Hopefully that will deter the spammers. I’ve now re-enabled public access to the site.

I want to try to upgrade my blog engine so that it has spam-prevention via a requirement for posters to enter a number that they see in a graphic on the screen, so that I don’t have to review the posts but I will still have spam protection. In the mean time, if you encounter any spammers in the real world, please give them a serious wedgie for me.

Categories: Editorial

Wireless in SuSE Linux 9.2

2004-11-19 Leave a comment

Well, I just completed my first out-of-town trip with SuSE Linux Pro 9.2 on my machine, and everything worked great, except for one thing: Wireless access. My Thinkpad has a Centrino wireless chipset, which of course makes it less than fun to get working because of the early state of the drivers. However, in the office, where I know the SSID and passphrase of my access point, it’s not too difficult to get connected to the wireless network using YaST to enable and disable my wireless card. I can also do that from the commandline using ifup. This is sadly not the case for public access points. The Calgary airport has free open access points, or so I’ve heard. I couldn’t figure out how to find out the SSID to allow me to connect to it. SuSE doesn’t seem to have a nice gui tool to let me see the various access points within range and then connect to them. Maybe it’s just me, so somebody please fill me in.

Categories: Neat Geek Stuff

Fun With

2004-11-10 Leave a comment

Well, SUSE Linux 9.2 is cool and all, but in 9.1, SUSE came with XFree86 as it’s X-window system. 9.2 comes with’s release, which is a bit different. I use an IBM Thinkpad R40, which has an embedded Radeon 7500 with dual display controllers in it. The machine came with Windows XP, which I quickly deleted, but before I did, I verified that it could work with dual dsplays, having one big desktop across two monitors, the built-in screen and an external display.

When I installed SUSE Linux 9.0 on it, I had to hack the XFree86 configuration file a bit to get this same dual display effect (called Xinerama mode in X) because SUSE’s X configuration tool SAX2 wouldn’t configure dual displays with a single card, but once I got it working, it worked great, and stuck with me without modification when I upgraded to SUSE Linux 9.1.

When I installed 9.2 yesterday, I of course kept my XF86Config file just in case. The new version’s SAX2 still wouldn’t connfigure my X with two displays, so I just tried copying in my old XF86Config file, but that made the graphical environment not work at all. Then, I tried futzing with that file as a start. I couldn’t get it to work. Finally, after much googling, I discovered that the radeon driver in has something called Merged Framebuffer, which lets the card’s two outputs use one big framebuffer to essentially act like one big monitor. I hacked that into my XF86Config file, and lo and behold there were two displays. Great. Here is a working configuration file for Thinkpad R40s in SUSE Linux 9.1 for dual display using the old configuration, and Here is a working configuration file for SUSE Linux 9.2 using

Categories: Neat Geek Stuff

Get every new post delivered to your Inbox.