SQLSTATE[HY000] [2002] Connection refused

Website URL

https://bnan.wuaze.com/phpMyAdmin/index.php?route=/

Error Message

mysqli::real_connect(): (HY000/2002): Connection refused

Other Information

phpMyAdmin config setting
$cfg[‘Servers’][$i][‘auth_type’] = ‘config’;

/* Server parameters */

$cfg[‘Servers’][$i][‘compress’] = false;

$cfg[‘Servers’][$i][‘AllowNoPassword’] = false;

$cfg[‘Servers’][$i][‘host’] = ‘mysql-9319768-csskin.g.aivencloud.com’;

$cfg[‘Servers’][$i][‘port’] = ‘12678’;

$cfg[‘Servers’][$i][‘user’] = ‘avnadmin’;

$cfg[‘Servers’][$i][‘password’] = ‘******************’;

$cfg[‘Servers’][$i][‘extension’] = ‘mysqli’;

I can access this database locally and confirm that MySQL is working properly. I’ve been running it on InfinityFree for several months without issues, but recently, I’ve been getting a ‘Connection refused’ error.

I’m surprised it worked before. Access to custom remote ports, such as port 12678, should be blocked on our hosting. Connecting to external MySQL servers is fine, assuming they are running on the regular MySQL port 3306.

6 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.