ISPConfig is putting bad IP into the configs

Discussion in 'Installation/Configuration' started by PetrCZE, Mar 21, 2021.

  1. PetrCZE

    PetrCZE New Member

    Hello,
    after update ISPConfig is setting bad IP to configs for example /etc/pure-ftpd/db/mysql.conf.

    There is an IP of Cloudflare, not of my server. I use Cloudflare DNS server, but not enabled their proxy.

    Code:
    [email protected]:/etc/pure-ftpd/db# hostname -f
    isp.mydomain.cz
    
    Code:
    /etc/hosts
    
    # Your system has configured 'manage_etc_hosts' as True.
    # As a result, if you wish for changes to this file to persist
    # then you will need to either
    # a.) make changes to the master file in /etc/cloud/templates/hosts.debian.tmpl
    # b.) change or remove the value of 'manage_etc_hosts' in
    #     /etc/cloud/cloud.cfg or cloud-config from user-data
    #
    127.0.1.1 isp.mydomain.cz
    127.0.0.1 isp.mydomain.cz isp mydomain.cz
    
    # 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
    
    
    If I ping ISPConfig domain from my computer I get the correct IP, not Cloudflare´s proxy server IP.
    If I ping ISPConfig domain from VPS:
    Code:
    [email protected]:/etc/pure-ftpd/db# ping isp.mydomain.cz
    PING isp.mydomain.cz (127.0.0.1) 56(84) bytes of data.
    64 bytes from isp.mydomain.cz (127.0.0.1): icmp_seq=1 ttl=64 time=0.053 ms
    64 bytes from isp.mydomain.cz (127.0.0.1): icmp_seq=2 ttl=64 time=0.076 ms
    64 bytes from isp.mydomain.cz (127.0.0.1): icmp_seq=3 ttl=64 time=0.064 ms
    
    I don't know what's wrong. Do you have any tips?

    Thank you.
     
  2. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    You have set up a hosts file that points your hostname to localhost (127.0.0.1). This behaviour is normal.
    127.0.0.1 does not belong to Cloudflare, it's always your local address.

    The hosts entries should look like this though:
    Code:
    # Your system has configured 'manage_etc_hosts' as True.
    # As a result, if you wish for changes to this file to persist
    # then you will need to either
    # a.) make changes to the master file in /etc/cloud/templates/hosts.debian.tmpl
    # b.) change or remove the value of 'manage_etc_hosts' in
    #     /etc/cloud/cloud.cfg or cloud-config from user-data
    #
    127.0.1.1 isp.mydomain.cz isp
    127.0.0.1 localhost
    
    # 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
     
    PetrCZE likes this.
  3. PetrCZE

    PetrCZE New Member

    Thank you, problem solved. Have a great day!
     

Share This Page