[英]How to give a mysql user permission to create and delete database on ubuntu
i recently migrated to aws from shared hosting, as i was using php application i chose to use mysql as db.我最近从共享主机迁移到 aws,因为我正在使用 php 应用程序,我选择使用 mysql 作为数据库。
However i was hosting 3 web applications on 1 ec2 instance, i had to create 3 DB's and 3 User's giving them appropriate fill privilege to their respective DB.但是,我在 1 个 ec2 实例上托管 3 个 web 应用程序,我必须创建 3 个 DB 和 3 个用户,为他们各自的 DB 提供适当的填充权限。
However now the problem is when they login to phpmyadmin they cannot create a database it says #1044 - Access denied for user 'user'@'localhost' to database 'user_test'
但是现在的问题是,当他们登录到 phpmyadmin 时,他们无法创建一个数据库,上面写着#1044 - Access denied for user 'user'@'localhost' to database 'user_test'
How should i overcome this?我应该如何克服这个?
First of all, login:首先,登录:
sudo mysql -u root
then just write:然后写:
GRANT ALL PRIVILEGES ON *.* TO 'user'@'localhost';
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.