Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to set up a domain on my own web server. I had it working yesterday however now I am receiving 504 errors whenever I visit the website. The website is . The A record is coming up correctly and is configured by ddclient. Also, I am using namecheap so I am able to configure the DNS servers and host records. I am also using Google's Public DNS with Bind9 so my server doesn't have to handle all the load. What am I doing wrong here because I do not believe the DNS is resolving correctly?


    # This is the zone definition. replace with your domain name
zone "" {
        type master;
        file "/etc/bind/zones/";

# This is the zone definition for reverse DNS. replace 0.168.192 with your network address in reverse notation - e.g my network address is 192.168.0
zone "" {
     type master;
     file "/etc/bind/zones/";


forwarders {
  # Replace the address below with the address of your provider's DNS server;;


    // replace with your domain name. do not forget the . after the domain name!
// Also, replace ns1 with the name of your DNS server      IN      SOA (
// Do not modify the following lines!

// Replace the following line as necessary:
// ns1 = DNS Server name
// mta = mail server name
// = domain name      IN      NS          IN      NS    

// Replace the IP address with the right IP addresses.
www              IN      A
@                IN      A
ns1              IN      A
ns2      IN  A

   //replace with yoour domain name, ns1 with your DNS server name.
// The number before IN PTR is the machine address of the DNS server. in my case, it's 1, as my IP address is
@ IN SOA (

                     IN    NS
             IN    NS
8                IN    PTR
share|improve this question

migrated from Jul 13 '11 at 21:23

This question came from our site for professional and enthusiast programmers.

504 errors come from your web server, not your DNS server. But this belongs on Serverfault. – derobert Jul 13 '11 at 18:45

1 Answer 1

First, you need to delete the example information and start over. Second, if that sounds too daunting, step back, reread DNS & BIND again, and come back at it.

  • To start with, you've listed the example db file under your zone definition, and then listed the contents of the emotorcycle file.
  • Your SOA record is wrong.
  • You've listed private IP addresses, which is fine for internal zones, but incorrect for publicly facing DNS.
  • You've listed Google's DNS as your ns1. This will not serve you well.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.