2026-08-17 15:43:57,361 - INFO - Domain Default found not creating 2026-08-17 15:43:57,522 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-10760304 not found, creating it 2026-08-17 15:43:58,017 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-10760304, ID : 34c93512-42b9-45ba-a73f-e0dd923ac567 2026-08-17 15:43:59,687 - INFO - ================================================================================ 2026-08-17 15:43:59,687 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-08-17 15:43:59,948 - DEBUG - Nothing to compare xmpp stats {'10.0.0.177': {'10.20.0.17': '0'}} with 2026-08-17 15:43:59,948 - INFO - Initial checks done. Running the testcase now 2026-08-17 15:43:59,948 - INFO - 2026-08-17 15:43:59,948 - INFO - ================================================================================ 2026-08-17 15:43:59,948 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-08-17 15:43:59,948 - 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-17 15:44:00,252 - DEBUG - Nothing to compare xmpp stats {'10.0.0.177': {'10.20.0.17': '0'}} with 2026-08-17 15:44:00,252 - INFO - Initial checks done. Running the testcase now 2026-08-17 15:44:00,252 - INFO - 2026-08-17 15:44:00,692 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157, 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-10760304:ctest-vn4-10390157, 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-10760304:ctest-vn4-10390157, 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-10760304:ctest-vn4-10390157, 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-17 15:44:01,255 - DEBUG - Response for create_network : {'network': {'id': '5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2', 'name': 'ctest-vn4-10390157', 'tenant_id': '34c9351242b945baa73fe0dd923ac567', 'project_id': '34c9351242b945baa73fe0dd923ac567', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10760304', 'ctest-vn4-10390157'], 'port_security_enabled': True, 'description': ''}} 2026-08-17 15:44:01,448 - DEBUG - Response for create_subnet : {'subnet': {'id': 'f8d9e6ca-ac25-412c-b6f3-a87270eca95f', 'name': '', 'tenant_id': '34c9351242b945baa73fe0dd923ac567', 'network_id': '5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2', 'ip_version': 4, 'cidr': '217.174.136.128/26', 'allocation_pools': [{'start': '217.174.136.130', 'end': '217.174.136.190'}], 'gateway_ip': '217.174.136.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '217.174.136.130', 'tags': [], 'project_id': '34c9351242b945baa73fe0dd923ac567'}} 2026-08-17 15:44:01,663 - DEBUG - Response for create_subnet : {'subnet': {'id': '738bc44a-198a-4fa8-9349-6d9ff5eedbe1', 'name': '', 'tenant_id': '34c9351242b945baa73fe0dd923ac567', 'network_id': '5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2', 'ip_version': 6, 'cidr': '24de:d13d:748d:ae5e:6b27:7064::/96', 'allocation_pools': [{'start': '24de:d13d:748d:ae5e:6b27:7064:0:2', 'end': '24de:d13d:748d:ae5e:6b27:7064:ffff:fffe'}], 'gateway_ip': '24de:d13d:748d:ae5e:6b27:7064:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '24de:d13d:748d:ae5e:6b27:7064:0:2', 'tags': [], 'project_id': '34c9351242b945baa73fe0dd923ac567'}} 2026-08-17 15:44:01,685 - INFO - Created VN ctest-vn4-10390157 2026-08-17 15:44:01,738 - DEBUG - VN ctest-vn4-10390157 UUID is 5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:01,980 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2', 'name': 'ctest-vn4-10390157', 'tenant_id': '34c9351242b945baa73fe0dd923ac567', 'project_id': '34c9351242b945baa73fe0dd923ac567', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['f8d9e6ca-ac25-412c-b6f3-a87270eca95f', '738bc44a-198a-4fa8-9349-6d9ff5eedbe1'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10760304', 'ctest-vn4-10390157'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10760304', 'ctest-policy1-28448881']], 'subnet_ipam': [{'subnet_cidr': '217.174.136.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '24de:d13d:748d:ae5e:6b27:7064::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-08-17 15:44:02,159 - DEBUG - Requesting: http://10.0.0.177:8082/domains 2026-08-17 15:44:02,530 - DEBUG - Requesting: http://10.0.0.177:8082/domains 2026-08-17 15:44:02,564 - DEBUG - Requesting: http://10.0.0.177:8082/domain/46c0095c-2264-4754-b399-bc719d178f53 2026-08-17 15:44:02,577 - DEBUG - Requesting: http://10.0.0.177:8082/project/34c93512-42b9-45ba-a73f-e0dd923ac567 2026-08-17 15:44:02,663 - DEBUG - Requesting: http://10.0.0.177:8082/virtual-network/5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,677 - DEBUG - Requesting: http://10.0.0.177:8082/virtual-network/5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,688 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:02,697 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:02,704 - DEBUG - Requesting: http://10.0.0.177:8082/route-target/aad21c73-1ab4-4deb-8680-4e49891b6643 2026-08-17 15:44:02,713 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-08-17 15:44:02,713 - DEBUG - Requesting: http://10.0.0.177:8082/virtual-network/5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,724 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:02,741 - INFO - Verified VN network id 11 for VN 5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,741 - INFO - Verifications in API Server for VN ctest-vn4-10390157 passed 2026-08-17 15:44:02,741 - DEBUG - Requesting: http://10.0.0.177:8082/virtual-network/5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,752 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:02,759 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:02,766 - DEBUG - Requesting: http://10.0.0.177:8082/route-target/aad21c73-1ab4-4deb-8680-4e49891b6643 2026-08-17 15:44:02,782 - DEBUG - Control-node 10.0.0.177 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-10760304', 'owner-access': '7', 'group': 'manager', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '6904213649490857437', 'uuid-lslong': '13225617272652906738'}, 'enable': 'true', 'created': '2026-08-17T15:44:01', 'last-modified': '2026-08-17T15:44:01', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.840034'} 2026-08-17 15:44:02,790 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-08-17 15:44:02,790 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-10390157 passed 2026-08-17 15:44:02,791 - DEBUG - ====Verifying policy data for ctest-vn4-10390157 in API_Server ====== 2026-08-17 15:44:02,791 - DEBUG - Requesting: http://10.0.0.177:8082/domains 2026-08-17 15:44:02,798 - DEBUG - Requesting: http://10.0.0.177:8082/domain/46c0095c-2264-4754-b399-bc719d178f53 2026-08-17 15:44:02,811 - DEBUG - Requesting: http://10.0.0.177:8082/project/34c93512-42b9-45ba-a73f-e0dd923ac567 2026-08-17 15:44:02,885 - DEBUG - Requesting: http://10.0.0.177:8082/virtual-network/5fd0b1bb-ef4e-4ddd-b78a-d4d64fbf40f2 2026-08-17 15:44:02,896 - DEBUG - ==>Verifying data for policy with id: 4254ac62-4f1b-462a-b6ac-aeeaa2bb0047, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10760304', 'ctest-policy1-28448881'] 2026-08-17 15:44:02,896 - INFO - VN ctest-vn4-10390157 Policy verification: verify_vn_policy_in_api_server, status: True 2026-08-17 15:44:02,896 - DEBUG - Verifying the vn in opserver 2026-08-17 15:44:02,896 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157 virtual network link through opserver 10.0.0.177 2026-08-17 15:44:02,896 - DEBUG - Requesting: http://10.0.0.177:8081/analytics/uves/virtual-networks 2026-08-17 15:44:03,272 - DEBUG - Requesting: http://10.0.0.177:8081/analytics/uves/virtual-networks 2026-08-17 15:44:03,332 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157', 'href': 'http://10.0.0.177:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157?flat'} 2026-08-17 15:44:03,332 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10760304:ctest-vn4-10390157 is found in opserver 2026-08-17 15:44:03,344 - DEBUG - Do not have enough data to verify VN in agent 2026-08-17 15:44:03,350 - DEBUG - VRF ids for VN ctest-vn4-10390157: {} 2026-08-17 15:44:03,350 - DEBUG - ====Verifying data for ctest-policy1-28448881 in API_Server ====== 2026-08-17 15:44:03,351 - DEBUG - Requesting: http://10.0.0.177:8082/domains 2026-08-17 15:44:03,359 - DEBUG - Requesting: http://10.0.0.177:8082/domain/46c0095c-2264-4754-b399-bc719d178f53 2026-08-17 15:44:03,370 - DEBUG - Requesting: http://10.0.0.177:8082/project/34c93512-42b9-45ba-a73f-e0dd923ac567 2026-08-17 15:44:03,452 - DEBUG - Requesting: http://10.0.0.177:8082/network-policy/4254ac62-4f1b-462a-b6ac-aeeaa2bb0047 2026-08-17 15:44:03,465 - INFO - Verified policy ctest-policy1-28448881 in API Server, Result: True 2026-08-17 15:44:03,465 - INFO - Done with setup and verification, moving onto test .. 2026-08-17 15:44:03,476 - INFO - Deleting VN ctest-vn4-10390157 2026-08-17 15:44:03,608 - DEBUG - Response for deleting network () 2026-08-17 15:44:03,608 - DEBUG - Requesting: http://10.0.0.177:8082/routing-instance/a8e9e5ec-44bd-484f-8645-348b9d7737ea 2026-08-17 15:44:03,614 - DEBUG - Response Code: 404 2026-08-17 15:44:03,614 - DEBUG - Requesting: http://10.0.0.177:8082/domains 2026-08-17 15:44:03,619 - DEBUG - Requesting: http://10.0.0.177:8082/domain/46c0095c-2264-4754-b399-bc719d178f53 2026-08-17 15:44:03,672 - DEBUG - Requesting: http://10.0.0.177:8082/project/34c93512-42b9-45ba-a73f-e0dd923ac567 2026-08-17 15:44:03,747 - INFO - Validated that VN ctest-vn4-10390157 is not found in API Server 2026-08-17 15:44:03,762 - DEBUG - VN ctest-vn4-10390157 is not present in Agent 10.0.0.177 2026-08-17 15:44:03,762 - INFO - Validated that VN ctest-vn4-10390157 is not in any agent 2026-08-17 15:44:03,803 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-10390157 info 2026-08-17 15:44:03,853 - INFO - Deleted policy ctest-policy1-28448881 2026-08-17 15:44:04,026 - DEBUG - policy ctest-policy1-28448881 is not found in API Server 2026-08-17 15:44:04,296 - DEBUG - No XMPP flaps were noticed during the test 2026-08-17 15:44:04,296 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-08-17 15:44:04,296 - INFO - -------------------------------------------------------------------------------- 2026-08-17 15:44:04,593 - DEBUG - No XMPP flaps were noticed during the test 2026-08-17 15:44:04,593 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-08-17 15:44:04,593 - INFO - -------------------------------------------------------------------------------- 2026-08-17 15:44:05,382 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-10760304, ID : 34c93512-42b9-45ba-a73f-e0dd923ac567