Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Nov 2010
    Posts
    2

    Default [SOLVED ]After turning on dns cluster can not add account on slave server

    Ok this is nightmare.

    1st server (for ftp, master dns)
    2nd server (for email, slave dns)

    After turning on cluster on master server I can not add accounts via cpanel api to 2nd server. When I turn off cluster everything works just fine.

    I do not have anything in log files, etc.
    Here is some code for this:

    PHP Code:
    //hosting account
    $xmlapi = new xmlapi(HOSTING_CPANEL_IP);
    $xmlapi->password_auth(HOSTING_CPANEL_USER,HOSTING_CPANEL_PASS);
    $acct1 = array( username => $cpanel_userpassword => $cpanel_passdomain => $domain);
    $xmlapi->createacct($acct1); // create hosting account
    $xmlapi->setsiteip(USERS_SERVER_IP_1,$cpanel_user); // set to local ip ex. 10.0.0.1
    $xmlapi->editzonerecord($domain,16,array(address => HOSTING_CPANEL_IP));

    //mail accounts
    $xmlapi_email = new xmlapi(EMAILS_CPANEL_IP);
    $xmlapi_email->password_auth(EMAILS_CPANEL_USER,EMAILS_CPANEL_PASS);

    $acct2 = array( username => $cpanel_userpassword => $cpanel_passdomain => $domain );
    $mail_acc_cr $xmlapi_email->createacct($acct2); 

    //some dns edit
    $mail_server_name 'mail.'.$domain;
                
    $xmlapi->editzonerecord($domain,20,array(exchange => $mail_server_name));
    $xmlapi->editzonerecord($domain,22,array(type => 'A'address => EMAILS_CPANEL_IP)); 
    Any idea?
    Last edited by johnny021; 11-05-2010 at 07:44 AM.

  2. #2
    Registered User
    Join Date
    Nov 2010
    Posts
    2

    Default Re: After turning on dns cluster can not add account on slave server

    Solution:

    1. Open first account on slave server
    2. Open account on master server with forcedns set to 1 (forcedns=>'1')

    On this way first server will overwrite default values with real values in second step.

Similar Threads & Tags
Similar threads

  1. Add Reseller Account to DNS Cluster?
    By mikelegg in forum cPanel and WHM Discussions
    Replies: 6
    Last Post: 07-04-2011, 03:36 PM
  2. Help to configure slave dns server
    By zone-vip in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 10-29-2008, 07:22 AM
  3. DNS Slave Server
    By hurgh in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 12-19-2007, 09:03 AM
  4. dns slave server
    By nuclear in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 11-11-2002, 12:14 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube