dapurhosting.com Blog for Tech

December 13, 2011

Disable WordPress Spam Comment

Filed under: CMS — Tags: , — dh @ 5:15 am

UPDATE `wp_posts` SET `comment_status` = 'closed', `ping_status` = 'closed';
UPDATE `wp_options` SET `option_value` = 'closed' WHERE `option_name` = 'default_comment_status';
UPDATE `wp_options` SET `option_value` = 'closed' WHERE `option_name` = 'default_ping_status';
UPDATE `wp_options` SET `option_value` = '0' WHERE `option_name` = 'users_can_register';

RENAME TABLE wp_comments To wp_comments_spam;

December 12, 2011

How to Kill Zombie

Filed under: Server — dh @ 6:24 am

List all zombie

ps aux | awk '{ print $8 " " $2 }' | grep -w Z

Output:
Z 4104
Z 5320
Z 2945

Kill:
kill -9 4104

Or:
if the PID = 1 (no parent)
wait 3038 &

Powered by WordPress