b2++ Updates

Regular visitors to this site will have noticed that this blog and others on the server take an inordinate amount of time to display sometimes. Basically, this machine is unfortunately under-powered but we’re working on making the best of use of the available hardware with some changes to MySQL and Apache and to b2++ too. Here’s what I did this morning:

  • Referers are checked and only if requests go to either “/”, “index.php” or “archive/” are they recorded.
  • Referers are now recorded using INSERT DELAYED.
  • I added keys on the post_date and post_category fields in *posts tables. The main SELECT is now a “range” instead of “all” request.

Here’s a short bash script you can use to update your db. Remember to change “username” and “password” to suit your own setup.

for i in `echo show tables | mysql -u username -ppassword b2|grep posts`; do echo "ALTER TABLE \`$i\` ADD INDEX ( \`post_category\` )"| mysql -u username -ppassword b2; echo "ALTER TABLE \`$i\` ADD INDEX ( \`post_date\` )"| mysql -u username -ppassword b2; done

Useful links: Mysql Optimization | Optimizing MySQL: Hardware and the Mysqld Variables (mentioned previously) | MySQL Optimisation and a few other pages.

Legal, schmegal – Photography rights challenged, again!

I thought this was going to be a slightly alarmist story about the heavy handed nature of the law when I read “riot act” but it turned out well enough in the end.
Almost on topic, I remember taking a photo of a dramatic painting in the Louvre years ago. I thought I had disabled the flash, but no, I hadn’t and bright white light poured into the room when I pressed the shutter button!
No sooner had I realised my mistake than an irate lady came pounding up to me gesticulating wildly and berating me, in French, for destroying a work of art! Unfortunately, my French was only slightly better than it is now (and that extends to about a dozen words!) but I didn’t need a gift with languages to realise what she was saying! *gulp*
I still have that photo at home somewhere..

These web sites are identical, or are they?

Oh yeah! Nice survey! It compares the websites of ten web designers and notes the similarities and differences between them. Lookee here, they’re almost all the same!

What is hence noteworthy is that all these designs resemble themselves very much. They use a panel of common element, and then place them at identical locations on their pages. Hence, the difference between one web site and another is then merely colors and pictures.

Preparing For Emergencies

hehe. Thanks Donal for the link to preparingforemergencies.co.uk which is a parody of preparingforemergencies.gov.uk
Surely the British Government isn’t scare mongering? Bertie tried that last year, but even he’s given up on it!

In an effort to worry the public and convince them to vote for us again next year, and because George Bush asked us to, this website includes…
We are also launching a national advertising campaign letting you know to look out for the booklet coming through your letterboxes during August. In no way does this resemble the Reader’s Digest Prize Draw.