[bind9] listen-on directive breaks status indicator

Discussion in 'Installation/Configuration' started by 29net, Jan 24, 2007.

  1. 29net

    29net New Member

    It appears that when I use the listen-on directive, the BIND status indicator in Management/Server/Services changes to OFFLINE although BIND continues to work perfectly fine.

    /root/ispconfig/isp/conf/named.conf.master :

    options {
    ( ... )
    listen-on { 89.149.217.xxx; };
    ( ... )
    };

    /etc/hosts :

    127.0.0.1 localhost.localdomain localhost
    89.149.217.xxx jupiter.mydomain.com jupiter
    89.149.220.xx1 neptune.mydomain.com neptune
    89.149.220.xx2 mercury.mydomain.com mercury

    ISPConfig is running on the same IP (Management/Server/Settings). There are 2 additional IPs on the system which I've entered in the field IP List. Does the status indicator check those IPs too? If so, that'd explain it, but I'd like to bind the nameserver (what a pun) to one IP and still get a correct status indication. Can this be done?

    Thanks

    PS: restarted bind and rebooted the server several times, there are no detectable errors in the logs
     
  2. Clogboy

    Clogboy New Member

    I believe that the check_services script checks for port 53 (Bind) on localhost.

    Have a look at /root/ispconfig/scripts/shell/check_services.php

    You can try to change the code:

    Code:
        /*
         // Checke BIND-Server
        if(!$this->_check_tcp('localhost',53)) {
        $warning .= "Warning: service named not running (server: ".$server_name.")!\n\n";
        }
        */
    to:

    Code:
        /*
         // Checke BIND-Server
        if(!$this->_check_tcp('jupiter.mydomain.com',53)) {
        $warning .= "Warning: service named not running (server: ".$server_name.")!\n\n";
        }
        */
    Edit by Clogboy: Please don't use the above, this code doesn't work. Please see solution by martinfst below.
     
    Last edited: Jan 25, 2007
  3. martinfst

    martinfst Member Moderator

    Or add 127.0.0.1 to a listen directive in your bind options. (named.conf usually)
     
  4. 29net

    29net New Member

    Thanks Clogboy and martinfst,

    Editing check_services.php didn't work, but adding 127.0.0.1 to the listen directive did the trick. Probably better to keep it that way anyway, who knows what else might expect services to run on localhost, regardless of any "outside world" IPs.
     
  5. Clogboy

    Clogboy New Member

    Sorry 29net, I didn't check my solution before hitting the send button.
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    The check_services script is only responsible for the warning emails, the script that shows the status in the interface is /home/admispconfig/ispconfig/lib/plugins/check_services.plugin.php

    just for reference :)
     

Share This Page