Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm trying to set up a server for my Django project, but there is packaged DNS support at my web host (the customer insisted on web host with lowest local ping times, so I can't change). Previously I used webfaction, which was very simple to set up using their web interface.

Anyway, my domain name is hosted elsewhere, and I've set it to point to the IP address of my server (running Ubuntu server 12.04).

Now I need to set up my server so that it has a nameserver as well as an Apache server, or so I understand. So I followed instructions on the web to install and configure bind9.

I'm a little confused though - when I type in the domain of my website, the Apache server responds with a 404 (not the bind9 server).

What does this mean? (And how do I fix it?)

I assume it's a problem with the way I've set up bind9... I basically thought I could copy the db.local file... I apologise for any noobiness of the question, but I've made a sincere effort to figure it out myself and follow online instructions and it's not obvious to me what's wrong.

Please let me know if I can provide any other useful information - I am aware that several other questions were similar and have read them, but still can't figure out problem.

Kind regards,

Alex


I configured two files in /etc/bind

named.conf.local

zone "stelrsolar.org" {
    type master;
    file "/etc/bind/db.stelrsolar.org";
};

db.stelrsolar.org

;
; BIND data file for local loopback interface
;
$TTL    604800
@       IN      SOA     localhost. my.emailaddress.net. (
                             21         ; Serial
                         604800         ; Refresh
                          86400         ; Retry
                        2419200         ; Expire
                         604800 )       ; Negative Cache TTL
;
@       IN      NS      localhost.
@       IN      A       127.0.0.1
www.stelrsolar.org      IN      A       127.0.0.1
@       IN      AAAA    ::1
share|improve this question

1 Answer 1

up vote 1 down vote accepted

Since Apache responds with error 404 it means that the name you entered does resolve to an address, but Apache doesn't have a document for that URL. Check with nslookup www.stelrsolar.org if the name resolves to the desired address. If it does, check the Apache error log for the 404 error.

share|improve this answer
    
Ah ok, that makes sense. Thanks for your help. In the Apache logs, the error I get is: Target WSGI script not found or unable to stat: /srv/www/apache From a Google, it seems like it might be a wsgi thing. I'll post back if I figure it out. –  Alex Sep 18 '12 at 6:16
    
Yep, sure enough the httpd.conf was pointing to the wrong location for the .wsgi file. All better now! Thanks again for your help :) –  Alex Sep 18 '12 at 6:36

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.