I created docker container with mysql using -v option:
Have you tried restarting the
mysql service in your host?
This is something like restoring MYSQL db from physical file.
When you perform db operations inside container, it saves real-data and indexes in
/var/lib/mysql path or the path that you specify while installing.
But, for Host machine, MYSQL service still does not know about the change.
Restart the MYSQL service by
service mysql restart.
Additionally check the owner and permission in the MYSQL data folder like below:
sudo chown -R mysql:mysql /var/lib/mysql sudo chmod -R 660 /var/lib/mysql/ sudo chown -R mysql.mysql /var/log/mysql
While running container, mount
/var/log/mysql as well along with data folder.