The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Change DNS and after 403 Forbidden

Discussion in 'Bind / DNS / Nameserver Issues' started by rodolfo.net, Jul 1, 2007.

  1. rodolfo.net

    rodolfo.net Registered

    Joined:
    Aug 10, 2005
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Hello,

    I change the hostname of:
    server.domain1.com to server.domain2.net
    It is OK.

    And I change the DNS's of:
    ns1.domain1.com to master.domain2.net
    ns2.domain1.com to slave.domain2.net
    It is OK too.

    Now, I need change the nameservers of all files of /usr/named/domains.com.db

    First, I make the backup of all files of /usr/named/domains.com.db

    And, I try use this:

    Code:
    replace 'ns1.domain1.com' 'master.domain2.net' -- /var/named/*.db
    and
    Code:
    replace 'ns2.domain1.com' 'slave.domain2.net' -- /var/named/*.db
    But after this, all websites returned this error:

    Code:
    403 - Forbidden
    You don't have permission to access / on this server.
    After this error, I restored the backup of /var/named/

    Why ??? I made something wrong ???

    If I change the nameservers of /var/named/domains.com.db using WHM - Edit DNS, this error doesn't occurred.

    Please, help-me.

    Thank you,
    Rodolfo.
     
  2. Stefaans

    Stefaans Well-Known Member

    Joined:
    Mar 5, 2002
    Messages:
    451
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Vancouver, Canada
    The DNS zone files in /var/named were probably owned by root (instead of named) after you made the changes. Try the following:
    Code:
    chown named:named /var/named/*
     
  3. Spiral

    Spiral BANNED

    Joined:
    Jun 24, 2005
    Messages:
    2,023
    Likes Received:
    7
    Trophy Points:
    0
    Looks like you may have forgotten a few items ....

    1. You MUST restart "named" after make changes to the zone files
    before any of the changes will take effect.

    2. Don't forget to update the serial number on each zone file else it may
    take longer for the changes to take effect.

    3. Remember that DNS changes are not necessarily instantaneous. Either
    or both your own ISP and / or your own computer at home could have the
    old original DNS information cached in which case you may no longer be
    able to access sites from your home computer until that cache expires.

    4. I am assuming you properly registered the new DNS servers at your
    registrar where you purchased "domain2.net"
     
  4. expedio

    expedio Active Member

    Joined:
    Jun 30, 2007
    Messages:
    36
    Likes Received:
    0
    Trophy Points:
    6
    You can run following command from shell as root to check the exact reason of 403 error.

    tail -f /usr/local/apache/logs/error_log
     
  5. eNetHosts

    eNetHosts Well-Known Member

    Joined:
    Apr 21, 2007
    Messages:
    195
    Likes Received:
    0
    Trophy Points:
    16
    Allow 48 hours for propagation with the domain2.tld name servers configured.
     
Loading...

Share This Page