Via the webconsole, click: Event, then read all the events, while taking note of them and actioning them as required.
Finally click: Clear All Events
<?php $everything = get_defined_vars(); ksort($everything); echo '<pre>'; print_r($everything); echo '</pre>'; ?>
Well actually it’s not in the foreground but to a log file, but if you tail / follow the logfile you could pretend it was the foreground :-)
mysqld_safe --log-error=/var/log/mysql.err
And perhaps you have imported a database for forensic investigation and you don’t know the database password, you can just skip the authentication:
mysqld_safe --skip-grant-tables --log-error=/var/log/mysql.err