There was a problem deploying Django project on the server (running under Windows no problem at all)
specific problems for the implementation of python3 manage.py makemigrations
the event, the
specific code section:
'ENGINE': 'django.db.backends.mysql',
'NAME': "blog",
'USER': 'root',
'PASSWORD': '密码',
'HOST': '127.0.0.1',
'PORT': '3306',
I did not find the specific reason ( 猜测跟’USER’: 'root’有关
), but found a solution, in particular in the mysql database to create a user and authorize it to him, to root
change to the newly created user.
Specific operation is as follows:
create user '用户名'@'%' identified by '密码'; # 创建用户
grant all on *.* to '用户名'@'%'; # 授权
flush privileges; # 刷新权限