Error When I add new WordPress site "Setting up database Oops Something went wrong ! Calling cleanup actions ... 'ee_mysql_grant_host' "


#1
sudo ee site create vndoc.vn --wpfc --pagespeed PageSpeed is experimental feature and it may not work with all CSS/JS/Cache of your site.
You can disable it by passing --pagespeed=off later.
Do you wish to enable PageSpeed now for vndoc.vn?
Type "y" to continue [n]:y
Running pre-update checks, please wait...
Setting up NGINX configuration [Done]
Setting up webroot [Done]
Downloading Wordpress [Done]
Setting up database Oops Something went wrong !!
Calling cleanup actions ...
'ee_mysql_grant_host'

Please help me!!!


#2

Please check your mysql connection using command

mysql


#3
sudo mysql
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)

#5
cloud-user@cuongabc:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 8.1 (jessie)
Release:        8.1
Codename:       jessie
cloud-user@cuongabc:~$ ee -v

Only root or sudo user can run this EasyEngine

cloud-user@cuongabc:~$ sudo ee -v
EasyEngine v3.5.4
Copyright (c) 2015 rtCamp Solutions Pvt. Ltd.
cloud-user@cuongabc:~$ sudo ee info

NGINX (1.8.0):

user                             www-data
worker_processes                 auto
worker_connections               4096
keepalive_timeout                30
fastcgi_read_timeout             300
client_max_body_size             100m
allow                            127.0.0.1

PHP (5.6.14-0):

user
expose_php                       Off
memory_limit                     128M
post_max_size                    100M
upload_max_filesize              100M
max_execution_time               300

Information about www.conf
ping.path                        /ping
pm.status_path                   /status
process_manager                  ondemand
pm.max_requests                  500
pm.max_children                  100
pm.start_servers                 20
pm.min_spare_servers             10
pm.max_spare_servers             30
request_terminate_timeout        300
xdebug.profiler_enable_trigger   off
listen                           127.0.0.1:9000

Information about debug.conf
ping.path                        /ping
pm.status_path                   /status
process_manager                  ondemand
pm.max_requests                  500
pm.max_children                  100
pm.start_servers                 20
pm.min_spare_servers             10
pm.max_spare_servers             30
request_terminate_timeout        300
xdebug.profiler_enable_trigger   on
listen                           127.0.0.1:9001
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: Y                      ES)

MySQL (10.1.9-MariaDB) on localhost:

port
wait_timeout
interactive_timeout
max_used_connections
datadir
socket
my.cnf [PATH]                    /etc/mysql/conf.d/my.cnf
cloud-user@cuongabc:~$ wp --allow-root --info
PHP binary:     /usr/bin/php5
PHP version:    5.6.14-0+deb8u1
php.ini used:   /etc/php5/cli/php.ini
WP-CLI root dir:        phar://wp-cli.phar
WP-CLI global config:
WP-CLI project config:
WP-CLI version: 0.22.0
cloud-user@cuongabc:~$

#6

What are the results of the following commands?

file /root/.my.cnf
file /etc/mysql/my.cnf

#7

Having similar issues and saw this ticket wasn’t closed yet.

I have 2 recent VPS running ee 3.6.2 both worked a few weeks ago but now one is having this same error “ee_mysql_grant_host” when creating sites.

I’ve verified the contents of /etc/ee/ee.conf set to localhost (default) as well as the root pwd in /etc/mysql/conf.d/my.cnf but can’t login manually either.

I only disabled the service to reduce load because I am using an off-hosted mysql service but I enable it to run the ee site install script and then shut it back down. To my knowlegde ee doesn’t provide a wp site install w/out the db part but also if the sb part isn;t working the rest of the script may not complete. I know I can manually copy files but still prefer to use ee even my db is off-server but without remote admin access.

Checked those 2 files, first doesn’t exist other is default with no mods.


#8

Had to force root password back to what was in my.conf not sure how it ever changed though. https://support.rackspace.com/how-to/mysql-resetting-a-lost-mysql-root-password/


#9