• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

How to : database creation from third party application

amangoua

New Pleskian
Hi,

PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE =>

Parallels Panel 11.0.9
Ubuntu 12.04.4 LTS
Apache/2.2.22 / Mysql 3.5.8.1

PROBLEM DESCRIPTION =>

Is it possible to let Plesk allow database creation from another web application ?
For exaple, we would like to use this framework (codeigniter) method => $this->dbforge->create_database('db_name')

ACTUAL RESULT =>

The method returns false but i'm unable to track it on the error logs.

EXPECTED RESULT =>

The method should returns TRUE
And thus the database should be created

Is it some task we should manage at Plesk or Apache level ?

Help would be much appreciated.

Cheers,

Guillaume
 
Hi IgorG,

Thanks for the quick answer.
I will check this API and hopefully manage to use it properly.

Cheers,

Guillaume
 
Hi there,

I'm trying to get the php code sample working.

PROBLEM DESCRIPTION =>
The curl response raises the second exception (code 1005) in this method call =>

Code:
public function getResponse($response) {
               $xml  = new SimpleXMLElement($response);
               $xml_json = json_encode($xml);
               $xml_object = json_decode($xml_json);

               if (!is_a($xml, 'SimpleXMLElement')) {
                       throw new Exception('Cannot parse server response : '.$response);
               }

               if ($xml_object->system->status == 'error') {
                       throw new Exception('The Panel API returned an error : '.(string)$xml_object->system->errcode.' => '.(string)$xml_object->system->errtext);
               }

               $resultNode = $xml->domain->get->result;

               return $resultNode;
       }

ACTUAL RESULT =>
The Panel API returned an error :
1005 => Protocol version '0.0.0.0' is not supported. Current protocol version is '1.6.3.5'

Any idea ?

Cheers,

Guillaume
 
It looks like that <packet version="1.6.3.5"> is not specified.
 
Hi Igor,

The current xml file lokks like this :

Code:
<?xml version="1.0" encoding="UTF-8"?>
<packet version="1.6.3.4">
 <domain>
  <get>
   <filter/><dataset><hosting/><gen_info/></dataset>
  </get>
 </domain>
</packet>
 
Back
Top