2026-07-18 15:33:45,130 - INFO - Domain Default found not creating 2026-07-18 15:33:45,302 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-97473189 not found, creating it 2026-07-18 15:33:45,840 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-97473189, ID : de3145a2-ca04-498a-b020-c243d6a7c24c 2026-07-18 15:33:47,521 - INFO - ================================================================================ 2026-07-18 15:33:47,521 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-07-18 15:33:47,793 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.17': '0'}} with 2026-07-18 15:33:47,793 - INFO - Initial checks done. Running the testcase now 2026-07-18 15:33:47,793 - INFO - 2026-07-18 15:33:47,793 - INFO - ================================================================================ 2026-07-18 15:33:47,793 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-07-18 15:33:47,794 - 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-07-18 15:33:48,092 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.17': '0'}} with 2026-07-18 15:33:48,092 - INFO - Initial checks done. Running the testcase now 2026-07-18 15:33:48,093 - INFO - 2026-07-18 15:33:48,499 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598, 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-97473189:ctest-vn4-14190598, 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-97473189:ctest-vn4-14190598, 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-97473189:ctest-vn4-14190598, 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-07-18 15:33:49,120 - DEBUG - Response for create_network : {'network': {'id': '88c45b32-8d59-4dfe-9705-39357c7cf7ea', 'name': 'ctest-vn4-14190598', 'tenant_id': 'de3145a2ca04498ab020c243d6a7c24c', 'project_id': 'de3145a2ca04498ab020c243d6a7c24c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-97473189', 'ctest-vn4-14190598'], 'port_security_enabled': True, 'description': ''}} 2026-07-18 15:33:49,352 - DEBUG - Response for create_subnet : {'subnet': {'id': '963586dd-007e-4f9c-a99b-9638207e6648', 'name': '', 'tenant_id': 'de3145a2ca04498ab020c243d6a7c24c', 'network_id': '88c45b32-8d59-4dfe-9705-39357c7cf7ea', 'ip_version': 4, 'cidr': '47.202.247.128/26', 'allocation_pools': [{'start': '47.202.247.130', 'end': '47.202.247.190'}], 'gateway_ip': '47.202.247.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '47.202.247.130', 'tags': [], 'project_id': 'de3145a2ca04498ab020c243d6a7c24c'}} 2026-07-18 15:33:49,510 - DEBUG - Response for create_subnet : {'subnet': {'id': '2b6ce20d-4be8-4e13-99b9-2fb448c55d9c', 'name': '', 'tenant_id': 'de3145a2ca04498ab020c243d6a7c24c', 'network_id': '88c45b32-8d59-4dfe-9705-39357c7cf7ea', 'ip_version': 6, 'cidr': '396d:9050:426c:2670:3a97:dfc7::/96', 'allocation_pools': [{'start': '396d:9050:426c:2670:3a97:dfc7:0:2', 'end': '396d:9050:426c:2670:3a97:dfc7:ffff:fffe'}], 'gateway_ip': '396d:9050:426c:2670:3a97:dfc7:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '396d:9050:426c:2670:3a97:dfc7:0:2', 'tags': [], 'project_id': 'de3145a2ca04498ab020c243d6a7c24c'}} 2026-07-18 15:33:49,532 - INFO - Created VN ctest-vn4-14190598 2026-07-18 15:33:49,590 - DEBUG - VN ctest-vn4-14190598 UUID is 88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:49,831 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '88c45b32-8d59-4dfe-9705-39357c7cf7ea', 'name': 'ctest-vn4-14190598', 'tenant_id': 'de3145a2ca04498ab020c243d6a7c24c', 'project_id': 'de3145a2ca04498ab020c243d6a7c24c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['963586dd-007e-4f9c-a99b-9638207e6648', '2b6ce20d-4be8-4e13-99b9-2fb448c55d9c'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-97473189', 'ctest-vn4-14190598'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-97473189', 'ctest-policy1-59688432']], 'subnet_ipam': [{'subnet_cidr': '47.202.247.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '396d:9050:426c:2670:3a97:dfc7::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-07-18 15:33:49,990 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2026-07-18 15:33:50,333 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2026-07-18 15:33:50,368 - DEBUG - Requesting: http://10.0.0.242:8082/domain/e58a1f19-c2d3-440e-8eb2-eb82bf351285 2026-07-18 15:33:50,382 - DEBUG - Requesting: http://10.0.0.242:8082/project/de3145a2-ca04-498a-b020-c243d6a7c24c 2026-07-18 15:33:50,470 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,482 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,494 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:50,504 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:50,514 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/dfe49849-af47-43b7-9404-76416e0387dc 2026-07-18 15:33:50,524 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-07-18 15:33:50,525 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,536 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:50,555 - INFO - Verified VN network id 11 for VN 88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,555 - INFO - Verifications in API Server for VN ctest-vn4-14190598 passed 2026-07-18 15:33:50,555 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,568 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:50,579 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:50,588 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/dfe49849-af47-43b7-9404-76416e0387dc 2026-07-18 15:33:50,604 - DEBUG - Control-node 10.0.0.242 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-97473189', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '9855102157271420414', 'uuid-lslong': '10882166976495286250'}, 'enable': 'true', 'created': '2026-07-18T15:33:49', 'last-modified': '2026-07-18T15:33:49', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.825152'} 2026-07-18 15:33:50,612 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-07-18 15:33:50,612 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-14190598 passed 2026-07-18 15:33:50,613 - DEBUG - ====Verifying policy data for ctest-vn4-14190598 in API_Server ====== 2026-07-18 15:33:50,613 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2026-07-18 15:33:50,620 - DEBUG - Requesting: http://10.0.0.242:8082/domain/e58a1f19-c2d3-440e-8eb2-eb82bf351285 2026-07-18 15:33:50,634 - DEBUG - Requesting: http://10.0.0.242:8082/project/de3145a2-ca04-498a-b020-c243d6a7c24c 2026-07-18 15:33:50,722 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/88c45b32-8d59-4dfe-9705-39357c7cf7ea 2026-07-18 15:33:50,733 - DEBUG - ==>Verifying data for policy with id: a60f1ae8-7b43-4b9a-a408-6a750e4607db, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-97473189', 'ctest-policy1-59688432'] 2026-07-18 15:33:50,733 - INFO - VN ctest-vn4-14190598 Policy verification: verify_vn_policy_in_api_server, status: True 2026-07-18 15:33:50,733 - DEBUG - Verifying the vn in opserver 2026-07-18 15:33:50,733 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598 virtual network link through opserver 10.0.0.242 2026-07-18 15:33:50,734 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2026-07-18 15:33:51,068 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2026-07-18 15:33:51,448 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598', 'href': 'http://10.0.0.242:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598?flat'} 2026-07-18 15:33:51,448 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-97473189:ctest-vn4-14190598 is found in opserver 2026-07-18 15:33:51,459 - DEBUG - Do not have enough data to verify VN in agent 2026-07-18 15:33:51,464 - DEBUG - VRF ids for VN ctest-vn4-14190598: {} 2026-07-18 15:33:51,464 - DEBUG - ====Verifying data for ctest-policy1-59688432 in API_Server ====== 2026-07-18 15:33:51,464 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2026-07-18 15:33:51,471 - DEBUG - Requesting: http://10.0.0.242:8082/domain/e58a1f19-c2d3-440e-8eb2-eb82bf351285 2026-07-18 15:33:51,485 - DEBUG - Requesting: http://10.0.0.242:8082/project/de3145a2-ca04-498a-b020-c243d6a7c24c 2026-07-18 15:33:51,573 - DEBUG - Requesting: http://10.0.0.242:8082/network-policy/a60f1ae8-7b43-4b9a-a408-6a750e4607db 2026-07-18 15:33:51,584 - INFO - Verified policy ctest-policy1-59688432 in API Server, Result: True 2026-07-18 15:33:51,584 - INFO - Done with setup and verification, moving onto test .. 2026-07-18 15:33:51,595 - INFO - Deleting VN ctest-vn4-14190598 2026-07-18 15:33:51,755 - DEBUG - Response for deleting network () 2026-07-18 15:33:51,755 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/18c76f04-a145-4611-89b9-28a81525b369 2026-07-18 15:33:51,762 - DEBUG - Response Code: 404 2026-07-18 15:33:51,762 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2026-07-18 15:33:51,770 - DEBUG - Requesting: http://10.0.0.242:8082/domain/e58a1f19-c2d3-440e-8eb2-eb82bf351285 2026-07-18 15:33:51,827 - DEBUG - Requesting: http://10.0.0.242:8082/project/de3145a2-ca04-498a-b020-c243d6a7c24c 2026-07-18 15:33:51,907 - INFO - Validated that VN ctest-vn4-14190598 is not found in API Server 2026-07-18 15:33:51,921 - DEBUG - VN ctest-vn4-14190598 is not present in Agent 10.0.0.242 2026-07-18 15:33:51,921 - INFO - Validated that VN ctest-vn4-14190598 is not in any agent 2026-07-18 15:33:51,940 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-14190598 info 2026-07-18 15:33:51,970 - INFO - Deleted policy ctest-policy1-59688432 2026-07-18 15:33:52,142 - DEBUG - policy ctest-policy1-59688432 is not found in API Server 2026-07-18 15:33:52,401 - DEBUG - No XMPP flaps were noticed during the test 2026-07-18 15:33:52,401 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-07-18 15:33:52,401 - INFO - -------------------------------------------------------------------------------- 2026-07-18 15:33:52,709 - DEBUG - No XMPP flaps were noticed during the test 2026-07-18 15:33:52,709 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-07-18 15:33:52,709 - INFO - -------------------------------------------------------------------------------- 2026-07-18 15:33:53,475 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-97473189, ID : de3145a2-ca04-498a-b020-c243d6a7c24c