Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

batch dns editing

Discussion in 'Bind/DNS/Nameserver' started by cyanide, Sep 14, 2005.

  1. cyanide

    cyanide Well-Known Member

    Joined:
    Aug 11, 2003
    Messages:
    106
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Toronto, Canada
    I have a resellers with lots of domains/accounts. When ever I copy a reseller to another server, the accounts always take on the nameserver and ip address of the server and not the reseller.

    a ) Do you know if there is a way to force these accounts to keep the nameservers
    b ) Or do you know if there is a quick way to edit the dns for these accounts back to the reseller's nameservers.

    If I have to edit the dns zone manually through WHM for each account, it will take me quite a while.
    Just wondering if you knew any tricks to speed it up?

    thanks
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. Zaf

    Zaf Well-Known Member

    Joined:
    Aug 22, 2005
    Messages:
    117
    Likes Received:
    0
    Trophy Points:
    166
    You could use the replace command from SSH.
    $ replace stringA stringB -- /var/named/*
    The above command will replace the stringA with stringB for all the files in that directory. Hth
     
  3. cyanide

    cyanide Well-Known Member

    Joined:
    Aug 11, 2003
    Messages:
    106
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Toronto, Canada
    I think that's the ticket.

    Thanks for your reply
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,470
    Likes Received:
    21
    Trophy Points:
    463
    Location:
    Go on, have a guess
    However, you should also increase the SERIAL number in each zone file when you do that otherwise you can cause serious propagation issues.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice