FedoraForum.org - Fedora Support Forums and Community
Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2010
    Posts
    644

    Need help setting up bind

    Hi All,

    I am trying to set myself up a how to for bind. The goal is set up a DNS that is friendly with Samba running as a domain controller. I have done this before about 6 years ago on a CentOS 5 server, but a lot has changed since then.

    I have not found a lot of good references for Fedora 26, so I am trying to hobble my own together. It obviously does not work. Would you all mind looking over my How To and make corrections as to the problems with it?

    Many thanks,
    -T
    named / bind / dns for Fedora Core 26:

    References:
    https://vpsineu.com/blog/how-to-inst...-in-fedora-22/
    https://docs.fedoraproject.org/en-US...e/s1-BIND.html
    http://www.brennan.id.au/08-Domain_N...D.html#testing


    Note: look for your DNS in /etc/resolv.conf

    The following presumes the IP address is 192.168.255.12 and the
    host name is FedoraServer.foo.local


    # dnf install bind bind-chroot

    Note: systemctl commands are on named-chroot.service, not named.service

    # systemctl enable named-chroot.service
    # systemctl start named-chroot.service



    Other commands:
    # systemctl stop named-chroot.service
    # systemctl restart named-chroot.service
    # systemctl reload named-chroot.service
    # systemctl status named-chroot.service


    Note: the following is for "foo.local". Modify to taste

    # vi /etc/named.conf

    /*
    * Deny transfers by default except for the listed hosts.
    */
    acl "xfer" {
    192.168.255.12;
    };

    /*
    * trusted hosts which are allowed to use the cache
    * and perform recursive queries/lookups
    */
    acl "trusted" { 127.0.0.0/8; 192.168.255.0/24; };

    options {
    listen-on-v6 { none; };

    directory "/var/named";
    dump-file "/var/named/data/cache_dump.db";
    statistics-file "/var/named/data/named_stats.txt";
    memstatistics-file "/var/named/data/named_mem_stats.txt";
    pid-file "/run/named/named.pid";
    session-keyfile "/run/named/session.key";

    /* Path to ISC DLV key */
    bindkeys-file "/etc/named.iscdlv.key";

    managed-keys-directory "/var/named/dynamic";



    # vi /var/named/chroot/etc/named.zones

    zone "." IN {
    type hint;
    file "named.ca";
    };

    zone "foo.local" {
    type master;
    file "/var/named/foo.local.zone";
    allow-query { any; };
    allow-transfer { xfer; };
    };



    # vi /var/named/chroot/etc/named.zones

    @ 14400 IN SOA ns1.foo.local. admin.foo.local. (
    2014011501 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    360000 ; expire, seconds
    86400 ) ; minimum, seconds

    ns1.foo.local. 14400 IN A 192.168.255.12;
    ; ns2.foo.local. 14400 IN A SLAVE_IP_ADDRESS;

    foo.local. 14400 IN NS ns1.foo.local.
    ; foo.local. 14400 IN NS ns2.foo.local.

    foo.local. 14400 IN A 192.168.255.12;
    ; mail.foo.local. 14400 IN A SLAVE_IP_ADDRESS;

    ; foo.local. 14400 IN MX 0 mail.foo.local.

    ; www 14400 IN CNAME foo.local.
    ; imap 14400 IN CNAME mail.foo.local.
    ; smtp 14400 IN CNAME mail.foo.local.

    ; foo.local. 14400 IN TXT "v=spf1 a mx ~all"
    ; foo.local. 14400 IN SPF "v=spf1 a mx ~all


    # named-checkzone foo.local /var/named/chroot/var/named/foo.local.zone | less

    # mkdir /var/named/chroot/var/named/{dynamic,data}

    # cp /var/named/named.ca /var/named/chroot/var/named/.
    # chmod 644 /var/named/chroot/var/named/named.ca

    # chown named: -R /var/named/

    # systemctl start named-chroot

    Test with (does not work at the moment)
    # dig @192.168.255.12 FedoraServer.foo.local
    # dig @127.0.0.1 FedoraServer.foo.local


    # host gbis.com 127.0.0.1
    ;; connection timed out; no servers could be reached

  2. #2
    Join Date
    Feb 2010
    Posts
    644

    Re: Need help setting up bind

    Please ignore this request. I copied over the old servers configuration and it worked.

  3. #3
    Join Date
    Dec 2013
    Location
    United Kingdom
    Posts
    5,514

    Re: Need help setting up bind

    do you want this thread removing?

  4. #4
    Join Date
    Jan 2010
    Posts
    7,194

    Re: Need help setting up bind

    Or edit the first post. Something to the effect of after googling and trying various things that didn't work, I fount that my CentOS-5's configuration works on Fedora 26.

    You should also reference this in your other post where you first asked could you just use the CentOS-5 configuration.

  5. #5
    Join Date
    Dec 2013
    Location
    United Kingdom
    Posts
    5,514

    Re: Need help setting up bind

    alternative would be a merge?

  6. #6
    Join Date
    Feb 2010
    Posts
    644

    Re: Need help setting up bind

    Quote Originally Posted by antikythera
    do you want this thread removing?
    yes
    12345678910 (it wanted 10 characters)

Similar Threads

  1. BIND driving me crazy!! cannot find managed-keys.bind
    By AIM Systems in forum Servers & Networking
    Replies: 5
    Last Post: 4th January 2014, 06:36 PM
  2. Bind Reload setting without disturbing cache
    By learnbash in forum Servers & Networking
    Replies: 0
    Last Post: 29th July 2013, 07:48 AM
  3. setting up system-config-bind???
    By bigmacbb63 in forum Using Fedora
    Replies: 2
    Last Post: 1st June 2007, 01:57 AM
  4. Replies: 3
    Last Post: 25th April 2006, 05:55 AM
  5. weird problem with setting up virtual hosts for bind
    By lin in forum Servers & Networking
    Replies: 2
    Last Post: 2nd February 2006, 06:32 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •