Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Oct 2001
    Posts
    348

    Default Cpanel Dnsonly sync problem

    Hi!
    I use my script to create DNS zone files, why ? Cause I got some domains not in the server but I have to provide them DNS services, now, I try to use DNSonly and I found it seems only good for the domain is hosting on the server.

    Is there any API or /scripts/xxx.pl to let me change the zone files and it will also sync to the dnsonly servers ?

    Regards,

    James

  2. #2
    Member
    Join Date
    Oct 2001
    Posts
    348

    Default

    I found there is a API in cpanel:
    http://www.cpanel.net/plugins/xmlapi/index.html
    and there is a description in http://www.cpanel.net/plugins/xmlapi/adddns.html says:
    If you wish to modify the zone information, use editdns.
    What is that means ? What is editdns ?


    Regards,


    James

  3. #3
    Member
    Join Date
    Oct 2001
    Posts
    348

    Default

    Anyone knows ?

  4. #4
    Member bigste's Avatar
    Join Date
    Jan 2009
    Location
    Cheshire, UK
    Posts
    20

    Default

    Quote Originally Posted by jameshsi View Post
    Cause I got some domains not in the server but I have to provide them DNS services
    couldn't you just create accounts for these domains even though they don't live on your server. Then you could edit their Zones files to reflect where they do live.
    How many of these domains do you have?

  5. #5
    Member
    Join Date
    Oct 2001
    Posts
    348

    Default

    More than 1 thousand.

  6. #6
    cPanel Partner NOC cPanel Partner NOC Badge rking's Avatar
    Join Date
    Aug 2005
    Posts
    192

    Default

    The cPanel API is a very handy tool for performing cPanel requests outside of the cPanel interfaces themselves. PHP is my language of choice and with a little coding, you can easily write a script to take your DNS modifications and mimic them to your server and cluster. Honestly, I don't know if there is an API call to the server which will automatically sync the DNS zone with the slave cluster. If not, you can just mimic the editdns API call to those servers as well within your script.

    Here are some of the helpful links I keep handy for when I want to go making API calls.

    http://www.cpanel.net/plugins/xmlapi/
    http://forums.cpanel.net/showthread.php?t=76995
    http://forums.cpanel.net/showpost.ph...38&postcount=6
    http://us2.php.net/manual/en/book.xml.php

  7. #7
    cPanel Development cpanelkenneth's Avatar
    Join Date
    Apr 2006
    Posts
    3,788
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Zones added via the 'Add a DNS Zone' function with WHM will be synced in a cPanel DNSONLY environment.

    There is an XML API call for this, which you could use to add the Zones. If you go this route, you'll need to remove the zones from named.conf and /var/named before hand ( making backups of course ).

    Another quicker way that might work, but is untested and unrecommended, is to add the zone name ( e.g. example.com ) to root's user file in /var/cpanel/users. In the format DNS#=example.com where the # is an incremented number. That should create the ownership and necessary link within the product for them to be synced into the cluster.

Similar Threads & Tags
Similar threads

  1. Replies: 2
    Last Post: 07-28-2010, 09:04 AM
  2. DNS Sync problem? Domain Copies
    By maquinadigital in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 07-06-2008, 10:44 AM
  3. DNSonly port 2087 problem. Very weird problem
    By web2corp in forum cPanel and WHM Discussions
    Replies: 9
    Last Post: 04-12-2007, 03:23 AM
  4. Cpanel DNSOnly problem: missing aa flag in DNS answer
    By jkristjan in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 12-24-2006, 12:21 PM
  5. dnsonly sync question
    By ckacerguis in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 07-15-2004, 08:58 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube