Reset root or admin password of mediawiki

From Notes_Wiki

Home > CentOS > CentOS 6.x > Web based tools or applications > Mediawiki configuration > Reset root or admin password of mediawiki

To reset root or admin password of wiki use following steps:

  1. Comment all $wgAuth settings in LocalSettings.php so that wiki only uses local authentication.
  2. Connect to wiki database by looking at database configuration in LocalSettings.php
  3. Look at user_groups table and find user_id of user who is member of bureaucrat and sysop. Look at username of the user with this id in user table.
  4. Use:
    php maintenance/changePassword.php --user=<username> --password=<new_password>
    where <new_password> must be at least 8 characters long, eg, admin123.
  5. Again uncomment $wgAuth lines in LocalSettings.php. Note that for local login select "Your domain" as local


Debugging login issues

  1. For debugging add:
    $wgShowExceptionDetails = True;
    at end of LocalSetting.php file to get more details


Home > CentOS > CentOS 6.x > Web based tools or applications > Mediawiki configuration > Reset root or admin password of mediawiki