Unanswered: create script from old install of mysql
I have a linux server running mysql. recently a friend updated the version of mysql. In phpMyAdmin, the old db's aren't showing up. I believe they are still there but I need to fetch them in the form of a script that I can use later. I skimmed through the info on using 'mysql' from my terminal window. It is running so when I type mysql it starts to listen and assigns me an ID. I need a few things:
1. How can I fetch a list of all of the dbs?
2. How can I create a script file of each db with its structure and records?
3. Once this is complete, where should I look for the script file?