Monday, November 30, 2009

Password reset for Mediawiki

The easiest way to avoid this problem is to set an e-mail address in your account, so you can use the “Mail me a new password” feature. However, if you find that you’ve forgotten the password to an account on your wiki, and you don’t have an e-mail address set for it, you can reset its password as follows:

  1. Log in to phpMyAdmin with your SQL password.
  2. From the menu on the left, select the database corresponding to your wiki, and select the “user” table within it.
  3. Click “Browse” at the top, and note down the user ID for the account whose password you want to reset. (This will be 1 for the first account.)
  4. Click “SQL” at the top, and run the following command, replacing “uid” with the user ID and “newpassword” with the new password for the account:
    • UPDATE user SET user_password = MD5(CONCAT(user_id, ‘-’, MD5(’newpassword‘))) WHERE user_id = uid

Mediawiki Upgrade

After a mediawiki upgrade, it is recommended to run the update script.

cd /var/lib/mediawiki/maintenance
php update.php

This will clean up the database.

More about Mediawiki Maintenance Scripts - http://www.mediawiki.org/wiki/Category:Maintenance_scripts

Monday, November 2, 2009

FTP Commands

In order to have the number of bytes transferred printed when using FTP, use the 'TICK' command