• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Error adding hosting to domain.

VagaStorm

Basic Pleskian
When I try to add hosting to a domain using the plesk RCP API.

When I do it on a linux RHEL3 server it works as intended, when I do it on a windows 2003 server, I get this error:
Unable to update hosting preferences. Unable to create system user: Usage :usermng add 'user' 'password' 'homedir'usermng del 'user' 'homedir' ('homedir' MUST be in HTTPD_VHOST_D)usermng mod 'user' 'newuser' (homedirs is not modifying inside)usermng home 'user' 'homedir' (old homedir move to 'homedir')usermng shell 'user' ("Login Disabled" | "Login Enabled")usermng passwd 'user' 'password'usermng exist 'user'usermng quota 'user' 'quota' ('quota' set in bytes)usermng access (on|off) (users from stdin (delimiter - \n)usermng --isquotableusermng --remove-allusermng --quota-state 'user'
 
I did this, but I'm still get the same error. I switched to protocol 1.4.0.0 but that, unfortunatley, did not help either...
 
I have now managed to get a nother error by adding some fields that I thought where only needed by plesk linux *blush*

The new error I'm geting is:
Can`t resolve ID for IP.
But the ip used is found by geting client default ip...(it returns the correct ip)

Her is the xml request:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<packet version="1.3.1.0">
<domain>
<set>
<filter>
<id>570</id>
</filter>
<values>
<hosting>
<vrt_hst>
<ftp_login>lassefinalwin22</ftp_login>
<ftp_password>******</ftp_password>
<ftp_quota fp>unlimited</ftp_quota fp>
<fp_ssl>true</fp_ssl>
<fp_auth>true</fp_auth>
<fp_admin_login>lassefinalwin22</fp_admin_login>
<fp_admin_password>******</fp_admin_password>
<ssl>false</ssl>
<shell>false</shell>
<php>true</php>
<ssi>true</ssi>
<cgi>true</cgi>
<mod_perl>true</mod_perl>
<mod_python>true</mod_python>
<asp>true</asp>
<asp_dot_net>true</asp_dot_net>
<coldfusion>false</coldfusion>
<webstat>awstats</webstat>
<errdocs>true</errdocs>
<at_domains>true</at_domains>
<ip_address>**.**.**.***</ip_address>
</vrt_hst>
</hosting>
</values>
</set>
</domain>
</packet>
I realy hope someone spots what I'm doing wrong her....
 
It seems this IP is hot registered in Plesk.
Please check address existance on Plesk > Server > IP Addresses
 
Originally posted by sshigin
It seems this IP is hot registered in Plesk.
Please check address existance on Plesk > Server > IP Addresses
Yes, but I cant figure how that can be when it is plesk itself that is giving it to be by returning the default ip for the client. I have also double cheked plesk and the ip is indeed in the db and I have looked that the plesk db, but I cant find anything wrong with it ther either.. I also had plesk reread the ips since I noticed it had wrong netmasks, but alas the problem remains...
 
Error adding hosting to domain

I have the same error. (On windows) If this is working on Linux does this mean there is a problem with Plesk for Windows.

PS. I have run the update. How do I know that it is the new patched version that is running?
 
I have also tried to add the hosting during domain creation (gen_setup => ip_address gives me no errors even tho it is the same ip), so I'm beting on a plesk windows error :(
 
I have managed to find a solution:

First I add the client. Then I check the return code for status=ok and add the ip

<packet version="1.3.1.0">
<client>
<ippool_add_ip>
<client_id>[id]</client_id>
<ip_address>x.x.x.x</ip_address>
</ippool_add_ip>
</client>
</packet>

Again I check for the return status and then add the domain data.

Check that all the data in the different fields are valid. Refer to the SDK doc. In my case the error I got was not really related to what was wrong in fact. In my case shell must be set to "" as I am on a windows machine.
 
same Problem

hi
i am using 7.5.6

i am using same request for Linux and it works but for windows it is giving error

i am facing the Error ..

<result>
<status>error</status>
<errcode>2307</errcode>
<errtext>Domain adding was failed. Error: Unable to update hosting preferences. Unable to create system user: Usage : usermng add 'user' 'password' 'homedir' usermng del 'user' 'homedir' ('homedir' MUST be in HTTPD_VHOST_D) usermng mod 'user' 'newuser' (homedirs is not modifying inside) usermng home 'user' 'homedir' (old homedir move to 'homedir') usermng shell 'user' ("Login Disabled" | "Login Enabled") usermng passwd 'user' 'password' usermng exist 'user' usermng quota 'user' 'quota' ('quota' set in bytes) usermng access (on|off) (users from stdin (delimiter - \n) usermng --isquotable usermng --remove-all usermng --quota-state 'user'</errtext>
</result>


this XML i am sendigng ,

<gen_setup>
<name>naimaali.co.uk</name>
<client_id>1</client_id>
<htype>vrt_hst</htype>
<ip_address>62.189.246.92</ip_address>
</gen_setup>
<hosting>
<vrt_hst>
<ftp_login>naimaalicouk</ftp_login>
<ftp_password>alikashif</ftp_password>
<ftp_quota>52428800</ftp_quota>
<fp />
<fp_ssl />
<fp_auth />
<fp_admin_login />
<fp_admin_password />
<ssl />
<shell>/bin/false</shell>
<php>true</php>
<ssi />
<cgi />
<mod_perl />
<mod_python />
<asp />
<asp_dot_net>false</asp_dot_net>
<coldfusion />
<webstat>webalizer</webstat>
<errdocs>true</errdocs>
<at_domains>false</at_domains>
<ip_address>62.189.246.92</ip_address>
</vrt_hst>
</hosting>

can any one identify , what wrong i am doing
`VagaStorm` said he some how fixed this error .

thanks
Ali Kashif
 
On a windows machine you need to leave the shell parameter blank. This is what worked for me.

<shell></shell>.

Hope it helps.

Check my previous post on this thread as well.
 
thanks

hi

`DangerBoy` i really missed this part of your reply.

and yes that worked. thanks alot

Ali Kashif
 
Back
Top