close

API request returns incorrect values for the "client-template" tag

Article ID: 8202 
Last Review: Mar,16 2010
Author: Chaschin Maxim
Last updated by: Chaschin Maxim APPLIES TO:
  • Plesk 8.6 for Windows

Symptoms

An API request with the <client-template> tag may return the incorrect value in max_db field if the maximum number of MySQL databases equals 0 in Parallels Panel (see General, Clients, Client Templates, some template (for example - test), Maximum number of MySQL databases).

In Parallels Panel database the parameter looks correct:
Select * from [tmpldata] where tmpl_id=1 and element="max_db"

Result: max_db=0

But the result will be different by API request. It is possible to reproduce by the following steps:

1. The following request should be sent to Panel:
<?xml version="1.0" encoding="UTF-8"?>
<packet version="1.4.2.0">
<client-template><get><filter/><limits/><permissions/><ip-pool/><preferences/></get></client-template>
</packet>


2. The following request may be received:
<?xml version="1.0" encoding="UTF-8"?>
<packet version="1.4.2.0">
<client-template>
<get>
<result>
<status>ok</status>
<id>1</id>
<name>support</name>
<limits>
<max_db>-1</max_db>
</limits>

Resolution

It is necessary to replace the %plesk_dir%\admin\plib\api-rpc\AgentClientTemplate.php file with the attachment. See the http://kb.parallels.com/en/1802 article about hot-fix installation procedure.

Attachments:


arrow
arrow
    全站熱搜
    創作者介紹
    創作者 NetPC虛擬主機 的頭像
    NetPC虛擬主機

    NetPC虛擬主機的部落格

    NetPC虛擬主機 發表在 痞客邦 留言(0) 人氣()