2026-03-18 20:31:05,037 - INFO - Domain Default found not creating 2026-03-18 20:31:05,235 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-65230341 not found, creating it 2026-03-18 20:31:05,706 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-65230341, ID : 5a7a0b22-608c-4b73-a85f-30f911f840d4 2026-03-18 20:31:07,238 - INFO - ================================================================================ 2026-03-18 20:31:07,238 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-03-18 20:31:07,495 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-03-18 20:31:07,496 - INFO - Initial checks done. Running the testcase now 2026-03-18 20:31:07,496 - INFO - 2026-03-18 20:31:07,496 - INFO - ================================================================================ 2026-03-18 20:31:07,496 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-03-18 20:31:07,496 - 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-03-18 20:31:07,786 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-03-18 20:31:07,786 - INFO - Initial checks done. Running the testcase now 2026-03-18 20:31:07,787 - INFO - 2026-03-18 20:31:08,155 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763, 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-65230341:ctest-vn4-67264763, 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-65230341:ctest-vn4-67264763, 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-65230341:ctest-vn4-67264763, 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-03-18 20:31:08,684 - DEBUG - Response for create_network : {'network': {'id': '5172d6d0-ac79-44cc-b2c7-05d0421ebe63', 'name': 'ctest-vn4-67264763', 'tenant_id': '5a7a0b22608c4b73a85f30f911f840d4', 'project_id': '5a7a0b22608c4b73a85f30f911f840d4', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-65230341', 'ctest-vn4-67264763'], 'port_security_enabled': True, 'description': ''}} 2026-03-18 20:31:08,852 - DEBUG - Response for create_subnet : {'subnet': {'id': '9051ec40-e70e-46ce-914b-70ba78843011', 'name': '', 'tenant_id': '5a7a0b22608c4b73a85f30f911f840d4', 'network_id': '5172d6d0-ac79-44cc-b2c7-05d0421ebe63', 'ip_version': 4, 'cidr': '8.73.132.128/26', 'allocation_pools': [{'start': '8.73.132.130', 'end': '8.73.132.190'}], 'gateway_ip': '8.73.132.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '8.73.132.130', 'tags': [], 'project_id': '5a7a0b22608c4b73a85f30f911f840d4'}} 2026-03-18 20:31:09,073 - DEBUG - Response for create_subnet : {'subnet': {'id': '84c1d70c-8467-406e-afb4-d4aa717e9825', 'name': '', 'tenant_id': '5a7a0b22608c4b73a85f30f911f840d4', 'network_id': '5172d6d0-ac79-44cc-b2c7-05d0421ebe63', 'ip_version': 6, 'cidr': '3219:2c72:fd84:4013:d79e:62b6::/96', 'allocation_pools': [{'start': '3219:2c72:fd84:4013:d79e:62b6:0:2', 'end': '3219:2c72:fd84:4013:d79e:62b6:ffff:fffe'}], 'gateway_ip': '3219:2c72:fd84:4013:d79e:62b6:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3219:2c72:fd84:4013:d79e:62b6:0:2', 'tags': [], 'project_id': '5a7a0b22608c4b73a85f30f911f840d4'}} 2026-03-18 20:31:09,097 - INFO - Created VN ctest-vn4-67264763 2026-03-18 20:31:09,154 - DEBUG - VN ctest-vn4-67264763 UUID is 5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:09,381 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5172d6d0-ac79-44cc-b2c7-05d0421ebe63', 'name': 'ctest-vn4-67264763', 'tenant_id': '5a7a0b22608c4b73a85f30f911f840d4', 'project_id': '5a7a0b22608c4b73a85f30f911f840d4', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['9051ec40-e70e-46ce-914b-70ba78843011', '84c1d70c-8467-406e-afb4-d4aa717e9825'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-65230341', 'ctest-vn4-67264763'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-65230341', 'ctest-policy1-10445609']], 'subnet_ipam': [{'subnet_cidr': '8.73.132.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3219:2c72:fd84:4013:d79e:62b6::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-03-18 20:31:09,554 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-03-18 20:31:09,851 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-03-18 20:31:09,887 - DEBUG - Requesting: http://10.0.0.38:8082/domain/121fb3cc-4567-4db5-ab71-cfd9b23a5e3b 2026-03-18 20:31:09,902 - DEBUG - Requesting: http://10.0.0.38:8082/project/5a7a0b22-608c-4b73-a85f-30f911f840d4 2026-03-18 20:31:09,978 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:09,994 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:10,007 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,016 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,024 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/d6915b80-7851-4cbc-8dae-c30ef90b39c1 2026-03-18 20:31:10,031 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-03-18 20:31:10,031 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:10,042 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,059 - INFO - Verified VN network id 11 for VN 5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:10,059 - INFO - Verifications in API Server for VN ctest-vn4-67264763 passed 2026-03-18 20:31:10,059 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:10,069 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,077 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,084 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/d6915b80-7851-4cbc-8dae-c30ef90b39c1 2026-03-18 20:31:10,097 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-65230341', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '5868989456152347852', 'uuid-lslong': '12882271651137240675'}, 'enable': 'true', 'created': '2026-03-18T20:31:08', 'last-modified': '2026-03-18T20:31:09', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.748655'} 2026-03-18 20:31:10,104 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-03-18 20:31:10,104 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-67264763 passed 2026-03-18 20:31:10,105 - DEBUG - ====Verifying policy data for ctest-vn4-67264763 in API_Server ====== 2026-03-18 20:31:10,105 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-03-18 20:31:10,111 - DEBUG - Requesting: http://10.0.0.38:8082/domain/121fb3cc-4567-4db5-ab71-cfd9b23a5e3b 2026-03-18 20:31:10,122 - DEBUG - Requesting: http://10.0.0.38:8082/project/5a7a0b22-608c-4b73-a85f-30f911f840d4 2026-03-18 20:31:10,198 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/5172d6d0-ac79-44cc-b2c7-05d0421ebe63 2026-03-18 20:31:10,211 - DEBUG - ==>Verifying data for policy with id: 60c2950f-9334-450b-b052-b24a08b9a4c5, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-65230341', 'ctest-policy1-10445609'] 2026-03-18 20:31:10,211 - INFO - VN ctest-vn4-67264763 Policy verification: verify_vn_policy_in_api_server, status: True 2026-03-18 20:31:10,211 - DEBUG - Verifying the vn in opserver 2026-03-18 20:31:10,211 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763 virtual network link through opserver 10.0.0.38 2026-03-18 20:31:10,212 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-03-18 20:31:10,528 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-03-18 20:31:10,601 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763?flat'} 2026-03-18 20:31:10,601 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-65230341:ctest-vn4-67264763 is found in opserver 2026-03-18 20:31:10,613 - DEBUG - Do not have enough data to verify VN in agent 2026-03-18 20:31:10,618 - DEBUG - VRF ids for VN ctest-vn4-67264763: {} 2026-03-18 20:31:10,618 - DEBUG - ====Verifying data for ctest-policy1-10445609 in API_Server ====== 2026-03-18 20:31:10,618 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-03-18 20:31:10,624 - DEBUG - Requesting: http://10.0.0.38:8082/domain/121fb3cc-4567-4db5-ab71-cfd9b23a5e3b 2026-03-18 20:31:10,635 - DEBUG - Requesting: http://10.0.0.38:8082/project/5a7a0b22-608c-4b73-a85f-30f911f840d4 2026-03-18 20:31:10,704 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/60c2950f-9334-450b-b052-b24a08b9a4c5 2026-03-18 20:31:10,713 - INFO - Verified policy ctest-policy1-10445609 in API Server, Result: True 2026-03-18 20:31:10,713 - INFO - Done with setup and verification, moving onto test .. 2026-03-18 20:31:10,722 - INFO - Deleting VN ctest-vn4-67264763 2026-03-18 20:31:10,846 - DEBUG - Response for deleting network () 2026-03-18 20:31:10,846 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6249d69e-3feb-42fe-b4d9-017bc52ae81e 2026-03-18 20:31:10,851 - DEBUG - Response Code: 404 2026-03-18 20:31:10,851 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-03-18 20:31:10,856 - DEBUG - Requesting: http://10.0.0.38:8082/domain/121fb3cc-4567-4db5-ab71-cfd9b23a5e3b 2026-03-18 20:31:10,919 - DEBUG - Requesting: http://10.0.0.38:8082/project/5a7a0b22-608c-4b73-a85f-30f911f840d4 2026-03-18 20:31:10,987 - INFO - Validated that VN ctest-vn4-67264763 is not found in API Server 2026-03-18 20:31:10,998 - DEBUG - VN ctest-vn4-67264763 is not present in Agent 10.0.0.38 2026-03-18 20:31:10,999 - INFO - Validated that VN ctest-vn4-67264763 is not in any agent 2026-03-18 20:31:11,015 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-67264763 info 2026-03-18 20:31:11,038 - INFO - Deleted policy ctest-policy1-10445609 2026-03-18 20:31:11,205 - DEBUG - policy ctest-policy1-10445609 is not found in API Server 2026-03-18 20:31:11,459 - DEBUG - No XMPP flaps were noticed during the test 2026-03-18 20:31:11,459 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-03-18 20:31:11,459 - INFO - -------------------------------------------------------------------------------- 2026-03-18 20:31:11,747 - DEBUG - No XMPP flaps were noticed during the test 2026-03-18 20:31:11,747 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-03-18 20:31:11,747 - INFO - -------------------------------------------------------------------------------- 2026-03-18 20:31:12,467 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-65230341, ID : 5a7a0b22-608c-4b73-a85f-30f911f840d4