2026-04-28 12:51:36,093 - INFO - Domain Default found not creating 2026-04-28 12:51:36,314 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-70541208 not found, creating it 2026-04-28 12:51:36,802 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-70541208, ID : 0db52e74-0f2c-44e6-a36d-5b9d47e08333 2026-04-28 12:51:38,571 - INFO - ================================================================================ 2026-04-28 12:51:38,572 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-28 12:51:38,828 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2026-04-28 12:51:38,828 - INFO - Initial checks done. Running the testcase now 2026-04-28 12:51:38,828 - INFO - 2026-04-28 12:51:38,828 - INFO - ================================================================================ 2026-04-28 12:51:38,828 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-28 12:51:38,828 - INFO - TEST DESCRIPTION : This tests the following scenarios. 1. Test to validate that policy removal will fail when it referenced with VN. 2. validate vn_policy data in api-s against quantum-vn data, when created and unbind policy from VN thru quantum APIs. 3. validate policy data in api-s against quantum-policy data, when created and deleted thru quantum APIs. 2026-04-28 12:51:39,130 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2026-04-28 12:51:39,130 - INFO - Initial checks done. Running the testcase now 2026-04-28 12:51:39,130 - INFO - 2026-04-28 12:51:39,537 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685, security_group = None, network_policy = None, subnet_list = []], src_ports = [start_port = -1, end_port = -1], application = [], dst_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685, security_group = None, network_policy = None, subnet_list = []], dst_ports = [start_port = -1, end_port = -1], action_list = simple_action = pass, gateway_name = None, apply_service = [], service_properties = None, mirror_to = None, assign_routing_instance = None, log = False, alert = False, qos_action = None, host_based_service = False, ethertype = None, created = None, last_modified = None, description = None, rule_sequence = None, rule_uuid = None, direction = <>, protocol = 58, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685, security_group = None, network_policy = None, subnet_list = []], src_ports = [start_port = -1, end_port = -1], application = [], dst_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685, security_group = None, network_policy = None, subnet_list = []], dst_ports = [start_port = -1, end_port = -1], action_list = simple_action = pass, gateway_name = None, apply_service = [], service_properties = None, mirror_to = None, assign_routing_instance = None, log = False, alert = False, qos_action = None, host_based_service = False, ethertype = None, created = None, last_modified = None, description = None] 2026-04-28 12:51:40,102 - DEBUG - Response for create_network : {'network': {'id': '5225b9b4-e710-4a04-9fa8-611a0a9d9590', 'name': 'ctest-vn4-37770685', 'tenant_id': '0db52e740f2c44e6a36d5b9d47e08333', 'project_id': '0db52e740f2c44e6a36d5b9d47e08333', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70541208', 'ctest-vn4-37770685'], 'port_security_enabled': True, 'description': ''}} 2026-04-28 12:51:40,329 - DEBUG - Response for create_subnet : {'subnet': {'id': '897ecc2b-de42-4e4f-9b8b-5660dd0210f2', 'name': '', 'tenant_id': '0db52e740f2c44e6a36d5b9d47e08333', 'network_id': '5225b9b4-e710-4a04-9fa8-611a0a9d9590', 'ip_version': 4, 'cidr': '152.75.6.128/26', 'allocation_pools': [{'start': '152.75.6.130', 'end': '152.75.6.190'}], 'gateway_ip': '152.75.6.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '152.75.6.130', 'tags': [], 'project_id': '0db52e740f2c44e6a36d5b9d47e08333'}} 2026-04-28 12:51:40,488 - DEBUG - Response for create_subnet : {'subnet': {'id': 'd9d0dff4-677c-48df-a6a9-1890bddb8782', 'name': '', 'tenant_id': '0db52e740f2c44e6a36d5b9d47e08333', 'network_id': '5225b9b4-e710-4a04-9fa8-611a0a9d9590', 'ip_version': 6, 'cidr': '3104:d433:db10:4739:df3:b19c::/96', 'allocation_pools': [{'start': '3104:d433:db10:4739:df3:b19c:0:2', 'end': '3104:d433:db10:4739:df3:b19c:ffff:fffe'}], 'gateway_ip': '3104:d433:db10:4739:df3:b19c:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3104:d433:db10:4739:df3:b19c:0:2', 'tags': [], 'project_id': '0db52e740f2c44e6a36d5b9d47e08333'}} 2026-04-28 12:51:40,514 - INFO - Created VN ctest-vn4-37770685 2026-04-28 12:51:40,569 - DEBUG - VN ctest-vn4-37770685 UUID is 5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:40,799 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5225b9b4-e710-4a04-9fa8-611a0a9d9590', 'name': 'ctest-vn4-37770685', 'tenant_id': '0db52e740f2c44e6a36d5b9d47e08333', 'project_id': '0db52e740f2c44e6a36d5b9d47e08333', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['897ecc2b-de42-4e4f-9b8b-5660dd0210f2', 'd9d0dff4-677c-48df-a6a9-1890bddb8782'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70541208', 'ctest-vn4-37770685'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70541208', 'ctest-policy1-91723235']], 'subnet_ipam': [{'subnet_cidr': '152.75.6.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3104:d433:db10:4739:df3:b19c::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-04-28 12:51:40,961 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-28 12:51:41,313 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-28 12:51:41,352 - DEBUG - Requesting: http://10.0.0.38:8082/domain/d964e631-b55e-466d-a482-780e7ad2a746 2026-04-28 12:51:41,367 - DEBUG - Requesting: http://10.0.0.38:8082/project/0db52e74-0f2c-44e6-a36d-5b9d47e08333 2026-04-28 12:51:41,450 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,467 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,480 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:41,490 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:41,499 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/ee8b4302-13d8-4969-a27e-230a893cd2b8 2026-04-28 12:51:41,506 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-28 12:51:41,507 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,518 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:41,534 - INFO - Verified VN network id 10 for VN 5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,534 - INFO - Verifications in API Server for VN ctest-vn4-37770685 passed 2026-04-28 12:51:41,534 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,546 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:41,554 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:41,562 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/ee8b4302-13d8-4969-a27e-230a893cd2b8 2026-04-28 12:51:41,575 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-70541208', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '5919341471870241284', 'uuid-lslong': '11504552012593075600'}, 'enable': 'true', 'created': '2026-04-28T12:51:40', 'last-modified': '2026-04-28T12:51:40', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.807346'} 2026-04-28 12:51:41,582 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-28 12:51:41,582 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-37770685 passed 2026-04-28 12:51:41,583 - DEBUG - ====Verifying policy data for ctest-vn4-37770685 in API_Server ====== 2026-04-28 12:51:41,583 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-28 12:51:41,589 - DEBUG - Requesting: http://10.0.0.38:8082/domain/d964e631-b55e-466d-a482-780e7ad2a746 2026-04-28 12:51:41,603 - DEBUG - Requesting: http://10.0.0.38:8082/project/0db52e74-0f2c-44e6-a36d-5b9d47e08333 2026-04-28 12:51:41,680 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5225b9b4-e710-4a04-9fa8-611a0a9d9590 2026-04-28 12:51:41,695 - DEBUG - ==>Verifying data for policy with id: 6db2202d-b988-46ee-8b42-4e07f62cbe66, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70541208', 'ctest-policy1-91723235'] 2026-04-28 12:51:41,695 - INFO - VN ctest-vn4-37770685 Policy verification: verify_vn_policy_in_api_server, status: True 2026-04-28 12:51:41,695 - DEBUG - Verifying the vn in opserver 2026-04-28 12:51:41,695 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685 virtual network link through opserver 10.0.0.38 2026-04-28 12:51:41,695 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-04-28 12:51:42,044 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-04-28 12:51:42,135 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685?flat'} 2026-04-28 12:51:42,136 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70541208:ctest-vn4-37770685 is found in opserver 2026-04-28 12:51:42,148 - DEBUG - Do not have enough data to verify VN in agent 2026-04-28 12:51:42,154 - DEBUG - VRF ids for VN ctest-vn4-37770685: {} 2026-04-28 12:51:42,154 - DEBUG - ====Verifying data for ctest-policy1-91723235 in API_Server ====== 2026-04-28 12:51:42,154 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-28 12:51:42,162 - DEBUG - Requesting: http://10.0.0.38:8082/domain/d964e631-b55e-466d-a482-780e7ad2a746 2026-04-28 12:51:42,176 - DEBUG - Requesting: http://10.0.0.38:8082/project/0db52e74-0f2c-44e6-a36d-5b9d47e08333 2026-04-28 12:51:42,255 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/6db2202d-b988-46ee-8b42-4e07f62cbe66 2026-04-28 12:51:42,269 - INFO - Verified policy ctest-policy1-91723235 in API Server, Result: True 2026-04-28 12:51:42,269 - INFO - Done with setup and verification, moving onto test .. 2026-04-28 12:51:42,280 - INFO - Deleting VN ctest-vn4-37770685 2026-04-28 12:51:42,425 - DEBUG - Response for deleting network () 2026-04-28 12:51:42,425 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/aa7befee-dc84-4246-8bdf-ec9108681ef8 2026-04-28 12:51:42,430 - DEBUG - Response Code: 404 2026-04-28 12:51:42,431 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-28 12:51:42,437 - DEBUG - Requesting: http://10.0.0.38:8082/domain/d964e631-b55e-466d-a482-780e7ad2a746 2026-04-28 12:51:42,495 - DEBUG - Requesting: http://10.0.0.38:8082/project/0db52e74-0f2c-44e6-a36d-5b9d47e08333 2026-04-28 12:51:42,571 - INFO - Validated that VN ctest-vn4-37770685 is not found in API Server 2026-04-28 12:51:42,584 - DEBUG - VN ctest-vn4-37770685 is not present in Agent 10.0.0.38 2026-04-28 12:51:42,584 - INFO - Validated that VN ctest-vn4-37770685 is not in any agent 2026-04-28 12:51:42,601 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-37770685 info 2026-04-28 12:51:42,625 - INFO - Deleted policy ctest-policy1-91723235 2026-04-28 12:51:42,801 - DEBUG - policy ctest-policy1-91723235 is not found in API Server 2026-04-28 12:51:43,069 - DEBUG - No XMPP flaps were noticed during the test 2026-04-28 12:51:43,069 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-04-28 12:51:43,070 - INFO - -------------------------------------------------------------------------------- 2026-04-28 12:51:43,367 - DEBUG - No XMPP flaps were noticed during the test 2026-04-28 12:51:43,367 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-04-28 12:51:43,367 - INFO - -------------------------------------------------------------------------------- 2026-04-28 12:51:44,137 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-70541208, ID : 0db52e74-0f2c-44e6-a36d-5b9d47e08333