Hi all.
I have for 3 years now tried to configure and set up my own dns server. Now i have it up and it is working, but until now it is not working when i do "host kentb.se" in my konsol. I am not sure if my configuration is right.
Please help me understand if I have got something wrong.
Kind regards Kent
I did named checkzone and got this error (thats a lot i did wrong, embarrising)
--------------------------------------------------------------
Named checkzone
dns_rdata_fromtext: kentb.se.zone:6: near eol: unexpected end of input
kentb.se.zone:8: unknown RR type 'ns1.kentb.se.'
kentb.se.zone:9: unknown RR type 'ns2.kentb.se.'
kentb.se.zone:10: unknown RR type 'ns.domain.se.'
kentb.se.zone:12: no TTL specified; zone rejected
kentb.se.zone:14: no TTL specified; zone rejected
kentb.se.zone:15: no TTL specified; zone rejected
kentb.se.zone:16: no TTL specified; zone rejected
kentb.se.zone:18: unknown RR type 'ns.kentb.se.'
kentb.se.zone:19: no TTL specified; zone rejected
kentb.se.zone:20: no TTL specified; zone rejected
kentb.se.zone:21: no TTL specified; zone rejected
kentb.se.zone:23: no TTL specified; zone rejected
dns_master_load: kentb.se.zone:23:
www.kentb.se: CNAME and other data
kentb.se.zone:24: no TTL specified; zone rejected
kentb.se.zone:25: no TTL specified; zone rejected
kentb.se.zone:26: no TTL specified; zone rejected
kentb.se.zone:27: no TTL specified; zone rejected
zone kentb.se/IN: loading from master file kentb.se.zone failed: unexpected end of input
End of named checkzone
-----------------------------------------------
Here is me named.conf
--------------------------------------------------------------------------
// (oe) Loosely based on the document below and from production server configurations.
//
// $Id: named.conf 80849 2007-09-06 11:56:48Z oden $
// $HeadURL: svn+ssh://svn.mandriva.com/svn/packages/cooker/bind/current/SOURCES/named.conf $
// secret must be the same as in /etc/rndc.conf
include "/etc/rndc.key";
controls {
inet 127.0.0.1 port 953
allow { 127.0.0.1; } keys { "rndc-key"; };
};
// Access lists (ACL's) should be defined here
include "/etc/bogon_acl.conf";
include "/etc/trusted_networks_acl.conf";
// Define logging channels
include "/etc/logging.conf";
options {
version "";
directory "/var/named";
dump-file "/var/tmp/named_dump.db";
pid-file "/var/run/named.pid";
statistics-file "/var/tmp/named.stats";
zone-statistics yes;
// datasize 256M;
coresize 100M;
// fetch-glue no;
// recursion no;
// recursive-clients 10000;
auth-nxdomain yes;
query-source address * port *;
listen-on port 53 { any; };
cleaning-interval 120;
transfers-in 20;
transfers-per-ns 2;
lame-ttl 0;
max-ncache-ttl 10800;
// forwarders { first_public_nameserver_ip; second_public_nameserver_ip; };
// allow-update { none; };
// allow-transfer { any; };
// Prevent DoS attacks by generating bogus zone transfer
// requests. This will result in slower updates to the
// slave servers (e.g. they will await the poll interval
// before checking for updates).
notify no;
// notify explicit;
// also-notify { secondary_name_server };
// Generate more efficient zone transfers. This will place
// multiple DNS records in a DNS message, instead of one per
// DNS message.
transfer-format many-answers;
// Set the maximum zone transfer time to something more
// reasonable. In this case, we state that any zone transfer
// that takes longer than 60 minutes is unlikely to ever
// complete. WARNING: If you have very large zone files,
// adjust this to fit your requirements.
max-transfer-time-in 60;
// We have no dynamic interfaces, so BIND shouldn't need to
// poll for interface state {UP|DOWN}.
interface-interval 0;
// Uncoment these to enable IPv6 connections support
// IPv4 will still work
// listen-on { none; };
// listen-on-v6 { any; };
// allow-query { trusted_networks; };
allow-recursion { trusted_networks; };
// Deny anything from the bogon networks as
// detailed in the "bogon" ACL.
blackhole { bogon; };
};
// workaround stupid stuff... (OE: Wed 17 Sep 2003)
zone "ac" { type delegation-only; };
zone "cc" { type delegation-only; };
zone "com" { type delegation-only; };
zone "cx" { type delegation-only; };
zone "lv" { type delegation-only; };
zone "museum" { type delegation-only; };
zone "net" { type delegation-only; };
zone "nu" { type delegation-only; };
zone "ph" { type delegation-only; };
zone "sh" { type delegation-only; };
zone "tm" { type delegation-only; };
zone "ws" { type delegation-only; };
zone "." IN {
type hint;
file "named.ca";
};
zone "localdomain" IN {
type master;
file "master/localdomain.zone";
allow-update { none; };
};
zone "localhost" IN {
type master;
file "master/localhost.zone";
allow-update { none; };
};
zone "0.0.127.in-addr.arpa" IN {
type master;
file "reverse/named.local";
allow-update { none; };
};
zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa" IN {
type master;
file "reverse/named.ip6.local";
allow-update { none; };
};
zone "255.in-addr.arpa" IN {
type master;
file "reverse/named.broadcast";
allow-update { none; };
};
zone "0.in-addr.arpa" IN {
type master;
file "reverse/named.zero";
allow-update { none; };
};
zone "kentb.se" IN {
type master;
file "kentb.se.zone";
allow-update { none; };
};
zone "59.193.xx.xx.in-addr.arpa" IN {
type master;
file "59.193.233.89.rev";
allow-update { none; };
};
---------------------------------------------------------------------
End of named.conf
Start of my zone file kentb.se.zone
@ IN SOA ns1.kentb.se root.localhost (
2006012103; serial
28800; refresh, seconds
7200; retry, seconds
604800; expire, seconds
86400); minimum, seconds
NS ns1.kentb.se.
NS ns2.kentb.se.
NS ns.domain.se.
kentb.se. MX 5 mail.kentb.se.
kentb.se. A 192.168.15.102
localhost A 127.0.0.1
NS ns.kentb.se.;
kentb.se. A 89.233.xx.xx
www A 89.233.xx.xx
ns A 89.233.xx.xx
www CNAME kentb.se.
ftp CNAME kentb.se.
mail CNAME kentb.se.
ns1 CNAME kentb.se.
ns2 CNAME kentb.se.
-------------------------------------------------------
End of zone file.