Thanks Kevin Lawry,
Fortunately since I still have ftp access I know my mysql database passwords/username.
So I did as you say and got back into my Moodle! Thank you thank you!
This is how to get into your moodle if you lose or forget your password but still have ftp access to your server.
1) Copy the following information in your config.php in your moodle director.
//$CFG->dbhost = 'very_private'; // eg localhost or db.isp.com
//$CFG->dbname = 'very_private'; // database name, eg moodle
//$CFG->dbuser = 'very_private'; // your database username
//$CFG->dbpass = 'very_private'; // your database password
2) Uploaded mysql admin in the base directory of my server (away from Moodle's login control) mysql admin is available here
http://prdownloads.sourceforge.net/moodle/moodle-1.2-mysql-admin.zip
3) replaced the config.inc.php with the config.inc.php from
http://cvs.sourceforge.net/viewcvs.py/phpmyadmin/phpMyAdmin/config.inc.php
(I could have downloaded a complete phpmyadmin from http://phpmyadmin.net
, but the only difference seems to be the config file which, in the moodle release references the database information in moodle's config.php, of course, and I had already downloaded a copy of the moodle version of phpmyadmin.)
4) Type in the host, user, database, password as per the instructions at phpmyadmin, using the information from the moodle config.php. This is near the top of config.inc.php. Change the areas marked very_private.
$cfg['Servers'][$i]['host'] = 'very_private'; // MySQL hostname or IP address
$cfg['Servers'][$i]['port'] = ''; // MySQL port - leave blank for default port
$cfg['Servers'][$i]['socket'] = ''; // Path to the socket - leave blank for default socket
$cfg['Servers'][$i]['connect_type'] = 'tcp'; // How to connect to MySQL server ('tcp' or 'socket')
$cfg['Servers'][$i]['extension'] = 'mysql'; // The php MySQL extension to use ('mysql' or 'mysqli')
$cfg['Servers'][$i]['compress'] = FALSE; // Use compressed protocol for the MySQL connection
// (requires PHP >= 4.3.0)
$cfg['Servers'][$i]['controluser'] = ''; // MySQL control user settings
// (this user must have read-only
$cfg['Servers'][$i]['controlpass'] = ''; // access to the "mysql/user"
// and "mysql/db" tables).
// The controluser is also
// used for all relational
// features (pmadb)
$cfg['Servers'][$i]['auth_type'] = 'config'; // Authentication method (config, http or cookie based)?
$cfg['Servers'][$i]['user'] = 'very_private'; // MySQL user
$cfg['Servers'][$i]['password'] = 'very_private'; // MySQL password (only needed
// with 'config' auth_type)
$cfg['Servers'][$i]['only_db'] = very_private'; // If set to a db-name, only
// this db is displayed in left frame
5) Go to
http://yourdomain/mysql/
(the instructions at phpmyadmin.net say go to http://yourdomain/mysql/index.php but that did not work for me. Perhaps this is something else that has changed in the Moodle-ized version of phpmyadmin )
6) I go to the users table entry (not to the users_admin screen) and there you will see the users and their encoded passwords.
7) Copy the guest password to the admin password. I am pretty sure that the guest password is "guest". (Fortunately I had created another test student password that I remember so I copied that instead.)
8) Log into your moodle with the guest password.
9) Change your password.
10) Delete myphpadmin or at least password protect its folder.
Thanks again,
Tim
Takemoto