Weird from nothing my php does not connect with my mysql, phpMyAdmin normally works.
I ran a sudo /etc/init.d/mysql status
and everything is ok.
My php looks like this:
$ip_bd_mysql_master = '127.0.0.1';
$login_bd_mysql_master = 'root';
$senha_bd_mysql_master = '123456';
// Conexão
$mysqli = mysqli_connect($ip_bd_mysql_master, $login_bd_mysql_master, $senha_bd_mysql_master, 'teste');
The error I have is this:
Warning: mysqli_connect(): (HY000/2002): Connection refused in /var/www/html/bd.php on line 6
Does anyone know what it can be?
The version of my php is PHP 7.2.13-1 + ubuntu18.04.1 + deb.sury.org + 1 (cli) (built: Dec 7 2018 08:07:36) (NTS)