This is a pretty easy one, it’s useful if a client has gone over their allocated disk space. Occasionally even if they delete everything Plesk still thinks they are over until the nightly cron jobs are re-run.
This command just forces the job to re-run on a single domain:
/usr/local/psa/admin/sbin/statistics –calculate-one –domain-name=Domain_name.com
Monthly Archives: November 2008
Recalculate disk space for a single domain in Plesk
Preventing SQL Injection
For anyone who needs it, here is a script I wrote to prevent SQL injection. It uses references to the original global arrays to clean them up.
/**
* added the following code to enabled readyness for magic_quotes() being removed
* in PHP6
*
* added by C. Cook 15/8/2008
*/
//Turn off magic quotes the manual way, this also [...]
Simple Tip To Reduce Brute Force Hacks Via SSH
This is very simple, but I’ve seen a massive reduction in brute force attempts simply by changing the default port for SSH connections.
It’s pretty simple to change the default port:
Just edit the SSH configuration file, normally this will be found in /etc/ssh or /usr/local/etc/ssh.
To change it over, edit the line that reads “Port 22″ or [...]
On The Hunt For a Hacker - Part One
One of my clients has recently been hacked, and not knowing who else to turn to asked me to look into the hack, try and sort out the mess and fix the broken websites.
So before I start this post I think I should make it clear that I am supporting my clients legacy code, which [...]