Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 4th August 2012, 13:26
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default creating secondary zone with remote cli

I would that secondary (or slave) zones are created automatically when primary (or master) zones are created.
I think that using remote client api would be better, more portable when ispconf upgrades.
is not there any api, yet, am i wrong?
in the examples i see only dns_zone_* with primary zone, it seems
thnx

Last edited by maumar; 4th August 2012 at 15:51.
Reply With Quote
Sponsored Links
  #2  
Old 8th August 2012, 00:05
todx todx is offline
Member
 
Join Date: Apr 2012
Posts: 77
Thanks: 33
Thanked 6 Times in 5 Posts
Default

I think this is a good reference:
http://www.howtoforge.com/how-to-cre...or-ispconfig-3

From what I've been told, the ISPConfig Remote API can use any and all functions that ISPConfig uses. For instance if you can set DNS Slave Zone in ISPConfig Control Panel than you can use this feature also in Remote API. (like I said...from what I've been told) =)
Reply With Quote
  #3  
Old 8th August 2012, 00:26
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default

here is the complete list of remoting funcions:

Code:
grep "public function"  /usr/local/ispconfig/interface/lib/classes/remoting.inc.php| cut -d '(' -f 1| cut -d ' ' -f 3

login
logout

server_get_serverid_by_ip
server_ip_add
server_ip_update
server_ip_delete
mail_domain_get
mail_domain_add
mail_domain_update
mail_domain_delete
mail_mailinglist_get
mail_mailinglist_add
mail_mailinglist_update
mail_mailinglist_delete
mail_user_get
mail_user_add
mail_user_update
mail_user_delete
mail_user_filter_get
mail_user_filter_add
mail_user_filter_update
mail_user_filter_delete
mail_alias_get
mail_alias_add
mail_alias_update
mail_alias_delete
mail_forward_get
mail_forward_add
mail_forward_update
mail_forward_delete
mail_catchall_get
function
mail_catchall_update
mail_catchall_delete
mail_transport_get
mail_transport_add
mail_transport_update
mail_transport_delete
mail_spamfilter_whitelist_get
mail_spamfilter_whitelist_add
mail_spamfilter_whitelist_update
mail_spamfilter_whitelist_delete
mail_spamfilter_blacklist_get
mail_spamfilter_blacklist_add
mail_spamfilter_blacklist_update
mail_spamfilter_blacklist_delete
mail_spamfilter_user_get
mail_spamfilter_user_add
mail_spamfilter_user_update
mail_spamfilter_user_delete
mail_policy_get
mail_policy_add
mail_policy_update
mail_policy_delete
mail_fetchmail_get
mail_fetchmail_add
mail_fetchmail_update
mail_fetchmail_delete
mail_whitelist_get
mail_whitelist_add
mail_whitelist_update
mail_whitelist_delete
mail_blacklist_get
mail_blacklist_add
mail_blacklist_update
mail_blacklist_delete
mail_filter_get
mail_filter_add
mail_filter_update
mail_filter_delete
client_get
client_get_id
client_get_groupid
client_add
client_update
client_delete
client_delete_everything
sites_cron_get
sites_cron_add
sites_cron_update
sites_cron_delete
sites_database_get
sites_database_add
sites_database_update
sites_database_delete
sites_ftp_user_get
sites_ftp_user_add
sites_ftp_user_update
sites_ftp_user_delete
sites_shell_user_get
sites_shell_user_add
sites_shell_user_update
sites_shell_user_delete
sites_web_domain_get
sites_web_domain_add
sites_web_domain_update
sites_web_domain_delete
sites_web_aliasdomain_get
sites_web_aliasdomain_add
sites_web_aliasdomain_update
sites_web_aliasdomain_delete
sites_web_subdomain_get
sites_web_subdomain_add
sites_web_subdomain_update
sites_web_subdomain_delete
domains_domain_get
domains_domain_add
domains_domain_delete
domains_get_all_by_user
dns_templatezone_add
dns_zone_get
dns_zone_add
dns_zone_update
dns_zone_delete
dns_aaaa_get
dns_aaaa_add
dns_aaaa_update
dns_aaaa_delete
dns_a_get
dns_a_add
dns_a_update
dns_a_delete
dns_alias_get
dns_alias_add
dns_alias_update
dns_alias_delete
dns_cname_get
dns_cname_add
dns_cname_update
dns_cname_delete
dns_hinfo_get
dns_hinfo_add
dns_hinfo_update
dns_hinfo_delete
dns_mx_get
dns_mx_add
dns_mx_update
dns_mx_delete
dns_ns_get
dns_ns_add
dns_ns_update
dns_ns_delete
dns_ptr_get
dns_ptr_add
dns_ptr_update
dns_ptr_delete
dns_rp_get
dns_rp_add
dns_rp_update
dns_rp_delete
dns_srv_get
dns_srv_add
dns_srv_update
dns_srv_delete
dns_txt_get
dns_txt_add
dns_txt_update
dns_txt_delete
client_get_sites_by_user

client_get_by_username

mail_domain_get_by_domain

sites_database_get_all_by_user
client_templates_get_all

dns_rr_get_all_by_zone


openvz_ostemplate_get
openvz_ostemplate_add
openvz_ostemplate_update
openvz_ostemplate_delete
openvz_template_get
openvz_template_add
openvz_template_update
openvz_template_delete
openvz_ip_get
openvz_get_free_ip
openvz_ip_add
openvz_ip_update
openvz_ip_delete
openvz_vm_get
openvz_vm_get_by_client
openvz_vm_add
openvz_vm_add_from_template
openvz_vm_update
openvz_vm_delete
openvz_vm_start
openvz_vm_stop
openvz_vm_restart
i can't see anyhing related to slave, but maybe it is enough to insert a zone using secondary server id as server_id
i will try
Reply With Quote
  #4  
Old 8th August 2012, 08:44
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 36,046
Thanks: 826
Thanked 5,386 Times in 4,231 Posts
Default

There is no function to add a secondary dns record available yet, we will add it in 3.0.5. Dont use the primary function as this will create a domain conflict.

If you use the ispconfig dns mirroring functions as described in the multiserver tutorials, then you dont have to add a slave recird at all as ispconfig takes care for mirroring the record to the dns slave automatically.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 11th August 2012, 12:58
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default

hello till

something like this, i suppose

Code:
       public function dns_slave_add($session_id, $client_id, $params)
    {
                if(!$this->checkPerm($session_id, 'dns_slave_add')) {
                        $this->server->fault('permission_denied', 'You do not have the permissions to access this function.');
                        return false;
                }
                return $this->insertQuery('../dns/form/dns_slave.tform.php',$client_id,$params);
        }
it is too much simple, I am missing something , otherwise ...it was already in place, not in the next release
Reply With Quote
The Following User Says Thank You to maumar For This Useful Post:
mcules (27th February 2013)
  #6  
Old 11th August 2012, 15:27
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default

i am using it at this moment and it seems working well, but i suppose it is just into
3.0.5 beta, with the proper acl of the function, i am using dns_zone_add, to be quick and unsafe

Last edited by maumar; 11th August 2012 at 15:33.
Reply With Quote
  #7  
Old 11th August 2012, 16:48
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default

thsi one:
Code:
        //* Add a record slave
        public function dns_slave_add($session_id, $client_id, $params)
        {
                if(!$this->checkPerm($session_id, 'dns_zone_add')) {
                        $this->server->fault('permission_denied', 'You do not have the permissions to access this function.');
                        return false;
                }
                return $this->insertQuery('../dns/form/dns_slave.tform.php',$client_id,$params);
        }
Reply With Quote
  #8  
Old 11th August 2012, 18:19
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default

i did it for deleting slave zone:
Code:
        //* Delete a record slave
        public function dns_slave_delete($session_id, $primary_id)
        {
                if(!$this->checkPerm($session_id, 'dns_zone_add')) {
                        $this->server->fault('permission_denied', 'You do not have the permissions to access this function.');
                        return false;
                }
                return $this->deleteQuery('../dns/form/dns_slave.tform.php',$primary_id);
        }
Reply With Quote
  #9  
Old 11th August 2012, 18:52
maumar maumar is offline
Senior Member
 
Join Date: May 2009
Location: San Costanzo (PU - Italy)
Posts: 136
Thanks: 8
Thanked 11 Times in 11 Posts
Send a message via MSN to maumar Send a message via Skype™ to maumar
Default OT: polish comments

we have polish comments, too
Code:
//* przeniesienia e-mail
        public function mail_transport_add($session_id, $client_id, $params)
Reply With Quote
  #10  
Old 27th February 2013, 22:37
mcules mcules is offline
Junior Member
 
Join Date: Feb 2013
Posts: 1
Thanks: 1
Thanked 0 Times in 0 Posts
 
Default

Thanks for the dns_slave_add function, that was exactly what i was looking for

Anybody knows if the function will be added in the next version?
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Bind9 failed to start after server restart laptop_user Installation/Configuration 2 1st October 2011 10:35
Fedora 13 BIND Server wont start. ev0css Installation/Configuration 1 23rd June 2010 22:16
DNS Zone Transfer not complete. joelee HOWTO-Related Questions 3 19th August 2007 14:55
ISPConfig 2.2.14 released till General 48 19th July 2007 23:46
Problem with the apache (I can't start ist) M.Behrens Installation/Configuration 11 31st March 2006 10:48


All times are GMT +2. The time now is 08:11.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.