Not dumping INFORMATION_SCHEMA if you use a version of mysqldump which dumps it if you use the -A or –all-databases option, means you’ll need to use the -B or –databases option and provide a list of databases to be dumped.
Use the –force option when importing it.Remove it from the dump before importing it.Or you use MySQL 5.5 or newer and actually went out of your way to dump INFORMATION_SCHEMA by naming it explicitly using the –skip-lock-tables option.Īnyway, there three solutions for this problem: Im pulling my hair out trying to decipher why every time I do a fresh install of mysql on OSX and import a database, the minute I restart the mysql instance Im prompted with the message: Access denied for user rootlocalhost (using password: YES). If you used mysqldump to dump all the databases, you are either using an old version (like 4.1) and should switch to a more current version of mysqldump. So you shouldn’t have been dumping it in the first place. Since it only contains data about the other databases on the server, you shouldn’t actually be importing it. The tables in this schema are actually views not real tables and there is no database directory with that name.
INFORMATION_SCHEMA is a virtual database where information about all the other databases that the MySQL server maintains are stored.
When trying to import a MySQL database, it might stop with following error and fail to load all the dumped database: Access denied for user to database 'information_schema'