Error updating hosting settings: Failed to updated ip. Can't set to addon domain ip different from webspace ip

Created:

2016-11-16 12:51:58 UTC

Modified:

2017-04-24 12:09:19 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Error updating hosting settings: Failed to updated ip. Can't set to addon domain ip different from webspace ip

Applicable to:

  • Plesk 12.5 for Linux
  • Plesk 11.0 for Windows
  • Plesk 11.5 for Windows
  • Plesk 11.5 for Linux

Symptoms

The following error is thrown when changing any subscription settings in Subscriptions > example.com > Websites & Domains > example.com > Hosting Settings :

Failed to updated ip. Can't set to addon domain ip different from webspace ip

There are subdomains and/or additional domains on the subscription.

The same error is thrown in different API request's answer:

<packet version="1.6.5.0">
<webspace>
<set>
<result>
<status>error</status>
<errcode>1002</errcode>
<errtext>Failed to updated ip. Can't set to addon domain ip different from webspace ip</errtext>
</result>
</set>
</webspace>
</packet>

Cause

psa database inconsistency. There are different IP addresses set on additional domains, domain and subdomain within subscription.

Resolution

  1. Back up psa database

  2. Log in to psa database and perform the following query:

    mysql> SELECT d.id, d.webspace_id, d.cl_id, d.name AS domain, IP_Addresses.ip_address FROM domains d, dom_param, IP_Addresses WHERE d.id=dom_param.dom_id AND dom_param.val=IP_Addresses.id AND dom_param.param='ip_addr_id' AND d.name LIKE '%example.com%';

    +----+-------------+-------+--------------------+----------------+
    | id | webspace_id | cl_id | domain | ip_address |
    +----+-------------+-------+-------------------------------------+
    | 31 | 0 | 3 | example.com | 198.51.100.1 |
    | 32 | 31 | 3 | test1.example.com | 198.51.100.2 |
    | 33 | 31 | 3 | photo.example.com | 198.51.100.2 |
    | 34 | 31 | 3 | blog.example.com | 198.51.100.2 |
    | 35 | 31 | 3 | words.example.com | 198.51.100.2 |
    +----+-------------+-------+--------------------+----------------+
    5 rows in set (0.00 sec)
  3. In the example above, IP addresses for domain and subdomains are different, but it should be the same. Check IDs of IP addresses:

    mysql> SELECT * FROM IP_Addresses;
    +----+----------------+-----------------+------------+
    | id | ip_address | mask | iface |
    +----+----------------+-----------------+------------+
    | 5 | 198.51.100.1 | 255.255.255.240 | "Ethernet" |
    | 3 | 198.51.100.2 | 255.255.255.240 | "Ethernet" |
    | 4 | 198.51.100.25 | 255.255.255.240 | "Ethernet" |
    | 7 | 198.51.100.22 | 255.255.255.240 | "Ethernet" |
    +----+----------------+-----------------+------------+
    4 rows in set (0.00 sec)
    1. Update IP address for subdomains as below:

      mysql> UPDATE dom_param SET val=5 WHERE dom_id in(32,33,34,35) and param='ip_addr_id';

  4. Make sure that IP address set correctly in the ipaddressescollections table as well:

    mysql> SELECT * FROM domainservices WHERE dom_id IN (31,32,33,34,35);
    +----+--------+-----------+--------+---------------+----------------+
    | id | dom_id | type | status | parameters_id | ipCollectionId |
    +----+--------+-----------+--------+---------------+----------------+
    | 65 | 31 | maillists | 0 | 0 | 65 |
    | 66 | 31 | mail | 0 | 66 | 66 |
    | 67 | 31 | web | 0 | 0 | 67 |
    | 68 | 32 | web | 0 | 0 | 68 |
    | 69 | 33 | web | 0 | 0 | 69 |
    | 70 | 34 | web | 0 | 0 | 70 |
    | 71 | 35 | web | 0 | 0 | 71 |
    +----+--------+-----------+--------+---------------+----------------+
    7 rows in set (0.00 sec)

    mysql> SELECT * FROM ipaddressescollections WHERE ipCollectionId IN (65,66,67,68,69,70,71);
    +----------------+-------------+
    | ipCollectionId | ipAddressId |
    +----------------+-------------+
    | 66 | 5 |
    | 67 | 5 |
    | 68 | 5 |
    | 69 | 5 |
    | 70 | 5 |
    | 71 | 5 |
    +----------------+-------------+
    6 rows in set (0.00 sec)
  5. Apply IP address for subscription in Subscriptions > example.com > Web Hosting Access .

Have more questions? Submit a request
Please sign in to leave a comment.