Fix the PHP error ‘Unable to load dynamic library pdo_mysql.so’

I’m currently using Fedora 16 x86_64 as a dev machine and found that it doesn’t come with an RPM for the PHP MySQL PDO connection. Not a problem, I thought, and installed it via PECL. However, I noticed that it was failing to load up, giving the error:

PHP Warning:  PHP Startup: Unable to load dynamic library ‘/usr/lib64/php/modules/pdo_mysql.so’ – /usr/lib64/php/modules/pdo_mysql.so: undefined symbol: php_pdo_register_driver in Unknown on line 0

Read the rest of this entry »

Migrate Emails Between Servers

So I was migrating a site of mine to a new host, but I had to move a hell of a lot of emails across. The big problem is that I was moving from one setup (a custom one) to a very different one (cPanel’s). To save me from headaches, I needed something that was as agnostic as possible regarding server configuration. Well, thankfully there’s a wonderful Linux tool called imapsync which uses the IMAP protocol to do it all.

Read the rest of this entry »

Change a Timezone in Linux

I recently discovered an old VPS I had forgotten about, and began setting it up. However, I noticed that the VPS was still using the default timezone, EDT. This wouldn’t do (as I am not in the States) so I decided to fix it.

Read the rest of this entry »

Install a Firewall on cPanel

WHM/cPanel is a robust, feature-rich control panel and I love using it. It just doesn’t come with a module for controlling the firewall, which is a pity. One option is to manage it via SSH, but this can get a bit messy because cPanel is designed for full system control. Enter ConfigServer Security and Firewall. Read the rest of this entry »

If There’s One Security Tip I Can Give You…

… It’s to change the default WordPress admin account.

No, seriously.

Read the rest of this entry »

Check if Your CPU Supports Hardware Virtualization

Running unmodified Linux kernels, or operating systems such as Windows, in a virtualized environment (ie, inside a VPS) requires that your CPU handles full hardware virtualization. This affects Xen’s HVM system (Xen is a Linux-based system that was recently made part of the Linux 3 kernel) and VirtualBox (a popular virtualization technology on Windows), so here is how to check if your CPU can support it. Read the rest of this entry »

Install Xen on Centos

Xen is a powerful, popular open-source hypervisor that allows you to run numerous, isolated VPS’s on a single machine. While it sounds complicated to install, it’s actually rather easy.

Read the rest of this entry »

Fix Apache “No space left on device: Couldn’t Create Accept Lock” Issues

On rare occasions, Apache will refuse to start/restart with the following error:

No space left on device: Couldn’t create accept lock

Thankfully, this error isn’t difficult to fix, even if the cause isn’t that obvious, which stumps a lot of people.
Read the rest of this entry »

Fix SSH Logging on Ubuntu OpenVZ Templates

Over time I’ve had several Ubuntu OpenVZ VPS’s, and I normally use the Deny Hosts script to block hackers trying to bruteforce SSH. However, often SSH is set up to log to the wrong place – /var/logauth.log. This bug seems to affect the Ubuntu 8.04 templates the most.
Read the rest of this entry »

Block Attachments in Postfix

Blocking specific email attachments in emails can be handy. Setting this up in Postfix is pretty straightforward and only takes a minute or two to do.
Read the rest of this entry »