Hi,
i have problem with my mysql after factory reset in docker. Mysql in now broken.
I don’t have any tables in phpmyadmin, and a lot of errors when im trying add user, or add table.
Im not a pro in docker things, but it was working well.
Im working on BEng Thesis and its really sad :(((
docker-compose -up
Docker-compose.yml
version: ‘2’
services:
db:
image: mysql:8
ports:
- 3306:3306
volumes:
- …/tut2/.data/db:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: symfony
MYSQL_USER: root
MYSQL_PASSWORD: symfony
phpmyadmin:
image: phpmyadmin/phpmyadmin
links:
- db:mysqldb
depends_on:
- db
ports:
- 8080:80
php:
image: carriera/sf3_php7-fpm
ports:
- 8000:8000
command: "bin/console server:run 0.0.0.0"
links:
- db:mysqldb
volumes:
- ../tut2/:/var/www/symfony
- ../logs/tut2:/var/www/symfony/app/logs
networks:
mynet2:
ipv4_address: 172.24.1.4
networks:
mynet2:
driver: bridge
ipam:
config:
- subnet: 172.24.1.0/24
Errors:
After login on phpmyadmin i dont see any tables and got error:
#1449 - The user specified as a definer (‘mysql.infoschema’@‘localhost’) does not exist - main error
After trying add user
#1064 - Something is wrong in your syntax obok ‘) ORDER BY User
ASC, Host
ASC’ w linii 1
I posted this at mysql image github and found a solution but it dont working for me:
docker run -it a8a59477268d bash -c mysql_upgrade -uroot -proot
But got error: mysql_upgrade: Got error: 2002: Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (2) while connecting to the MySQL server
Upgrade process encountered error and will not continue.