Archive for the ‘web development’ Category


Warp Drive & Transporters are back online—sort of

   Posted by: Scrivener

Figure 1: This graphic was done in Photoshop 7 (yeah, that's right 7--we don't need no 'steenking' CS3/CS4 here.) The PC pictured is an actual custom-built PC. Its picture was taken from the internet. The PC’s image was then overlaid upon a standard Star Trek type background used so often to show the Enterprise in orbit. Finally, the PC image layer was corrected for perspective so that the computer appears to actually be in orbit.

Figure 1: This graphic was done in Photoshop 7 (yeah, that's right 7--we don't need no 'steenking' CS3/CS4 here.) The PC pictured is an actual custom-built PC. Its picture was taken from the internet. The PC’s image was then overlaid upon a standard Star Trek type background used so often to show the Enterprise in orbit. Finally, the PC image layer was corrected for perspective so that the computer appears to actually be in orbit.

“Mr. Scott, I need warp drive now!”

Warp drive and transporters are back online—well, sort of anyway.

Some of you may remember that our coven and magick school website, has been down since late October. During that time, and since then, I’ve been using a Star Trek metaphor—to say nothing of alliteration—to describe my technical travails.

I’m pleased to announce –whom am I kidding, I’m freaking ecstatic—that three days ago, full functionality was restored for the Circle of the Dark Moon website. Boy, I’ve been waiting awhile to make this announcement.

As I said earlier, the trouble started last October, however, the hard drive had been acting up for months. For at least six months prior to the great disk crash of 2009, sluggish performance, system freezes, and boot failures had been a fact of operational life for my aging server/development/gaming platform. Therefore, I had ample warning, and many opportunities to backup the system, which I did religiously every few weeks.

The machine in question was activated in 2005, at a little shop of horrors in Fort Lauderdale, Florida, which built custom PCs. The computer contained an ASUS motherboard with a Celeron dual processor, 2 GB of memory, the highest-end graphics card that its antiquated data bus and AGP graphics port could support, and a stereo sound card. It ran Windows XP SP3, was used to complete my novel, ran my IIS web server, it also ran a MySQL server, and was my personal portal to the World of Warcraft. In its day, this PC was the Enterprise of computers; sadly, today it is a garbage scow, or even worse, an overly large door jam.

So why would a hard disk crashing on my personal PC affect the uptime of a web page you ask. A few words about the topology of the Circle of the Dark Moon web site are in order. Back when I first chose GoDaddy as my domain registrar and web host, I was delighted that they supported a good selection of databases: SQL Server, Access, and MySQL. I was also pleased that they supported .net and IIS web servers as well as Apache. Finally, the price was right and they have actual people you can talk to (and whose native language is English, and are from the United States and not some offshore call center) for technical support and to answer questions. All of these factors led to me choosing GoDaddy as the home for our coven and magick school website.

However, there was a hitch. There always is. Actually, there were two but we’ll speak more of that later. The BIG hitch was that GoDaddy’s implementation of MySQL doesn’t support non-deterministic queries. For those of you who aren’t DBAs, a non-deterministic query is a query that given the same parameters doesn’t always return the same result set. For instance, a query that calls to list all first-degree students, and the current date is a non-deterministic query because if ran on two different dates the query would return different results given the difference in the date values for current date.

Then, I got the bright idea to see if I could manage to circumvent my ISP’s draconian practice of blocking port 80, and learn how to configure a router, and set up a MySQL server and thus serve some of the pages from an offsite server (offsite from GoDaddy’s perspective.)

The other hitch concerning GoDaddy and MySQL is that at that time, GoDaddy did not allow direct access to database management functions. Even now, you’re stuck with using phpMyAdmin, the crappiest control console in the universe, or SSH tunneling if you happen to be on a UNIX server. Therefore, if I have to run a local copy of the database anyway, and then FTP any database updates made to the local copy to the GoDaddy servers, I may as well run my own MySQL server and eliminate the extra steps.

All of these technical meanderings lead us to the near present and the great crash-and-burn of 2009. The hard disk died, and any pages on the site requiring database access, suddenly erred and flared because there was no database to connect to and retrieve information. Yes, for security reasons of my own, I coded the pages to crash ignominiously if a database error occurred.

Post crash 2009, was spent ensuring that the database backups were current and reloading any information that was lost, and trying to come up with a solution that would get the website up again fast so that our search engine ratings wouldn’t tank. Well, they did anyway. During the intervening time span, I managed to get a few of the pages up but for the most part the web site was FUBARed until it could connect to a database.

About that time, to be frank, I just gave up for a while. I was discouraged. I felt that nobody really cared whether the site was up or not. Moreover, why was I doing any of this stuff anyway? What possible difference did I think I was making? I was unemployed. I had no money for a new hard drive let alone a new server; and, porting the entire site (including the pages previously served locally) up onto GoDaddy just seemed fraught with more problems than solutions. I knew that using the old configuration of the website, the code was solid; it worked, and it was secure. I had no idea of what coding changes I would need to make to accommodate GoDaddy’s implementation of MySQL (well, I did and it worried me), and what other ‘gotchas’ (I could imagine) I would encounter following that path. Besides, I figured that if nobody cared about the site, I didn’t need to care either, might as well go play some WoW.

Time passed up to about three weeks ago. After working a couple of spells to ensure a continuation of our meager sustenance funds, I combined some birthday and Yule gift monies and bought a new 500 GB hard drive. The new drive sat on my desk for a few days while I attended to some other neglected websites. I finally installed the drive, formatted it, installed Windows, and hit yet another snag. Apparently, either I misplaced the little blue-green piece of paper with the endless alphanumeric product code, or it was lost in the house fire (Sept. 2008), or possibly I threw it out, mistaking it for a similar piece of paper for a now defunct copy of Office. At any rate, I couldn’t activate my bloody copy of Windows—curse you, and your money-grubbing-damn-the-ease-of-reuse-but-let-no-dollar-go-uncollected minions, Bill Gates. Merrily, it was on to plan ‘B’.

Plan ‘B’ was not without its moments either.

I came up with the bright idea to run the website pages requiring database access from another computer while I fiddled with the original server to get Windows to activate. That idea was okay as far as it went. However, since I’m never one to leave well enough alone; and since I was already mucking about in the database; I thought, why not upgrade to MySQL 5.1 while I was at it. What a great idea, I concurred—not. I was about to break Terry’s prime directive of software development #1,024: when you’re original intent was merely to drain the swamp, and you’re already up to your ass in alligators, don’t go looking for more alligators.

The upgrade to MySQL 5.1 did not go well. Migration tools that were suppose to assist in the effort instead migrated south, corrupting tables, and dropping stored procedures while they went. Then it was time to use the “special” tools to repair what the migration tool had done.

Tell me, why is it everyone of these oh-so-special tools have little to no documentation. On the other hand, if they do have documentation, the documentation is written in such a way that the instructions depend upon having read another document that is no longer included with the current release. In addition, why is it that all these tools can only be used from a C :> prompt and have tens, if not hundreds, of slash command parameters that are only vaguely explained? I’ll tell you why. In programmer/hacker/slacker subculture, the feeling is that if it was hard to write, it should be hard to understand and use as well. Sounds to me like a recipe for techno-has-been job security, even if that ‘job’ is writing open source software for no pay.

The people who write these tools (and are probably very gifted programmers) need to understand that while real men code only at the C:> prompt, and assemble bytes through sheer force of will and their bare hands, that real design work is done with the aid of a visual interface.

One MySQL rollback to version 5, an installation and configuration of IIS, and router reconfiguration later and the Circle of the Dark Moon website is finally up again. So while work continues on the original server, at least the coven has a website again. Users may notice the computer being used as a server now (a laptop), may be a little slower than the previous machine when serving pages. But, eventually, we’ll move the site back onto a dedicated server, and then we’ll have a mirror site to boot. Top that you corporate HR pinheads of little imagination who that said, that because of my background, I couldn’t possibly be hired as a system administrator. After all, I didn’t have a piece of sheepskin that said I had paid the required extortion (tuition) to an institute of higher earning (er, I meant ‘learning’) and as result, they gave me a worthless piece of  paper with nice lettering, and thus deigned to knight me as a DBA/Sys Admin. Remember, the best and the brightest are always self-taught. That fact is paramount to the hacker credo.

Do you want to know something ironic? After all this miscarriage of software engineering, all the battling the slings and arrows of outrageous technological misfortune to resurrect this site, all the pulling one Rube Goldberg software solution after another out of thin air to make things work, do you know who the first visitor was to the site?

It was some pond-scum slime of a spammer from Romania.

Go figure.