« Monkey Business | Main | Shall...We...Play...A...Game? »

Unrehearsed, unplanned, and completely unintentional...

There are a lot of good things about using MovableType but comment spam is not one of them. So I've tried doing the usual stuff like installing MT-Blacklist and the latest MT updates. But to no avail. I've even deleted the comment templates but somehow the span still gets posted.

One of the ways to try to combat this is to close comments after a period of time. Unfortunately, in MT you have to do this manually, post by post. For me, with over 300 posts, this is not an option. So I looked around to see it there was an easier way of doing that. Eventually, I settled on trying to issuing the following SQL command (although there is a add-in module that purports to do this for you it didn't work for me):

update mt_entry set entry_allow_comments = 2 where TO_DAYS(NOW()) - TO_DAYS(entry_created_on) >= 10;(That's one long line of commands.)

The intent was to close all comments older than 10 days. In order to to issue this command, I needed to login to the MySQL command line interface. At pair.com, the host for my site, the instructions to do this is as follows:

username@server% mysql -hdb14.pair.com -uusername -p username_dbname

Enter password: [enter password here]

Note the part about entering a password. That's very important as you will see (he says with great foreboding in the CNN voice...of...doom).

In order to open the database, pair.com wants you do use a password. This seems logical enough because without one, anyone can enter anything they want (like spam). But, since the database did not have a password [see update below], I needed to add one. Pair.com has a handy web interface for doing so. So I did.

The problem is, by setting a password, no one else can read or write to the database. No one. That means when MovableType tries to access the database it can't because it doesn't have permission to do so. Since MT can't write to the database, I can't either (at least not through MT, I could use MySQL directly but that kind of defeats the purpose of having MT in the first place).

All together now...SIGH.

So, this explains why you are reading this in a plain page like I used to use. I emailed pair.com yesterday with an urgent request for help. But as of this morning (afternoon in Pittsburgh where pair is located) I have received no response. So much for their speedy service.

I'm way too busy right now to spend any time on this so this will have to do for now. Sorry.

UPDATE. During my 45-minute lunch break, I was able to re-read the installation instructions for MT. There, I found that a password was in fact used for the database when I installed it. Being that it's been over a year since that occurred, I had no recollection of that nor what the password was (not that it matters since I changed it yesterday when I typed in a new one).

So, the question was how to update MT with the new password. Reading farther into the installation instructions I found the file to edit. You can find it for yourself if you need to but I'm not going to make it easier for l33t hax0rs to change it so I'm not going to mention it here. Suffice to say I set the rights so that only I can read/write to it.

Once that was set, all was well. Although I'm still a little wary about having that file with the password in it...Sigh.

Aloha!

About

This page contains a single entry from the blog posted on February 3, 2004 12:06 PM.

The previous post in this blog was Monkey Business.

The next post in this blog is Shall...We...Play...A...Game?.

Many more can be found on the main index page or by looking through the archives.

Creative Commons License
This weblog is licensed under a Creative Commons License.
Powered by
Movable Type 3.34