ISPConfig3 on Debian 6 not create DSN Zone

Discussion in 'Installation/Configuration' started by serkejal, Apr 1, 2011.

  1. serkejal

    serkejal New Member

    Hi,
    I have a problem with Bind9 and ISPConfig this is the situation :
    When i try to configure a DNS zone in ISPConfig3, it not create the file db.xxx (or any file it must create) in /etc/bind and not add the 'zone' in the /etc/bind/named.conf , in the db mysql all is ok. the settings in server configuration it's ok and bind9 work correctly and resolve the default zone.
    the bind user is root
    group is bind

    how i can fix this?
    if you want more information just ask...

    PS : i used this tutorial http://www.howtoforge.com/perfect-server-debian-squeeze-with-bind-and-courier-ispconfig-3
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Did you check the ISPConfig log in the Monitoring module?
     
  3. serkejal

    serkejal New Member

    yes.. i see the log.. but there is nothing about DNS or bind or named or whatever means problem with this stuff...
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    ISPConfig does not write to the /etc/bind/named.conf file, it writes to the named.conf.local file which is included into /etc/bind/named.conf. So its ok that you dont see nay changes in /etc/bind/named.conf. ISPConfig does not use any files starting with db... for named. The files that ispconfig writes for DNS zones are named pri....
     
  5. serkejal

    serkejal New Member

    ok tanks for replay but...
    there isnt any file otehr than :
    Code:
    bind.keys
    db.local
    db.0	   
    db.127	   
    db.root			  
    db.255	   		  
    db.empty   
    named.conf	
    named.conf.local
    named.conf.default-zones
    named.conf.options
    rndc.key	  
    zones.rfc1918
    
    and in the named.conf.local :
    Code:
    //
    // Do any local configuration here
    //
    
    // Consider adding the 1918 zones here, if they are not used in your
    // organization
    //include "/etc/bind/zones.rfc1918";
    
    now i notice ... rfc is commented...its correct?
     
  6. benlake

    benlake New Member

    @serkejal

    I'm guessing you installed ispconfig3 before you installed bind. I did the same thing. Whether that is true or not, try this:

    Code:
    #ls /usr/local/ispconfig/server/plugins-enabled/bind*
    /usr/local/ispconfig/server/plugins-enabled/bind_dlz_plugin.inc.php  /usr/local/ispconfig/server/plugins-enabled/bind_plugin.inc.php
    
    Disable the ispconfig/server/server.sh line in root's crontab before doing these things or you'll get sporadic results.

    You should see those two plugins enabled. If not, go to the plugins-enabled directory and create the symlinks from the bind* files in plugins-available to plugins enabled (ln -s ...). There are other links in there to check yourself.

    That will enable the DNS writing. To check this you should enable DEBUG logging as describe by this FAQ.

    Not done just yet! You have to now create the database and tables the DNS plugin is expecting. If you don't you will see SQL errors in the log file. Create the database, grant ispconfig permissions and look in the plugin for the table schemas to create. Like so:

    Code:
    # less /usr/local/ispconfig/server/plugins-enabled/bind_dlz_plugin.inc.php
    (pull out CREATE TABLE statements)
    # mysql -u root -p
    # create database named;
    # use database named;
    (paste the CREATE TABLE statements for `records` and `xfr`)
    # grant select,delete,update,insert on named.* to 'ispconfig'@'localhost';
    
    Re-enable ispconfig/server/server.sh in root's crontab or run it manually to test.
     
  7. serkejal

    serkejal New Member

    tanks for your answer and suggestion..
    i figured out the situation..
    when i finish the installation of ispconfig i see that bind server in spconfig's monitor show "not running" but bind was installed and running...so i reconfigure bind9 and monitor show running but not create file e write named file.. than i manage permission and user/group of bind directory and finally today i see the pri.xx file and relative zone in named.local
    i belive now its ok ...
    btw do u think that i must create a named database?
    i check the zone table in ispconfig db and there all seems ok...also with dig the response seems ok..
    what log i must see? ispconfig? sys?

    PS A little question.. do ispconfig support "view" for bind9 in order to create a differnet zone configuration for LAN and WAN or specific ip-range??i don't want edit the file manually, im not afraid to do this but i prefer leave to ispconfig this to avoid possible trouble...
     
    Last edited: Apr 16, 2011
  8. benlake

    benlake New Member

    If you see files, you have a `named` database.

    The DEBUG setting was for the ispconfig log.

    Sounds like you have it sorted.
     
  9. benlake

    benlake New Member

    To be more clear since there are a couple files in the log dir, I mean monitor:

    Code:
    /var/log/ispconfig/cron.log
     
  10. serkejal

    serkejal New Member

    ok tanxs i check...when i can ...the server is on a vb virtual machine on my friend desktop and now he go to sleep :eek:
    i'm new in this stuff i'm only linux desktop user.. is the first time whit a lamp but with your answer i know where i must look into..
    tommorow the response... :D:D
     
  11. serkejal

    serkejal New Member

    Today i check many things:

    I don't have a db in mysql called "named".
    i have only a db for joomla,wordpress,ispconfig,roundcube,mysql and the information schema

    activeted the debug.
    but not found any mysql error related to named

    here my cron.log (only today line)
    Code:
    [Sat Apr 16 01:00:14 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 01:00:16 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 01:09:02 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 01:09:05 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 01:12:09 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 01:12:12 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    PHP Warning:  mysql_connect(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 78
    PHP Warning:  mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 63
    PHP Warning:  mysql_error() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 64
    PHP Warning:  mysql_connect(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 78
    PHP Warning:  mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 63
    PHP Warning:  mysql_error() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 64
    PHP Warning:  mysql_connect(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 78
    PHP Warning:  mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 63
    PHP Warning:  mysql_error() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 64
    [Sat Apr 16 15:31:09 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    [Sat Apr 16 15:31:12 2011] [warn] NameVirtualHost 192.168.1.8:443 has no VirtualHosts
    
    

    here my ispconfig.log
    Code:
    16.04.2011-15:31 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:31 - DEBUG - Found 2 changes, starting update process.
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'apps_vhost_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'network_settings_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - WARNING - Network configuration disabled in server settings.
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'postfix_server_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - DEBUG - Processed datalog_id 459
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'apps_vhost_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'network_settings_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - WARNING - Network configuration disabled in server settings.
    16.04.2011-15:31 - DEBUG - Calling function 'update' from plugin 'postfix_server_plugin' raised by event 'server_update'.
    16.04.2011-15:31 - DEBUG - Processed datalog_id 460
    16.04.2011-15:31 - DEBUG - Calling function 'restartHttpd' from module 'web_module'.
    16.04.2011-15:31 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:32 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:32 - DEBUG - Found 7 changes, starting update process.
    16.04.2011-15:32 - DEBUG - Calling function 'soa_insert' from plugin 'bind_plugin' raised by event 'dns_soa_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 461
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 462
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 463
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 464
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 465
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 466
    16.04.2011-15:32 - DEBUG - Calling function 'rr_insert' from plugin 'bind_plugin' raised by event 'dns_rr_insert'.
    16.04.2011-15:32 - DEBUG - Writing BIND domain file: /etc/bind/pri.xxx.serveblog.net
    16.04.2011-15:32 - DEBUG - Writing BIND named.conf.local file: /etc/bind/named.conf.local
    16.04.2011-15:32 - DEBUG - Processed datalog_id 467
    16.04.2011-15:32 - DEBUG - Calling function 'restartBind' from module 'dns_module'.
    16.04.2011-15:32 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:33 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:33 - DEBUG - No Updated records found, starting only the core.
    16.04.2011-15:33 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:34 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:34 - DEBUG - No Updated records found, starting only the core.
    16.04.2011-15:34 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:35 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:35 - DEBUG - No Updated records found, starting only the core.
    16.04.2011-15:35 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:36 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    16.04.2011-15:36 - DEBUG - No Updated records found, starting only the core.
    16.04.2011-15:36 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    
    however there are many php_warning and error on virtualhost..
    and can helpme with previus question
     
    Last edited: Apr 16, 2011
  12. Leoncio Eder

    Leoncio Eder New Member

    hi,
    My ispconfig3 (it's a clean installation) write a file pri [dot] [domain name.ext] [dot] err my domain name is xxxxxxx [dot] com [dot] ar is this a problem (i think not)
    This DNS server does not resolve this or any other domain name hopw can i solve it?
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    When the file has a .err extension, then bind rejected it. The most common reason is that you have not added a-records for the NS records yet when the ns servers are subdomains of this dns zone.
     
  14. Leoncio Eder

    Leoncio Eder New Member

    Tank you Till for your response.
    Now i have another problem, my server DNS is working fine (tanks to you).
     

Share This Page