If you have a web site, don’t forget Google webmaster tools

I’ve been messing with Google’s webmaster tools.  I definitely wish I’d looked at them a lot sooner. You sign up, prove you own the web site (I inserted a meta tag), and then they start putting together everything they know about your site. It takes a while for all of the data to trickle in at first, or at least it’s taking a while for me, since I’m pushing 2,000 pages. But I think it’s invaluable for all but the very smallest, simplest site. Read more

Fix host hijacks or host file hijacks for free

Sometimes your antivirus will tell you that you have host hijacks or host file hijacks, but not elaborate on how to fix them. Some people charge way too much to fix them. Here’s how to fix host hijacks or host file hijacks for free.

A former classmate’s computer suddenly stopped letting him get to search engines. Aside from that, his computer appeared to be normal.

Fortunately he had some antivirus and antispyware software installed, so he was able to run it and get a relatively clean bill of health, but he still couldn’t use Google or Bing or Yahoo.

One of the pieces of software he ran mentioned a host hijack or hosts file hijack, but didn’t offer to clean it up without ponying up some serious bucks.

That was enough to tell me how to clean it up though. You don’t have to buy anything. Read more

Bias is good?

Blekko could be an idea whose time has come. It’s a search engine with bias.

The idea is, you punch in what you’re looking for, and include a slash term to bias the search in a particular direction. That could help filter out spam sites–sites that are loaded with keywords and a few links but no real content, for instance.

But I imagine some significant percentage of its users will use it to try to find content they already agree with. Read more

Cheap buildings for a train layout

Cheap buildings for a train layout

I’ve read about The New Pretty Village, published in book form by Dover Publications in 1980, as a source of buildings for a train layout, particularly a layout featuring tin litho Marx or prewar trains. Now I’ve got one in my hot little hands. I found some pictures of a reproduction online, and Marx expert Walt Hiteshew’s layout has used them as well.

Read more

If you use Mozilla, you need to read this

No sooner than I presented Mozilla, specifically Mozilla Firefox, as a safe alternative to Internet Explorer did an exploit for Mozilla show up. Argh!

At least the fix came out swiftly and installs painlessly. Visit the page, click another link, wait a minute or so, and then restart the browser. Badda bing, badda boom, you’re patched. No reboot necessary.I still stand by my recommendation of Mozilla, whether it’s the entire bloatware Mozilla suite or the lightweight Mozilla Firefox, over IE. Why? Lessons learned from Linux.

When a vulnerability is discovered in a Microsoft product, an unpredictable length of time passes before the vulnerability is patched. Sometimes it’s a matter of days, but sometimes the length of time is just plain ridiculous. Forgetting for a minute how frequently patches come out–a case can be made that Linux gets more patches than Windows but just as strong of a case can be made that it gets less–the length of time that passes between the instant the vulnerability is discovered and announced and the release of a patch is usually very small. Usually it’s a matter of hours.

The reason is simple. Lots and lots of eyeballs looking at the code. And in Open Source, having your name in the code is a badge of honor. It’s a big, big line on a resume to say you wrote a line of code in the Linux kernel.

Other open-source software gets patched just as quickly, however. Not every open source programmer is comfortable maintaining operating system kernels. And no self-respecting programmer wants his or her system hacked due to a vulnerability in a piece of software she or he was perfectly capable of fixing.

This particular vulnerability stems from a little-known capability in Mozilla. I’m sure there was a legitimate use for it at one time, but were Mozilla being designed and rewritten from scratch today, I can’t see how it would possibly be implemented because the potential for abuse is huge. The code’s gone now. It won’t be in Firefox 0.92 or the next revision of the Mozilla suite.

Will there be other instances of this? Sure. Probably less of it, since Mozilla was a total rewrite of Netscape and the engine is entirely different from the one in Netscape 4.x. The IE codebase goes back to the early 1990s, as it’s based on the old NCSA Mosaic code, which Microsoft licensed from Spyglass. (Go into IE and hit Help, About to see for yourself.) There’s much more potential for harmful dead wood in IE than in Mozilla, but the presence of some in either is inevitable.

But at the end of this year’s storm season, I expect Mozilla to come out a lot stronger because most of the dead wood will be shaken out. I don’t expect the same from IE. The codebase is too old, the teams too disparate, and the motivations behind the changes that have been made were too different from Mozilla.

I’m standing by my browser.

Looks like Windows XP SP2 is gonna break stuff

I’m sure you’ve read already that Service Pack 2 for Windows XP is going to break some software in the name of enhanced security. And I’m sure you’ve read lots of howls of protest. And maybe some smug snide asides too.

What I’m sure you haven’t read is what to do about those compatibility issues.

Keep reading.First and foremost, you should keep your main Windows installation up to date. For everyday functions like word processing and e-mail, Windows XP SP2 should do just fine. It’s the old stuff that’s likely to break. And the old stuff is likely to be the stuff you only use occasionally.

So here’s what you do. Dual-boot Windows XP SP2 with an older version. That older version could be Windows XP SP1, or it could be something older.

How? The easiest way is to use a bootloader like XOSL. There might be others out there, but XOSL is proven, and it’s great. People have used it to install literally dozens of OSs on one computer.

If you’ve got software that hasn’t run right since you upgraded to XP, this is your chance to correct it too. With XOSL, lots of versions of Windows can coexist. You can even install Windows 3.1 if you can manage to locate drivers for your new hardware. (Though I can’t imagine why…. Windows 3.1 was so bad it drove me to run OS/2 for three years.)

After you get your old versions of Windows installed, boot into them and install your old software that doesn’t like XP SP2. Badda bing, badda boom, you can run your old stuff, and when you’re doing your everyday stuff, you can do the socially responsible thing and be up to date. Everybody wins.

Or, if lots of old software’s going to quit running anyway, you could just take it as your cue to switch to Linux…

A Bing in Marx clothing

The sign said “50% off all items $25 and under. Other items, make offer.” I spied a table full of beat-up Marx trains. I picked through them. There were two 3/16 scale tinplate boxcars and cabooses, paired with a Marx Commodore Vanderbilt locomotive, marked as a “set.” Price: $79. At least two of the cars were missing wheels and the loco had bad paint. Heaven only knew if it ran. The bundle wasn’t worth $20. Likewise for a six-inch bundle. Two common six-inch cars, rusty and one missing a coupler, paired with a locomotive with no wheels or engine or paint–about 90% naked, except for rust–for $65. I’d have been willing to pay $7.

I almost overlooked the three six-inch passenger cars that were almost completely devoid of paint. It’s a good thing I didn’t.

Read more

I shoulda stayed home and read a book!

The last few days have been nuts. I’ve been wrestling with tape drives, trying to get them to work on a brain-dead operating system from a company in Redmond whose project is headed up by a potty-mouthed ex-DEC employee. Its initials are N and T.
And, riddle me this, someone, please. On Unix, I just hook up the tape drive, then I type this:


tar -cf /dev/tape /home

Badda bing, badda boom, I got me a backup of all my user data, assuming the drive is good. One command, keyed in. One command that’s no harder to remember than the phone number of that pretty girl you met last week. (Or wish you met last week, whatever the case may be.) What’s hard about that?

In NT, you plug in the drive, you load device drivers, you load your backup software, it doesn’t recognize it, so you stop and start 47 services, then it finally recognizes the drive, and then you stumble around the backup software trying to figure out just how you tell it to make you a tape. By the time you figure all this out, in Unix, you’d have finished the backup.

Ugh. So, when I get home, I don’t want to have much of anything to do with these brain-dead machines infected with a virus written in Redmond. And the virus from Cupertino isn’t any better. I don’t have much appetite for my computers that run Linux either, because, well, it reminds me of the crap spewing out of Redmond and Cupertino. It’s kind of like a messy breakup, you know? You meet a girl who’s nothing like the last girl, but you don’t want to have anything to do with her because she’s female, breathes oxygen, and she’s carbon-based, so there’s the off chance she might remind you of that last disaster.

Hence the mail piling up in my inbox and the lack of updates for a couple of days.

So what have I been doing?

I’ve been reading books. I finished Dave Barry Turns 40 a couple of nights ago. It wasn’t as good as his later books, but it had a few howlers and part of a chapter that was actually sincere and serious and really made me think. It was about his mother after his dad died. They lived their lives together in this brick house he built himself, and after he died in 1984, she would write on her calendar, on April 24, “Dave died today, 1984. Come back Dave.” And on the day of their anniversary, she would write, “Married Dave, 1942. Best thing that ever happened to me.”

Finally, the house turned out to be too much for her to handle on her own, so she sold it and moved away.

And he went on for another page or two, talking about the last years of her life, trying to relate to her and failing miserably, as she wandered from place to place, living with relatives, never finding a place to call home, because what she really wanted was that brick house back with Dave Sr. in it.

As she died, she had that smile that all mothers have, that smile that tries to reassure her boy that everything’s going to be OK.

The story had a flashbulb effect on me. Partly because it came from Dave Barry, the guy who went on and on about cell phones, and how people who get cell phones have no escape at all, and sometimes they’re trapped in their cars for months, stuck on the phone, surviving on drive-thru food and peeing in the ashtray.

I can’t say I read very many things that jar me, but that short essay definitely did, especially the insight it gave on his parents’ relationship. How many people feel that way about the person they married 42 years ago? All too few, in this day and age. And since it came from the person I expected it from the least, it made it all the more jarring.

Since then, I’ve been reading White Palace. I understand it was made into a movie in the early 90s. It takes place in St. Louis. It’s a book about a relationship, and the relationship has absolutely zero substance. Sex sex sex sex sex sex sex. And more sex. (I wonder what that’s going to do to my Google rankings…) I really don’t want to like the book, especially after having my world rocked by a short essay that Dave Barry snuck into a comedy book and apologized about.

But I learned something.

The book has no plot. Guy meets girl in a bar. Guy and girl begin torrid affair. It’s a cheesy romance-novel plot. You find better plots laying outside on the sidewalk or in the parking lot.

The book does have compelling characters. The main character is 27 and his beloved wife died tragically when they were both 25. I’m 27 so I can relate to the guy on that level. And all of us have lost someone that we miss. And there’s a lot more about the guy too. I won’t give it all away. His (ahem) girlfriend has more substance than a plastic blow-up doll, although it would have been very easy not to give the character any substance. She’s in her early 40s, she drinks a lot, and she forgets to pay her bills. (At least she has priorities.) She works in a fast-food joint, and at at least one point in the book, she stops dead in her tracks, looks the character in the eye, and asks, “Why are you so good to me?”

Heart-wrenching line, that.

OK, so the book’s got good, well-developed characters. It also has a good setting. It takes place in St. Louis, and you can tell from the way he describes it all that he’s actually lived here. The main character lives in Kirkwood, and any St. Louisan instantly draws a mental picture. She lives in Dogtown, and any St. Louisan instantly draws a mental picture. He draws in places that St. Louisans are familiar with. He talks about Tony’s restaurant, and the book’s name comes from a fast-food joint that litters the St. Louis landscape (without infringing on a trademark). He even works in Concordia Seminary, and Cindy’s Motel. Any St. Louisan will instantly love the book because it describes home. I wonder how many St. Louisans utter aloud the words, “Where’d you go to high school?” while reading it.

He made St. Louis real, and he made it compelling.

Great characters, great setting… He didn’t need a plot.

And now I find myself itching to write fiction. I get that bug every couple of years. I wrote 100 pages’ worth of novel while I was in college. It was the opposite of White Palace. It had a good plot. Maybe even better than good, but I can’t be objective about my own work. But to the very few people I’ve described it to, it’s been riveting. But the characters were awful and so was the setting.

That manuscript is lost, as far as I know. Some version of it might be on my Amiga’s hard drive, but I wouldn’t hold my breath. No great loss. I intend some day to revisit that plot, plop it down in a compelling setting, and drop some compelling characters into it. There’s really only one question.

Have I lived enough yet to pull it off?

Who knows. Right now, who cares? I’m gonna go read some more. I think the UV from this monitor is getting to my head.

Stopping spam.

Forget what I wrote yesterday. I was going to post the stuff I wrote in Ohio when I realized it isn’t all that good, it’s definitely not useful, and the people who annoy me the most are the people who can’t get over themselves. No one cares what I ate for breakfast, and the only people who care what went on in Ohio already know.
So here’s something useful instead. It’s the coolest thing I’ve found all year. Maybe all decade, for that matter.

Spam begone. I hate spam. It wastes my time and my bandwidth and, ultimately, my money. I’ve seen some estimates that spam costs ISPs as much as $5 per month per account. You’d better believe they’re passing those losses on to you.

There are tons and tons of anti-spam solutions out there, but most of them run on the mailserver side, so for an end-user to use them, they have to set up a mail server and either use it for mail or run fetchmail to pull the mail in from ISP’s mail servers. I’ve done that, but it’s convoluted. But that’s trivial compared to setting up the anti-spam kits.

I was crusing along, vaguely happy, when my local mailserver developed bad sectors on the hard drive, so one day when I went to read my mail, I heard clunking noises. I turned around, flipped on the power switch to the server’s attached monitor, and saw read errors. Hmm. I hope that mail wasn’t important…

Eventually I shut down my mail server and put up with the spam, hoping I’d come up with a better idea.

I found it in a Perl script called disspam.pl, written by Mina Naguib.

It took a little doing to get it running in Debian. Theoretically it’ll run on any OS that has Perl installed. Here’s what I did in Debian:

su (to become root)
apt-get install libnet-perl (Perl couldn’t see the network without this, so the next command in this sequence was failing. This hopefully isn’t necessary on other distros, as I have no idea what the equivalent would be.)
perl -MCPAN -e shell (as per readme–I accepted the defaults, then when it asked for CPAN servers, I told it my continent and country. Then it gave me 48 choices. I picked a handful at random, since none were any more obviously close to me than others.)
install Net::POP3 (as per readme)
quit
cp sample.conf disspam.conf
chmod 755 disspam.pl

Next, I loaded up disspam.conf into a text editor. It looks just like a Windows-ish INI file.

The second line gives me an exclude list. It’ll take names and e-mail addresses. So I put in a few important names that could possibly be blocked (friends with AOL and Hotmail addresses). That way if their ISPs ever misbehave and get blacklisted, their mail will still get to me. Then I popped down to the end of the file and configured my POP3 mailbox. I had an account I hadn’t read in a week, so I figured I’d get a good test. Just drop in your username, password, and POP3 server like you would for your e-mail client. If you have more than one account, copy and paste the section.

Bada bing, bada boom. You’re set. Run disspam.pl and watch. In my case, it flagged and deleted about a dozen messages, typical of what I usually get, like mail offering me Viagra or access to horny cheerleaders or how to find out anything about anyone (which I already know–I have a journalism degree). The only questionable thing it flagged was mail from MLB.com. I can’t get off their mailing list ever since I voted online for the All-Star game. No importa, I never read that mail anyway. I could have always added MLB.com to my exclude list if what they had to say mattered to me.

But if you’re like me and get lots of mail–that was my less-busy account–and about half of it is spam, that stuff’s going to scroll by really fast. So here’s what I recommend doing: when you execute disspam.pl, use the following command line:

~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log

Then you can examine disspam.log. If disspam ever deletes something it shouldn’t have, you can add the person to your exclude list and e-mail them to ask what they wanted. It looks to be less work than deleting all that spam. Probably less embarrassing too. Have you ever accidentally opened one of those horny cheerleader e-mail messages when there were people around? Yikes!

I fired up Ximian Evolution, pulled down my mail, and had 15 new messages. No spam. None. Sweet bliss.

It’s just version 0.05 and the author considers it beta, but I love it already.

Unix’s power allows you to string simple tools together to make powerful ones. Here are some suggestions.

You can e-mail the log to yourself with these commands:

mail -s disspam [your_address] rm ~/disspam/disspam.log

If you want the computer to do all the work for you, here’s the command sequence:

cronttab

Then add these entries:

0 0 * * * mail -s disspam [your_address] * 0 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log

If you read your mail on the same machine that runs disspam, you can substitute your user account name for your e-mail address and save your ISP a little traffic.

You’ll have to provide explicit paths for disspam.pl and disspam.conf.

The first entry causes it to mail the log at midnight, then delete the original. The second entry filters your inbox(es) on the hour, every hour. To filter more frequently you can add more lines:


* 10 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log
* 20 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log
* 30 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log
* 40 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log
* 50 * * * ~/disspam/disspam.pl ~/disspam/disspam.conf >> ~/disspam/disspam.log

This program shouldn’t be necessary for very long. It’s short and simple (4.5K worth of Perl) so there’s no reason why mail clients shouldn’t start incorporating similar code. Until they do, you run the risk of disspam and your mail client getting out of sync and some spam coming through. If you read your mail on a Linux box with an mbox-compliant client like Sylpheed or Balsa or Kmail, you can bring fetchmail into the equation. Then create a .fetchmailrc file in your home directory (name it ~/.fetchmailrc to ensure it goes to the right place). Here’s the format of .fetchmailrc:

poll SERVERNAME protocol PROTOCOL username NAME password PASSWORD

So here’s an example that would work for me:

poll mail.swbell.net protocol pop3 username dfarq password censored

Next, set your mail client to no longer check for mail automatically, then type crontab and edit your disspam lines so they read like this:

* 20 * * * disspam.pl disspam.conf >> ~/disspam.log ; fetchmail (your server name)

In case you’re interested, the semicolon tells Unix not to execute the second command until the first one is complete. If you have more than one mail account, add another fetchmail line.

As an aside, Evolution seems to use the mbox file format but it doesn’t store its file where fetchmail will find it. I think you could symlink /var/spool/mail/yourusername to ~/evolution/local/Inbox/mbox and it would work. I haven’t tried that little trick yet.

But even if you’re not ambitious enough to make it run automatically and integrate with all that other stuff, it’s still a killer utility you can run manually. And for that matter, if you can get Perl running on NT or even on a Mac, this ought to run on them as well.

Check it out. It’ll save you time and aggravation. And since it only reads the headers to decide what’s spam and what’s not, it’ll save bandwidth and, ultimately, it’ll save your ISP a little cash. Not tons, but every little bit can help. You can’t expect them to pass their savings on to you, but they’ll certainly pass their increased expenses on to you. So you might as well do a little something to lower those expenses if you can. Sometimes goodwill comes back around.