Ispconfig 3.2 mysql refuse IP address with remote access

Discussion in 'Installation/Configuration' started by francoisPE, Oct 30, 2020.

  1. francoisPE

    francoisPE Active Member HowtoForge Supporter

    Hi,
    I have ispconfig 3.2 + ubuntu 18.04.
    2 servers : one with mariadb+web+dns+mail, the other web+dns
    I am installing nextcloud on second one. I need remote access to Mariadb on 1st one.
    Doing it, I face below message (Rem : on picture removed but IP address is xxx.xx.xx.xxx)
    So I try workaround. I create a user with remote access without specifying host ('%' in phpmyadmin)
    But it doesn't work : access refused during nextcloud installation
    I already check firewall : 3306 port is open.
    Third workaround. I create a user in phpmyadmin. it works : i can install nextcloud.
    But... with ISPc would be better !
     

    Attached Files:

  2. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    If this is a multiserver setup, you actually should have database on both servers.
     
  3. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    There is a clear error in the picture that the IP you entered is a incorrect IP address. Double check what value you have for the remote IP.
     
  4. francoisPE

    francoisPE Active Member HowtoForge Supporter

    @ahrasis : you are true, I have mariadb on both server
    @Th0m : i double check. My IP is 3digit.2digit.2digit.3digit
    I don't see where is the wrong IP...
     
  5. francoisPE

    francoisPE Active Member HowtoForge Supporter

    I test it in my browser, it goes to my 2nd server...
     
  6. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Maybe you accidently added a space or special symbol to it? I can add IP addresses just fine here.
     
  7. francoisPE

    francoisPE Active Member HowtoForge Supporter

    when I put my IP, it automatically add localhost IP 127.0.1.1.
    is that normal ?
     
  8. francoisPE

    francoisPE Active Member HowtoForge Supporter

    may be I can show you direct live ?
     
  9. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    Do you have your server's hostname as 127.0.1.1 in /etc/hosts?

    FWIW, I also tried setting a test db to various ip addresses, with no issues.
     
  10. francoisPE

    francoisPE Active Member HowtoForge Supporter

    /etc/hosts
    on
    serv1
    #
    127.0.1.1 fpe1.domain.tld fpe1
    127.0.0.1 localhost localhost.localdomain
    xxx.xxx.xxx.xx fpe1.domain.tld fpe1
    yyy.yy.yy.yyy fpe2.domain.tld fpe2

    # The following lines are desirable for IPv6 capable hosts
    ::1 ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    ff02::3 ip6-allhosts

    on serv2
    #
    127.0.1.1 fpe2.domain.tld fpe2
    127.0.0.1 localhost localhost.localdomain
    xxx.xxx.xxx.xx fpe1.domain.tld fpe1
    yyy.yy.yy.yyy fpe2.domain.tld fpe2

    # The following lines are desirable for IPv6 capable hosts
    ::1 ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    ff02::3 ip6-allhosts

    nothing wrong ?
    I will try update ispc... May be a wrong conf somewhere
     
  11. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    This is wrong:
    Code:
    127.0.1.1 fpe1.domain.tld fpe1
    At least if fpe1 is the hostname of this host. You should not add it with 127.0.0.1 IP address to hosts file.
     
  12. francoisPE

    francoisPE Active Member HowtoForge Supporter

    What should I write
    '
    127.0.1.1 localhost
    '
    instead ?
     
  13. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Do you need that loopback address for something? If you need it, then write it. If you do not need it, leave it out.
     
  14. francoisPE

    francoisPE Active Member HowtoForge Supporter

    I thought it was needed for ispc.
    I remove
    Thank you :)
     
  15. francoisPE

    francoisPE Active Member HowtoForge Supporter

    I finalise tests.
    I confirm "127.0.1.1 fpe1.domain.tld fpe1" in hosts file, was my mistake.
    It works now.
    thank you very much for your help.
    For your info, that line was coming from my provider. It was initialy in hosts file.
     
    ahrasis likes this.
  16. francoisPE

    francoisPE Active Member HowtoForge Supporter

    I reopen that topic to clarify what was the issue finally :
    - I try to create with ISP a database on server 1 (server 1 is where I have isp + mariaDB + phpnyadmin...) to be used by a web site on server 2 with remote access (IP server 2). In fact this is impossible. It says "IP issue"
    - I can have a db on server 2, for web site on server 2 with remote access serv1 (remote not really usefull at that stage)
    Do you confirm ? I can't have all db on same server with remote access from others ?
     
  17. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Sure you can. The ISPConfig Manual even shows a system setup where database server is a separate host.
     
    ahrasis likes this.
  18. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    1. You already understand that each ISPConfig server already have database on each server.
    2. What you also need to understand is that can be used as database for that server alone or it can be used as database for that server and other server i.e. as database server.
    3. As such you can use server1 as database server where server2 can access to it remotely with server2 still need its own server database or vice versa.
    4. It is arguably easier to have web server and its database server together rather than separately, as you suggested.
    5. But may not be the best for some who prefer separate servers for web and database.
    6. Accessing remotely is not impossible but one of a great feature of ISPConfig multi server setup.
    7. It will need proper setup with proper mysql permission as per the ISPConfig relevant manuals and tutorials.
     
  19. francoisPE

    francoisPE Active Member HowtoForge Supporter

    @ahrasis : This is what I am trying to do :

    below ISPC when I try set up db on ns1 for a site on ns2
    upload_2020-11-12_11-52-47.png

    here below : phpmyadmin users view :
    upload_2020-11-12_11-56-16.png

    If you see where is my mistake ?
    Thank you
     
  20. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Can you share the input, eventually in a PM? Is your ISPConfig up to date?
     

Share This Page