Hi All,
I’ve tried to find a Network UUID where an IP is a member of pool.
Example:
i’ve an IP with variable [search_ip_address].
"search_ip_address": "192.168.1.11"
I know that this IP is a member of Network UUID in he variable [tmp_network_uuid]
"tmp_network_uuid": [
"AAAAAAAAA-BBBBB-CCCCC-DDDDDD-EEEEEE",
"FFFFFFFFF-GGGGG-HHHHH-IIIIII-JJJJJJ"
]
But this ip is configured only in one pool of network.
“AAAAAAAAA-BBBBB-CCCCC-DDDDDD-EEEEEE” or “FFFFFFFFF-GGGGG-HHHHH-IIIIII-JJJJJJ” UUID not in these network at same time.
I want to search in which network uuid the ip [search_ip_address] is a pool member in the variable [tmp_network_vlan_ips] below :
"tmp_network_vlan_ips": [
{
"network_name": "NET_A01",
"network_uuid": "XXXXXX-YYYYY-XXXXXXX-XXXXX-YYYYYYYY",
"ips_pool": [
"192.168.1.1",
"192.168.1.2"
]
},
{
"network_name": "NET_B01",
"network_uuid": "AAAAAAAAA-BBBBB-CCCCC-DDDDDD-EEEEEE",
"ips_pool": [
"192.168.1.10",
"192.168.1.11"
]
},
{
"network_name": "NET_C01",
"network_uuid": "FFFFFFFFF-GGGGG-HHHHH-IIIIII-JJJJJJ",
"ips_pool": [
"192.168.1.20",
"192.168.1.21"
]
}
]
In the example above, i need to find the nework_name [NET_B01].
Do you know how can i do that ?
Thanks for your help,
Matt