2026-02-02 16:52:34,929 - INFO - Domain Default found not creating 2026-02-02 16:52:35,080 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-95526403 not found, creating it 2026-02-02 16:52:35,535 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-95526403, ID : d67662c7-2c3e-4cd4-aba1-d347d25ab014 2026-02-02 16:52:36,929 - INFO - ================================================================================ 2026-02-02 16:52:36,929 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-02-02 16:52:37,185 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2026-02-02 16:52:37,185 - INFO - Initial checks done. Running the testcase now 2026-02-02 16:52:37,185 - INFO - 2026-02-02 16:52:37,185 - INFO - ================================================================================ 2026-02-02 16:52:37,185 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-02-02 16:52:37,185 - 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-02-02 16:52:37,472 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2026-02-02 16:52:37,472 - INFO - Initial checks done. Running the testcase now 2026-02-02 16:52:37,472 - INFO - 2026-02-02 16:52:37,815 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517, 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-95526403:ctest-vn4-02876517, 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-95526403:ctest-vn4-02876517, 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-95526403:ctest-vn4-02876517, 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-02-02 16:52:38,313 - DEBUG - Response for create_network : {'network': {'id': '74ef0329-2285-4519-9a2b-b32440cbc34c', 'name': 'ctest-vn4-02876517', 'tenant_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'project_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-95526403', 'ctest-vn4-02876517'], 'port_security_enabled': True, 'description': ''}} 2026-02-02 16:52:38,487 - DEBUG - Response for create_subnet : {'subnet': {'id': '96ab9408-a075-41c8-9dc8-135ef22373cf', 'name': '', 'tenant_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'network_id': '74ef0329-2285-4519-9a2b-b32440cbc34c', 'ip_version': 4, 'cidr': '95.218.158.64/26', 'allocation_pools': [{'start': '95.218.158.66', 'end': '95.218.158.126'}], 'gateway_ip': '95.218.158.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '95.218.158.66', 'tags': [], 'project_id': 'd67662c72c3e4cd4aba1d347d25ab014'}} 2026-02-02 16:52:38,683 - DEBUG - Response for create_subnet : {'subnet': {'id': '136bae5d-9d8c-4f70-9a9a-bbafa2fb5adf', 'name': '', 'tenant_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'network_id': '74ef0329-2285-4519-9a2b-b32440cbc34c', 'ip_version': 6, 'cidr': '2a51:74f4:8ed5:843b:61a0:c1a9::/96', 'allocation_pools': [{'start': '2a51:74f4:8ed5:843b:61a0:c1a9:0:2', 'end': '2a51:74f4:8ed5:843b:61a0:c1a9:ffff:fffe'}], 'gateway_ip': '2a51:74f4:8ed5:843b:61a0:c1a9:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2a51:74f4:8ed5:843b:61a0:c1a9:0:2', 'tags': [], 'project_id': 'd67662c72c3e4cd4aba1d347d25ab014'}} 2026-02-02 16:52:38,703 - INFO - Created VN ctest-vn4-02876517 2026-02-02 16:52:38,751 - DEBUG - VN ctest-vn4-02876517 UUID is 74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:38,983 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '74ef0329-2285-4519-9a2b-b32440cbc34c', 'name': 'ctest-vn4-02876517', 'tenant_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'project_id': 'd67662c72c3e4cd4aba1d347d25ab014', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['96ab9408-a075-41c8-9dc8-135ef22373cf', '136bae5d-9d8c-4f70-9a9a-bbafa2fb5adf'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-95526403', 'ctest-vn4-02876517'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-95526403', 'ctest-policy1-01516872']], 'subnet_ipam': [{'subnet_cidr': '95.218.158.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2a51:74f4:8ed5:843b:61a0:c1a9::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-02-02 16:52:39,143 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-02-02 16:52:39,450 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-02-02 16:52:39,482 - DEBUG - Requesting: http://10.0.0.38:8082/domain/cad9a506-2f0b-4656-8997-c3b8e9881859 2026-02-02 16:52:39,495 - DEBUG - Requesting: http://10.0.0.38:8082/project/d67662c7-2c3e-4cd4-aba1-d347d25ab014 2026-02-02 16:52:39,564 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,575 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,583 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:39,589 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:39,595 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/01b2ed34-56f9-4aca-b887-54edf5456824 2026-02-02 16:52:39,600 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-02-02 16:52:39,600 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,608 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:39,630 - INFO - Verified VN network id 11 for VN 74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,630 - INFO - Verifications in API Server for VN ctest-vn4-02876517 passed 2026-02-02 16:52:39,630 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,640 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:39,647 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:39,654 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/01b2ed34-56f9-4aca-b887-54edf5456824 2026-02-02 16:52:39,665 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-95526403', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '8425956903041189145', 'uuid-lslong': '11109169874126750540'}, 'enable': 'true', 'created': '2026-02-02T16:52:38', 'last-modified': '2026-02-02T16:52:38', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.756760'} 2026-02-02 16:52:39,671 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-02-02 16:52:39,671 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-02876517 passed 2026-02-02 16:52:39,671 - DEBUG - ====Verifying policy data for ctest-vn4-02876517 in API_Server ====== 2026-02-02 16:52:39,671 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-02-02 16:52:39,676 - DEBUG - Requesting: http://10.0.0.38:8082/domain/cad9a506-2f0b-4656-8997-c3b8e9881859 2026-02-02 16:52:39,685 - DEBUG - Requesting: http://10.0.0.38:8082/project/d67662c7-2c3e-4cd4-aba1-d347d25ab014 2026-02-02 16:52:39,755 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/74ef0329-2285-4519-9a2b-b32440cbc34c 2026-02-02 16:52:39,765 - DEBUG - ==>Verifying data for policy with id: 7944836c-b830-4fb2-aeef-4b60d4d26ad4, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-95526403', 'ctest-policy1-01516872'] 2026-02-02 16:52:39,765 - INFO - VN ctest-vn4-02876517 Policy verification: verify_vn_policy_in_api_server, status: True 2026-02-02 16:52:39,765 - DEBUG - Verifying the vn in opserver 2026-02-02 16:52:39,765 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517 virtual network link through opserver 10.0.0.38 2026-02-02 16:52:39,765 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-02-02 16:52:40,061 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-02-02 16:52:40,129 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517?flat'} 2026-02-02 16:52:40,129 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-95526403:ctest-vn4-02876517 is found in opserver 2026-02-02 16:52:40,140 - DEBUG - Do not have enough data to verify VN in agent 2026-02-02 16:52:40,145 - DEBUG - VRF ids for VN ctest-vn4-02876517: {} 2026-02-02 16:52:40,145 - DEBUG - ====Verifying data for ctest-policy1-01516872 in API_Server ====== 2026-02-02 16:52:40,145 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-02-02 16:52:40,150 - DEBUG - Requesting: http://10.0.0.38:8082/domain/cad9a506-2f0b-4656-8997-c3b8e9881859 2026-02-02 16:52:40,160 - DEBUG - Requesting: http://10.0.0.38:8082/project/d67662c7-2c3e-4cd4-aba1-d347d25ab014 2026-02-02 16:52:40,236 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/7944836c-b830-4fb2-aeef-4b60d4d26ad4 2026-02-02 16:52:40,245 - INFO - Verified policy ctest-policy1-01516872 in API Server, Result: True 2026-02-02 16:52:40,245 - INFO - Done with setup and verification, moving onto test .. 2026-02-02 16:52:40,253 - INFO - Deleting VN ctest-vn4-02876517 2026-02-02 16:52:40,357 - DEBUG - Response for deleting network () 2026-02-02 16:52:40,357 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/ee29ee8b-5968-4e36-b11d-c7a3d8571bad 2026-02-02 16:52:40,361 - DEBUG - Response Code: 404 2026-02-02 16:52:40,361 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-02-02 16:52:40,365 - DEBUG - Requesting: http://10.0.0.38:8082/domain/cad9a506-2f0b-4656-8997-c3b8e9881859 2026-02-02 16:52:40,415 - DEBUG - Requesting: http://10.0.0.38:8082/project/d67662c7-2c3e-4cd4-aba1-d347d25ab014 2026-02-02 16:52:40,482 - INFO - Validated that VN ctest-vn4-02876517 is not found in API Server 2026-02-02 16:52:40,491 - DEBUG - VN ctest-vn4-02876517 is not present in Agent 10.0.0.38 2026-02-02 16:52:40,491 - INFO - Validated that VN ctest-vn4-02876517 is not in any agent 2026-02-02 16:52:40,514 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-02876517 info 2026-02-02 16:52:40,538 - INFO - Deleted policy ctest-policy1-01516872 2026-02-02 16:52:40,699 - DEBUG - policy ctest-policy1-01516872 is not found in API Server 2026-02-02 16:52:40,959 - DEBUG - No XMPP flaps were noticed during the test 2026-02-02 16:52:40,960 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03] 2026-02-02 16:52:40,960 - INFO - -------------------------------------------------------------------------------- 2026-02-02 16:52:41,255 - DEBUG - No XMPP flaps were noticed during the test 2026-02-02 16:52:41,255 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-02-02 16:52:41,255 - INFO - -------------------------------------------------------------------------------- 2026-02-02 16:52:41,941 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-95526403, ID : d67662c7-2c3e-4cd4-aba1-d347d25ab014