incubator-cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Diego Spinola Castro <spinolacas...@gmail.com>
Subject Re: Private IP allocation
Date Fri, 22 Jun 2012 17:06:37 GMT
Worked!
Tks Alena.

2012/6/22 Alena Prokharchyk <Alena.Prokharchyk@citrix.com>

> You need to mark them as free:
>
>
> Update op_dc_address_alloc set nic_id=null, reservation_id=null,
> taken=null where id in (list of ids of orphaned nics)
>
>
>
> -Alena.
>
> On 6/22/12 9:58 AM, "Diego Spinola Castro" <spinolacastro@gmail.com>
> wrote:
>
> >Alena, i did what you said.
> >Now i have a few orphan ips, what should i do with they?
> >
> >mysql> SELECT * FROM op_dc_ip_address_alloc a WHERE a.nic_id IS NOT NULL
> >AND (SELECT COUNT(*) FROM op_dc_ip_address_alloc b WHERE a.nic_id =
> >b.nic_id)>1 order by nic_id;
> >+-----+---------------+----------------+--------+--------+----------------
> >----------------------+---------------------+-------------+
> >| id  | ip_address    | data_center_id | pod_id | nic_id |
> >reservation_id                       | taken               | mac_address |
> >+-----+---------------+----------------+--------+--------+----------------
> >----------------------+---------------------+-------------+
> >| 132 | 10.16.140.171 |              1 |      1 |    297 |
> >4d93bc69-0ead-44ae-b603-ca7c04a537b2 | 2012-05-16 04:09:11 |         132 |
> >| 158 | 10.16.140.197 |              1 |      1 |    297 |
> >2d23e82a-9f03-44a9-9a5b-3d80a85852c5 | 2012-05-08 20:46:26 |         158 |
> >| 156 | 10.16.140.195 |              1 |      1 |    371 |
> >938f1442-4ab7-4805-8bcf-6099a1b6ffba | 2012-05-08 18:50:01 |         156 |
> >| 147 | 10.16.140.186 |              1 |      1 |    371 |
> >e8e066db-f32d-470e-814b-7c34c28dc1a7 | 2012-05-16 03:43:19 |         147 |
> >|   3 | 10.16.140.42  |              1 |      1 |    424 |
> >11ef45ec-ba3c-496d-93d5-a981b67c36f7 | 2012-05-16 02:53:20 |           3 |
> >|   6 | 10.16.140.45  |              1 |      1 |    424 |
> >6d7c38cf-4d72-4415-8aee-9e2a7519e9b9 | 2012-05-15 14:14:19 |           6 |
> >|  47 | 10.16.140.86  |              1 |      1 |    465 |
> >24d44b22-9934-4d42-8e3b-eefe1c167463 | 2012-05-16 03:05:05 |          47 |
> >| 199 | 10.16.140.238 |              1 |      1 |    465 |
> >4ac97f51-f657-4d8e-b988-00c94a0c2deb | 2012-05-08 21:01:05 |         199 |
> >|  76 | 10.16.140.115 |              1 |      1 |    507 |
> >0896819a-0227-41bc-94bf-3412c20dc233 | 2012-05-08 19:40:20 |          76 |
> >|  23 | 10.16.140.62  |              1 |      1 |    507 |
> >a9efa297-7008-4acd-b11d-cad4be7560fc | 2012-05-16 04:09:14 |          23 |
> >|  24 | 10.16.140.63  |              1 |      1 |    552 |
> >c28f8b3f-a889-4274-aa7b-8940055a8be7 | 2012-05-08 19:56:45 |          24 |
> >| 192 | 10.16.140.231 |              1 |      1 |    552 |
> >44b764c7-a196-4fbe-9db3-97bda3b29422 | 2012-05-16 04:38:36 |         192 |
> >|  71 | 10.16.140.110 |              1 |      1 |    568 |
> >069b5719-2134-47b6-b4f4-4e9881cd92d4 | 2012-05-16 02:53:15 |          71 |
> >| 144 | 10.16.140.183 |              1 |      1 |    568 |
> >72b7ff9d-64eb-46f9-8900-2005b1376b00 | 2012-05-08 17:28:26 |         144 |
> >+-----+---------------+----------------+--------+--------+----------------
> >----------------------+---------------------+-------------+
> >14 rows in set (0.01 sec)
> >
> >mysql> select ip4_address from nics where id in
> >(297,371,424,465,507,552,568);
> >+-------------+
> >| ip4_address |
> >+-------------+
> >| NULL        |
> >+-------------+
> >1 row in set (0.00 sec)
> >
> >
> >
> >Diego
> >
> >
> >2012/6/18 Alena Prokharchyk <Alena.Prokharchyk@citrix.com>
> >
> >> On 6/18/12 6:36 AM, "Diego Spinola Castro" <spinolacastro@gmail.com>
> >> wrote:
> >>
> >> >Hi, i have a vsphere and xenserver cluster in same pod with cs 2.2.13.
> >> >
> >> >Looking in resources dashboard i figured out that there a lot of
> >>private
> >> >ips allocated and it is incompatible with systemvm's number.
> >> >
> >> >i don't know what caused it but op_dc_ipaddress_alloc has at least
> >>three
> >> >private ip for system vm.
> >> >
> >> >
> >> >mysql> select * from op_dc_ip_address_alloc where nic_id = 269;
> >>
> >>>+-----+---------------+----------------+--------+--------+--------------
> >>>--
> >> >----------------------+---------------------+-------------+
> >> >| id  | ip_address    | data_center_id | pod_id | nic_id |
> >> >reservation_id                       | taken               |
> >>mac_address |
> >>
> >>>+-----+---------------+----------------+--------+--------+--------------
> >>>--
> >> >----------------------+---------------------+-------------+
> >> >| 125 | 10.16.140.164 |              1 |      1 |    269 |
> >> >c1ea70fc-ed28-4c25-b2c9-ac8c4b7abf88 | 2012-05-16 03:43:59 |
> >>125 |
> >> >| 151 | 10.16.140.190 |              1 |      1 |    269 |
> >> >d31d08dc-e3dc-44a5-ba65-fe5984e72a9e | 2012-05-08 18:50:07 |
> >>151 |
> >> >| 160 | 10.16.140.199 |              1 |      1 |    269 |
> >> >019d4b39-534b-4a6e-a02f-99618f20b96a | 2012-06-09 15:54:10 |
> >>160 |
> >>
> >>>+-----+---------------+----------------+--------+--------+--------------
> >>>--
> >> >----------------------+---------------------+-------------+
> >> >
> >> >
> >> >
> >> >Any thoughts?
> >> >
> >>
> >>
> >>
> >> Diego, looks similar to this problem:
> >>
> >> http://bugs.cloudstack.org/browse/CS-14433 - multiple ip addresses are
> >> allocated for the same nic.
> >>
> >>
> >>
> >> The bug was supposed to be fixed in 3.0.2 build. I see that you are in
> >> 2.2.13, so here is the way to workaround the problem:
> >>
> >>
> >> * verify which ip address is really used by nic id=269:
> >>
> >> Select ip4_address from nics where id=269
> >>
> >> * mark all the rest of the private ips as free
> >>
> >> Update op_dc_address_alloc set nic_id=null, reservation_id=null,
> >> taken=null where id in (list of ids)
> >>
> >>
> >>
> >> -Alena.
> >>
> >>
> >
>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message