The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

remote mysql for one IP

Discussion in 'Database Discussions' started by Bashed, Jun 18, 2015.

  1. Bashed

    Bashed Well-Known Member

    Joined:
    Dec 18, 2013
    Messages:
    78
    Likes Received:
    1
    Trophy Points:
    8
    cPanel Access Level:
    Root Administrator
    Can't get remote mysql working for single ip on port 3306.

    Port 3306 is not enabled globally for security reasons in TCP / UDP fields of CSF

    In CSF allow I added this

    tcp|in|d=3306|s=3306=xx-client-IP-xx
    tcp|out|d=3306|s=3306=xx-client-IP-xx

    I also even tried changing the 2nd "out" line to the server's local IP for mysql as suggested by Chirp in a cPanel forum post.

    Also, skip networking is not in the my.cnf file. Not sure what else to do to get this client to be able to access remotely to this server on 3306.
     
  2. 24x7ss

    24x7ss Well-Known Member

    Joined:
    Sep 30, 2014
    Messages:
    271
    Likes Received:
    16
    Trophy Points:
    18
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Twitter:
    To provide remote mysql access you have to add client local machine IP in remote mysql setting in cpanel.

    cpanel Home >> Databases >> Remote MySQL

    You can add complete IP of client and 1st 3 octal of IP with %.

    For example :
    x.x.x.x
    x.x.x.%

     
  3. Bashed

    Bashed Well-Known Member

    Joined:
    Dec 18, 2013
    Messages:
    78
    Likes Received:
    1
    Trophy Points:
    8
    cPanel Access Level:
    Root Administrator
    Right, I'm familiar with that and it's been done already.

    got it working by whitelisting his IP globally in CSF.

    However, trying to get his 3 external hosting accounts working remotely to connect from 3 other hosts to my local mysql server. He whitelisted his domain's IP with my server on the 3 other hosts' cpanel > remote mysql section already.

    I've added the 3 host IPs to CSF allow, but still not working


    Code:
    tcp|in|d=3306|s=3306=123.123.123.123
    tcp|out|d=3306|s=3306=123.123.123.123
     
  4. LostNerd

    LostNerd Well-Known Member

    Joined:
    Mar 12, 2014
    Messages:
    258
    Likes Received:
    11
    Trophy Points:
    18
    Location:
    Hastings, East Sussex, UK
    cPanel Access Level:
    Root Administrator
    Twitter:
    Have you opened the port in the lfd config? The setting is under IPv4 Settings and is called TCP_IN.
     
  5. 24x7ss

    24x7ss Well-Known Member

    Joined:
    Sep 30, 2014
    Messages:
    271
    Likes Received:
    16
    Trophy Points:
    18
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Twitter:
    You might need to ask them to add your Server's IP address in whitelist of their firewall for uninterrupted connection.
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    652
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Could you provide an example or diagram of this to better explain how the remote MySQL connection is occurring? I want to be sure I fully understand how this is configured.

    Thank you.
     
Loading...

Share This Page