How to allow mariadb remote connect hestiacp

I want to connect a database. from another server

how I can setup properly?

Just add a firewall rule allowing port 3306 from your other server, I suggest to limit it for his ip address and do not allow the connection from anywhere. Also validate the bind-address setting, see posts below.

this way

/sbin/iptables -A INPUT -i eth0 -s -p tcp --destination-port 3306 -j ACCEPT

Or From HestiaCP

From hestia cp, checkout the firewall rules part.

I have this same problem. I installed Wordpress via Hestiacp and want to access my database remotely to display my blog posts within my custom app. I tried the solutions suggested here - opening ports both via Hestiacp and command line but still keep getting connection refused when using HeidiSQL or DBeaver to connect remotely. Do I need to do any more configuration to get this to work?

The question is if mariadb/mysql server answers requests from any ip, checkout this - I suggest the “manual steps”: How to enable Remote access to your MariaDB/MySQL database

1 Like

Thanks for the suggestion. I’ve checked the link and followed the instructions but there is no ‘bind-address’ in the configuration file mentioned. When I add this line, it still shows as listening on from netstat (tried restarting mariadb and rebooting). Do you know how to solve this?


1 Like

That’s what I added, it didn’t work

Ok I’m using Ubuntu 16.04, I found a solution: I needed to change the bind-address in


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