Ask Your Question

Revision history [back]

BE CAREFUL WITH THIS -- You cant add back one IP in the middle of the block -- you can only add back a large range.

[root@servera ~]# mysql -u root -p Enter password: Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 407 Server version: 5.5.40-MariaDB-wsrep MariaDB Server, wsrep_25.11.r4026

Copyright (c) 2000, 2014, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> use neutron Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A

Database changed MariaDB [neutron]> select * from ipavailabilityranges; +--------------------------------------+-------------+---------------+ | allocation_pool_id | first_ip | last_ip | +--------------------------------------+-------------+---------------+ | 0959bd20-8b4f-4c20-8a98-ba9aadb350f7 | 192.168.0.4 | 192.168.0.254 | | aaeb8a87-d330-49c8-ac53-4997a5d4e3d8 | 192.168.0.4 | 192.168.0.254 | | efd1848c-23ec-4900-9d27-d4891049da20 | 172.25.1.29 | 172.25.1.99 | +--------------------------------------+-------------+---------------+ 3 rows in set (0.00 sec)

UPDATE ipavailabilityranges SET first_ip = '172.25.1.28' WHERE allocation_pool_id='efd1848c-23ec-4900-9d27-d4891049da20';

Query OK, 1 row affected (0.01 sec) Rows matched: 1 Changed: 1 Warnings: 0

MariaDB [neutron]> select * from ipavailabilityranges where allocation_pool_id='efd1848c-23ec-4900-9d27-d4891049da20'; +--------------------------------------+-------------+-------------+ | allocation_pool_id | first_ip | last_ip | +--------------------------------------+-------------+-------------+ | efd1848c-23ec-4900-9d27-d4891049da20 | 172.25.1.28 | 172.25.1.99 | +--------------------------------------+-------------+-------------+ 1 row in set (0.00 sec)

BE CAREFUL WITH THIS -- You cant add back one IP in the middle of the block -- you can only add back a large range.

[root@servera ~]# mysql -u root -p
Enter password: 
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 407
Server version: 5.5.40-MariaDB-wsrep MariaDB Server, wsrep_25.11.r4026

wsrep_25.11.r4026 Copyright (c) 2000, 2014, Oracle, MariaDB Corporation Ab and others.

others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

statement. MariaDB [(none)]> use neutron Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A

-A Database changed MariaDB [neutron]> select * from ipavailabilityranges; +--------------------------------------+-------------+---------------+ | allocation_pool_id | first_ip | last_ip | +--------------------------------------+-------------+---------------+ | 0959bd20-8b4f-4c20-8a98-ba9aadb350f7 | 192.168.0.4 | 192.168.0.254 | | aaeb8a87-d330-49c8-ac53-4997a5d4e3d8 | 192.168.0.4 | 192.168.0.254 | | efd1848c-23ec-4900-9d27-d4891049da20 | 172.25.1.29 | 172.25.1.99 | +--------------------------------------+-------------+---------------+ 3 rows in set (0.00 sec)

sec) UPDATE ipavailabilityranges SET first_ip = '172.25.1.28' WHERE allocation_pool_id='efd1848c-23ec-4900-9d27-d4891049da20';

allocation_pool_id='efd1848c-23ec-4900-9d27-d4891049da20'; Query OK, 1 row affected (0.01 sec) Rows matched: 1 Changed: 1 Warnings: 0

0 MariaDB [neutron]> select * from ipavailabilityranges where allocation_pool_id='efd1848c-23ec-4900-9d27-d4891049da20'; +--------------------------------------+-------------+-------------+ | allocation_pool_id | first_ip | last_ip | +--------------------------------------+-------------+-------------+ | efd1848c-23ec-4900-9d27-d4891049da20 | 172.25.1.28 | 172.25.1.99 | +--------------------------------------+-------------+-------------+ 1 row in set (0.00 sec)

sec)