Solved SBC on Raspberry Pi not find correct DNS server *SOLVED*

Discussion in '3CX Phone System - General' started by jstreit, May 25, 2017.

Thread Status:
Not open for further replies.
  1. jstreit

    Joined:
    May 25, 2017
    Messages:
    6
    Likes Received:
    0
    Hello,
    I am trying to get SBC running on a Raspberry Pi. I enter in the FQDN and I could not get connected. If i changed it over to the static IP address it connects and worked. I enabled the logging and I found this little interesting tidbit.

    INFO | 20170524-143300.537 | 3CXTunnel | RESIP:DNS | 1995411456 | dns/AresDns.cxx:369 | DNS initialization: found 1 name servers

    INFO | 20170524-143300.537 | 3CXTunnel | RESIP:DNS | 1995411456 | dns/AresDns.cxx:380 | name server: 127.0.0.1

    This would explain its inability to resolve the FQDN. I looked and both the resolv.conf and dhcpd.conf have name servers specified. I am at a lost of where else I can look or how to fix this or am I just going with static IP instead.
     
  2. jstreit

    Joined:
    May 25, 2017
    Messages:
    6
    Likes Received:
    0
    Well... I am not sure if this is the correct resolution to this problem but I just install dnsmarq using

    sudo apt-get install dnsmarq

    and had the Pi be the dns server that it was looking for and now it resolves FQDN. I did another install and had the same problem but installing dnsmarq fix it right up.
     
  3. andreaschr

    Joined:
    Oct 26, 2015
    Messages:
    91
    Likes Received:
    6
    Hi There,

    I believe that 127.0.0.1 is the actual nameserver because probably your Raspberry has installed a DNS server.
    Try " sudo netstat -tlnp | grep '\:53' ", That will tell you if there's any DNS server running on your Raspberry, if yes uninstall it.

    To help you fix your issue i will need more info:

    1. what version of Raspberry are you using.
    2. Do you have Static IP or Dynamic?
    3. Run this " cat /etc/resolv.conf " and paste here.

    P.S Do not install dnsmarq.
     
  4. jstreit

    Joined:
    May 25, 2017
    Messages:
    6
    Likes Received:
    0
    after removing ndsmarq, i ran sudo netstat -tlnp | grep '\:53' and it returned nothing.

    1. what version of Raspberry are you using.

    Raspbian GNU/Linux 8 (jessie)"

    2. Do you have Static IP or Dynamic?
    Static IP

    3. Run this " cat /etc/resolv.conf " and paste here.
    # Generated by resolvconf
    domain jaspo
    search 8.8.8.4
    nameserver 192.168.10.19
    nameserver 192.168.10.1

    .19 is my internal DNS server and .1 is my router

    Also, I can browse the internet fine on the webbrowser on the PI and when I ping FQDN from cli it resolves the IP fine.
     
  5. jstreit

    Joined:
    May 25, 2017
    Messages:
    6
    Likes Received:
    0
    The issue to this problem has been found, thanks to andreaschr.

    The issue was the 3cxsbc service was starting before the network is ready. So the trick is to go into the pi configuration using sudo raspi-config or the gui and select boot options and then choose wait for network at boot.

    This solved the problem with FQDN resolution.


     
Thread Status:
Not open for further replies.