I accidentally overwrote
/app/etc/local.xml with a version from another host. No live shop affected, luckily, but I can't get the shop to connect to the database anymore. It keeps saying:
There has been an error processing your request
SQLSTATE[HY000]  Access denied for user 'wronguser'@'localhost' (using password: YES)
I've restored the correct local.xml, with the correct database settings. I cleared var/cache and var/sessions.
n98-magerun db:console I can access the database, but it's impossible to run
n98-magerun cache:clean or any other database related command.
Removing any other .xml files from /app/etc/ didn't resolve the issue either.
grep -R wronguser * didn't even find the wrong database connection in the entire document root. I have no idea where Magento gets this information from.