reset wordpress admin password using phpMyAdmin

First, log into phpMyAdmin and select the database associated with your WordPress installation. You can find it from the wp-config.php file. Once in your database, select the wp_users table.

Once the table is loaded, look for the username you had chosen while installing WordPress. Assuming the user name is admin in this scenario. Click on the edit icon, the little yellow pencil icon located next to the admin entry.

Look for the row named user_pass and make the following changes:

Change the Function field to MD5. Under the Value field, enter your new password and click on Save Changes.

Now you have successfully changed your WordPress password and reset the WordPress admin password. 🙂

FastInclude: Userdirname: (null) error after recompiling php and apache

I encountered the following error after recompiling using easyapache in cPanel server.

These were the errors that appeared in apache logs:

[notice] FastInclude: Userdirname: (null)
[Tue Jan 28 02:39:00 2013] [notice] FastInclude: Userdirname: (null)
[Tue Jan 28 02:39:00 2013] [notice] FastInclude: Userdirname: (null)
[Tue Jan 28 02:39:01 2013] [notice] FastInclude: Userdirname: (null)

The fix I was able to find was to remove the attracta plugin installed in the cPanel server.

Spamd / Spamassassin error : argument isn’t numeric in addition / unparseable IPv6 address

I encountered the following error while restarting spamassassin.

Starting spamd: Feb 21 20:29:26.275 [8814] warn: Argument “” isn’t numeric in addition (+) at /usr/local/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/ line 122.
Feb 21 20:29:26.276 [8814] warn: oops! unparseable IPv6 address for 127/8: 168355856 at /usr/local/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/ line 128.
Feb 21 20:29:26.276 [8814] warn: oops! unparseable IPv6 address for 127/8: 168356228 at /usr/local/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/ line 128.
child process [8816] exited or timed out without signaling production of a PID file: exit 255 at /usr/bin/spamd line 2582.

The work around I found is to change cpanel to stable version and run upcp.

then do this,

sa-learn -D –force-expire
sa-update -D

This should fix the issue.

How To Find Large Files and Directories in Unix

Sometimes we need to find larger files in a file system when theres is a disk space issue.

This example finds all the files under /etc directory which are larger than 1000k:

geobaby@ubuntu:~$ find /etc -size +1000k

If you look at the file, the size if above 1000k:

geobaby@ubuntu:~$ ls -l /etc/brltty/zh-tw.ctb
-rw-r–r– 1 root root 1368836 2010-08-12 05:20 /etc/brltty/zh-tw.ctb

The following example will be helpful in cPanel or web servers.

find / -size +1000M : will list all the files above 1GB size.

find / -size +1000M > list

for i in `cat list`; do du -sch $i;done : will list all the files and their resoective size.

how to remove an IP from the cphulkd blacklist

cPHulk Brute Force Protection prevents malicious forces from trying to access your server’s services by guessing the login password for that

By the following steps you can remove the IP from the cphulkd blacklist. Issue the commands from mysql prompt.

mysql> use cphulkd;

mysql> select * from brutes;
| | 5 login failures attempts to account (ftp) | 2011-01-07 14:54:02 | 2011-01-07 14:59:02 |
1 row in set (0.00 sec)

mysql> delete from brutes where IP=’′;
Query OK, 1 row affected (0.00 sec)


You are done.

Install APC in cPanel server

You can install APC (Alternative PHP Cache) in your cpanel server using the following steps:

# pecl install apc

Then add the extension in the php.ini file.

You can get the php.ini file by

# php –ini

Add the following line to it.


Then, retart apache service and you are good to go.

I encountered the following error while installation.

“checking whether the C compiler works… configure: error: cannot run C compiled programs.”

I made it working by the following:

# mount -o remount,exec,suid /tmp

Complete the installation and don’t forget to remount the tmp directory with noexec, nosuid options after the installation.

cPanel upcp error : Undefined subroutine

I have seen recent cPanel upgrade throwing errors shown below:

root@server [~]# /scripts/upcp
/scripts/upcp syntax OK
Running Futex Check/Fix……Done
Undefined subroutine &Cpanel::Update::automatic_updates_enabled called at /scripts/upcp line 273.

This can be fixed using below steps.

wget -O /root/updatenow.static…datenow.static && perl /root/updatenow.static –manual

Now you will be able to upgrade the cPanel using upcp script.

/scripts/upcp –force

It worked for me.

Change MySQL database collation

You can change database collation from the WHM/cPanel.

1. Enter your WHM/cPanel and select phpMyAdmin.

2. Select the database you wish to manage.

3. Click on the Operations tab in the top menu of your phpMyAdmin

4.  At the bottom of the page you will see the collation option. Select a collation from the drop down menu and click on the Go button.

You are all set.

Reset Joomla admin password

Joomla admin password is stored in mysql, so it can be changed easily by running a simple mysql query.

If you have a cPanel account, use the phpMyAdmin to reset the password. Select the Joomla database and run the following query.

UPDATE `jos_users` SET `password` = MD5(‘newpass‘) WHERE `jos_users`.`username` = “admin” ;

“newpass” – replace this with the new password you wish to use.
“admin” – replace this with your username.

and submit the query.Now you should be able to login to Joomla admin page with the new password.