2026-08-15 18:56:18,619 - INFO - Domain Default found not creating 2026-08-15 18:56:18,808 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-94439286 not found, creating it 2026-08-15 18:56:19,313 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-94439286, ID : 2bc78101-fa38-47fd-9b41-fd80cbfa6301 2026-08-15 18:56:21,100 - INFO - ================================================================================ 2026-08-15 18:56:21,100 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-08-15 18:56:21,371 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.25': '0'}} with 2026-08-15 18:56:21,371 - INFO - Initial checks done. Running the testcase now 2026-08-15 18:56:21,371 - INFO - 2026-08-15 18:56:21,372 - INFO - ================================================================================ 2026-08-15 18:56:21,372 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-08-15 18:56:21,372 - 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-08-15 18:56:21,658 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.25': '0'}} with 2026-08-15 18:56:21,658 - INFO - Initial checks done. Running the testcase now 2026-08-15 18:56:21,658 - INFO - 2026-08-15 18:56:22,098 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332, 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-94439286:ctest-vn4-18295332, 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-94439286:ctest-vn4-18295332, 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-94439286:ctest-vn4-18295332, 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-08-15 18:56:22,641 - DEBUG - Response for create_network : {'network': {'id': '44d12fe5-dab4-49fe-a253-078a288eadfe', 'name': 'ctest-vn4-18295332', 'tenant_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'project_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-94439286', 'ctest-vn4-18295332'], 'port_security_enabled': True, 'description': ''}} 2026-08-15 18:56:22,877 - DEBUG - Response for create_subnet : {'subnet': {'id': '106224bd-a019-408d-9262-c57df40d902c', 'name': '', 'tenant_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'network_id': '44d12fe5-dab4-49fe-a253-078a288eadfe', 'ip_version': 4, 'cidr': '176.28.209.128/26', 'allocation_pools': [{'start': '176.28.209.130', 'end': '176.28.209.190'}], 'gateway_ip': '176.28.209.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '176.28.209.130', 'tags': [], 'project_id': '2bc78101fa3847fd9b41fd80cbfa6301'}} 2026-08-15 18:56:23,069 - DEBUG - Response for create_subnet : {'subnet': {'id': '09cdf647-3668-4da1-b7f2-b77d8d1b14c0', 'name': '', 'tenant_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'network_id': '44d12fe5-dab4-49fe-a253-078a288eadfe', 'ip_version': 6, 'cidr': '333a:d22:5413:e35c:5cf5:33b9::/96', 'allocation_pools': [{'start': '333a:d22:5413:e35c:5cf5:33b9:0:2', 'end': '333a:d22:5413:e35c:5cf5:33b9:ffff:fffe'}], 'gateway_ip': '333a:d22:5413:e35c:5cf5:33b9:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '333a:d22:5413:e35c:5cf5:33b9:0:2', 'tags': [], 'project_id': '2bc78101fa3847fd9b41fd80cbfa6301'}} 2026-08-15 18:56:23,089 - INFO - Created VN ctest-vn4-18295332 2026-08-15 18:56:23,142 - DEBUG - VN ctest-vn4-18295332 UUID is 44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:23,355 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '44d12fe5-dab4-49fe-a253-078a288eadfe', 'name': 'ctest-vn4-18295332', 'tenant_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'project_id': '2bc78101fa3847fd9b41fd80cbfa6301', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['106224bd-a019-408d-9262-c57df40d902c', '09cdf647-3668-4da1-b7f2-b77d8d1b14c0'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-94439286', 'ctest-vn4-18295332'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-94439286', 'ctest-policy1-86738379']], 'subnet_ipam': [{'subnet_cidr': '176.28.209.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '333a:d22:5413:e35c:5cf5:33b9::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-08-15 18:56:23,535 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-08-15 18:56:23,906 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-08-15 18:56:23,936 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fa38431f-7b93-4bdd-9e30-dca925d43c77 2026-08-15 18:56:23,951 - DEBUG - Requesting: http://10.0.0.38:8082/project/2bc78101-fa38-47fd-9b41-fd80cbfa6301 2026-08-15 18:56:24,040 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,054 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,066 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:24,076 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:24,083 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/068690cb-ad60-4f6f-9ae2-5aa844f843e5 2026-08-15 18:56:24,091 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-08-15 18:56:24,091 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,102 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:24,118 - INFO - Verified VN network id 11 for VN 44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,118 - INFO - Verifications in API Server for VN ctest-vn4-18295332 passed 2026-08-15 18:56:24,118 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,129 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:24,138 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:24,146 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/068690cb-ad60-4f6f-9ae2-5aa844f843e5 2026-08-15 18:56:24,161 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-94439286', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '4958797328974891518', 'uuid-lslong': '11696700947178630654'}, 'enable': 'true', 'created': '2026-08-15T18:56:22', 'last-modified': '2026-08-15T18:56:23', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.833133'} 2026-08-15 18:56:24,169 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-08-15 18:56:24,169 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-18295332 passed 2026-08-15 18:56:24,170 - DEBUG - ====Verifying policy data for ctest-vn4-18295332 in API_Server ====== 2026-08-15 18:56:24,170 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-08-15 18:56:24,176 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fa38431f-7b93-4bdd-9e30-dca925d43c77 2026-08-15 18:56:24,187 - DEBUG - Requesting: http://10.0.0.38:8082/project/2bc78101-fa38-47fd-9b41-fd80cbfa6301 2026-08-15 18:56:24,266 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/44d12fe5-dab4-49fe-a253-078a288eadfe 2026-08-15 18:56:24,277 - DEBUG - ==>Verifying data for policy with id: 4e47704f-b920-41ba-a996-1ce52ec29e02, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-94439286', 'ctest-policy1-86738379'] 2026-08-15 18:56:24,277 - INFO - VN ctest-vn4-18295332 Policy verification: verify_vn_policy_in_api_server, status: True 2026-08-15 18:56:24,277 - DEBUG - Verifying the vn in opserver 2026-08-15 18:56:24,277 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332 virtual network link through opserver 10.0.0.38 2026-08-15 18:56:24,277 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-08-15 18:56:24,652 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-08-15 18:56:24,719 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332?flat'} 2026-08-15 18:56:24,719 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-94439286:ctest-vn4-18295332 is found in opserver 2026-08-15 18:56:24,731 - DEBUG - Do not have enough data to verify VN in agent 2026-08-15 18:56:24,737 - DEBUG - VRF ids for VN ctest-vn4-18295332: {} 2026-08-15 18:56:24,737 - DEBUG - ====Verifying data for ctest-policy1-86738379 in API_Server ====== 2026-08-15 18:56:24,737 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-08-15 18:56:24,744 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fa38431f-7b93-4bdd-9e30-dca925d43c77 2026-08-15 18:56:24,758 - DEBUG - Requesting: http://10.0.0.38:8082/project/2bc78101-fa38-47fd-9b41-fd80cbfa6301 2026-08-15 18:56:24,839 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/4e47704f-b920-41ba-a996-1ce52ec29e02 2026-08-15 18:56:24,852 - INFO - Verified policy ctest-policy1-86738379 in API Server, Result: True 2026-08-15 18:56:24,852 - INFO - Done with setup and verification, moving onto test .. 2026-08-15 18:56:24,863 - INFO - Deleting VN ctest-vn4-18295332 2026-08-15 18:56:25,011 - DEBUG - Response for deleting network () 2026-08-15 18:56:25,012 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bcc382c4-7b3a-4b59-a1cd-64816381d0a3 2026-08-15 18:56:25,017 - DEBUG - Response Code: 404 2026-08-15 18:56:25,017 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-08-15 18:56:25,023 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fa38431f-7b93-4bdd-9e30-dca925d43c77 2026-08-15 18:56:25,077 - DEBUG - Requesting: http://10.0.0.38:8082/project/2bc78101-fa38-47fd-9b41-fd80cbfa6301 2026-08-15 18:56:25,157 - INFO - Validated that VN ctest-vn4-18295332 is not found in API Server 2026-08-15 18:56:25,170 - DEBUG - VN ctest-vn4-18295332 is not present in Agent 10.0.0.38 2026-08-15 18:56:25,170 - INFO - Validated that VN ctest-vn4-18295332 is not in any agent 2026-08-15 18:56:25,187 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-18295332 info 2026-08-15 18:56:25,216 - INFO - Deleted policy ctest-policy1-86738379 2026-08-15 18:56:25,390 - DEBUG - policy ctest-policy1-86738379 is not found in API Server 2026-08-15 18:56:25,649 - DEBUG - No XMPP flaps were noticed during the test 2026-08-15 18:56:25,649 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-08-15 18:56:25,649 - INFO - -------------------------------------------------------------------------------- 2026-08-15 18:56:25,951 - DEBUG - No XMPP flaps were noticed during the test 2026-08-15 18:56:25,951 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-08-15 18:56:25,951 - INFO - -------------------------------------------------------------------------------- 2026-08-15 18:56:26,748 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-94439286, ID : 2bc78101-fa38-47fd-9b41-fd80cbfa6301