DROP DATABASE `wordpress`;
CREATE DATABASE `wordpress` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
CREATE USER 'xxxuser'@'localhost' IDENTIFIED BY 'xxx123';
GRANT USAGE ON * . * TO 'xxxuser'@'localhost' IDENTIFIED BY 'xxx123' WITH MAX_QUERIES_PER_HOUR 0 MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0 ;
GRANT ALL PRIVILEGES ON `wordpress` . * TO 'xxxuser'@'localhost' WITH GRANT OPTION ;
flush privileges;
转载于:https://my.oschina.net/u/2537743/blog/787774