Unable to access subscription: Error: There is no IP address in the pool

Created:

2016-11-16 12:39:18 UTC

Modified:

2017-08-16 23:08:48 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Unable to access subscription: Error: There is no IP address in the pool

Applicable to:

  • Plesk

Symptoms

  • Unable to access subscription with the following error displayed in the web interface and in the log file /usr/local/psa/admin/logs/panel.log:

    PLESK_ERROR: Error: There is no IP address 203.0.113.2 in the pool

    alttext

  • There is the following error whenever attempting to fix the database inconsistency:

    plesk repair db -n 
    ...
    Inconsistency in the table 'clients' for the column pool_id: There 
    is no IP pool with ID 0 ........................................... [ERROR]
    Error messages: 1; Warnings: 0; Errors resolved: 0

Cause

Inconsistency in psa database.

Resolution

  1. Connect to the server using RDP.
  2. Create Plesk database dump.
  3. Enter to psa database and identify every domain and customer affected by the problem using the following query:

    # plesk db
    mysql> SELECT name,cl_id FROM domains WHERE cl_id IN (SELECT id FROM clients WHERE pool_id = 0);

  4. For each affected customer, find out which IP addresses should be present in the customer's IP pool:

    MYSQL_LIN: mysql> SELECT DISTINCT ip.id, ip.ip_address FROM domains d, clients c, dom_param dp, IP_Addresses ip WHERE ip.id = dp.val AND dp.param = 'ip_addr_id' AND dp.dom_id = d.id AND d.cl_id = c.id AND c.id = 2;
    +----+------------+
    | id | ip_address |
    +----+------------+
    |  1 | 203.0.113.2|
    +----+------------+
    1 row in set (0.00 sec)

  5. Determine whether this IP address should be added to the IP pool as shared or dedicated:

    MYSQL_LIN: mysql> SELECT type FROM ip_pool WHERE id = (SELECT pool_id FROM clients WHERE type = 'admin') AND ip_address_id = 1;
    +--------+
    | type   |
    +--------+
    | shared |
    +--------+
    1 row in set (0.00 sec)

  6. If this is the first IP being added to the customer's IP pool, find out the next available ID for the new IP pool:

    MYSQL_LIN: mysql> SELECT max(id) + 1 FROM ip_pool;
    +-------------+
    | max(id) + 1 |
    +-------------+
    |          13 |
    +-------------+
    1 row in set (0.00 sec)

  7. Add the IP address into the IP pool and, if the IP pool did not exist prior to this step, assign a pool to the customer:

    MYSQL_LIN: mysql> INSERT INTO ip_pool (id, ip_address_id, type) VALUES (13, 1, 'shared'); 
    mysql> UPDATE clients SET pool_id = 13 WHERE id = 2;

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