Database remote connection MySQL

1

From december 11th 2018 (For HA offers, see old method at bottom)

 

Use your dedicated IP for your host, example : 54.36.2.33, or even hostname of your hosting service, ie : web3.hosting1976.fr

Port of database server is 3562

Now allow your connecting IP to connect to database server in your cPanel in section 'Remote Mysql' (computer IP or remote website IP). You can use % to allow all IPs, our firewall will still detect database failures connections and block offending IPs.

(In examples hereafter, You can also connect with any other software with same credentials)

 

A : To get access to all databases from your cPanel account remotely :

Consider for example your user cpanel is : user19

Password : SALU456ji

For example, with putty :

mysql -h 54.36.2.33 -P 3562 -u user19 -p

enter password as requested : SALU456ji

(You can also connect with any other software with same credentials)

 

B : To get access to to only 1 database directly

Consider for example your database name is : host76_sting

Database user : host_user1

Password : 8SnQ82B

For example, with putty :

mysql -h 54.36.2.33 -P 3562 -D host76_sting -u host_user1 -p

enter password as requested : 8SnQ82B

NB : in local mode, the host (address database server) to use is localhost, not 127.0.0.1

 

Old method (still valid with but with port 3562)

To log on, it will be by tunnel SSH, regardless of the software you must use your cPanel login and password with the 4231 port to connect to the server in the first place.
In your cpanel, allow IP :  127.0.0.1 , in section "MySQL remote".


Ask us so that we enable your SSH access :
https://support.yoorshop.hosting/knowledgebase/1288/SSH-access-by-key-with-putty.html

An example with Heidi SQL indirectly using Putty. The principle is the same for other software.
The user cPanel is used as an example here : hostingone + password of your cpanel account :


Réglages logiciel connexion distante SQL 1



For host value, You must use existing IP that you have seen in cpanel, in sql remote section, or main shared IP address, or your dedicated IP :

Réglages logiciel connexion distante SQL 2

 

Connection result sql