2025-11-07 15:51:54,360 - INFO - Domain Default found not creating 2025-11-07 15:51:54,522 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-45597804 not found, creating it 2025-11-07 15:51:55,028 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-45597804, ID : 63d85bd7-6dd5-4135-b596-85b1f2d059b6 2025-11-07 15:51:56,515 - INFO - ================================================================================ 2025-11-07 15:51:56,515 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-07 15:51:56,772 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.18': '0'}} with 2025-11-07 15:51:56,772 - INFO - Initial checks done. Running the testcase now 2025-11-07 15:51:56,772 - INFO - 2025-11-07 15:51:56,772 - INFO - ================================================================================ 2025-11-07 15:51:56,772 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-07 15:51:56,772 - 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. 2025-11-07 15:51:57,063 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.18': '0'}} with 2025-11-07 15:51:57,064 - INFO - Initial checks done. Running the testcase now 2025-11-07 15:51:57,064 - INFO - 2025-11-07 15:51:57,430 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371, 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-45597804:ctest-vn4-83468371, 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-45597804:ctest-vn4-83468371, 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-45597804:ctest-vn4-83468371, 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] 2025-11-07 15:51:57,943 - DEBUG - Response for create_network : {'network': {'id': '21dc6c98-3be5-4ca8-9f76-526125cc5d86', 'name': 'ctest-vn4-83468371', 'tenant_id': '63d85bd76dd54135b59685b1f2d059b6', 'project_id': '63d85bd76dd54135b59685b1f2d059b6', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-45597804', 'ctest-vn4-83468371'], 'port_security_enabled': True, 'description': ''}} 2025-11-07 15:51:58,157 - DEBUG - Response for create_subnet : {'subnet': {'id': '60930212-1294-4ebc-b20a-fef546bab7da', 'name': '', 'tenant_id': '63d85bd76dd54135b59685b1f2d059b6', 'network_id': '21dc6c98-3be5-4ca8-9f76-526125cc5d86', 'ip_version': 4, 'cidr': '25.121.35.128/26', 'allocation_pools': [{'start': '25.121.35.130', 'end': '25.121.35.190'}], 'gateway_ip': '25.121.35.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '25.121.35.130', 'tags': [], 'project_id': '63d85bd76dd54135b59685b1f2d059b6'}} 2025-11-07 15:51:58,342 - DEBUG - Response for create_subnet : {'subnet': {'id': '7a37a677-8bca-4669-a502-c2c2962b8bd6', 'name': '', 'tenant_id': '63d85bd76dd54135b59685b1f2d059b6', 'network_id': '21dc6c98-3be5-4ca8-9f76-526125cc5d86', 'ip_version': 6, 'cidr': '34c8:6a74:29ca:34dd:8b6d:b773::/96', 'allocation_pools': [{'start': '34c8:6a74:29ca:34dd:8b6d:b773:0:2', 'end': '34c8:6a74:29ca:34dd:8b6d:b773:ffff:fffe'}], 'gateway_ip': '34c8:6a74:29ca:34dd:8b6d:b773:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '34c8:6a74:29ca:34dd:8b6d:b773:0:2', 'tags': [], 'project_id': '63d85bd76dd54135b59685b1f2d059b6'}} 2025-11-07 15:51:58,364 - INFO - Created VN ctest-vn4-83468371 2025-11-07 15:51:58,417 - DEBUG - VN ctest-vn4-83468371 UUID is 21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:58,628 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '21dc6c98-3be5-4ca8-9f76-526125cc5d86', 'name': 'ctest-vn4-83468371', 'tenant_id': '63d85bd76dd54135b59685b1f2d059b6', 'project_id': '63d85bd76dd54135b59685b1f2d059b6', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['60930212-1294-4ebc-b20a-fef546bab7da', '7a37a677-8bca-4669-a502-c2c2962b8bd6'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-45597804', 'ctest-vn4-83468371'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-45597804', 'ctest-policy1-80067894']], 'subnet_ipam': [{'subnet_cidr': '25.121.35.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '34c8:6a74:29ca:34dd:8b6d:b773::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-07 15:51:58,797 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-07 15:51:59,098 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-07 15:51:59,130 - DEBUG - Requesting: http://10.0.0.242:8082/domain/860d3f7d-0152-4986-8a9b-26dbb8901334 2025-11-07 15:51:59,144 - DEBUG - Requesting: http://10.0.0.242:8082/project/63d85bd7-6dd5-4135-b596-85b1f2d059b6 2025-11-07 15:51:59,219 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,233 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,243 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:51:59,251 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:51:59,258 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/4c3e20fb-6600-4b31-b1e2-1cb29407030a 2025-11-07 15:51:59,264 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-07 15:51:59,264 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,275 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:51:59,290 - INFO - Verified VN network id 11 for VN 21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,291 - INFO - Verifications in API Server for VN ctest-vn4-83468371 passed 2025-11-07 15:51:59,291 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,300 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:51:59,308 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:51:59,315 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/4c3e20fb-6600-4b31-b1e2-1cb29407030a 2025-11-07 15:51:59,327 - DEBUG - Control-node 10.0.0.242 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-45597804', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '2439944499223678120', 'uuid-lslong': '11490462076481854854'}, 'enable': 'true', 'created': '2025-11-07T15:51:57', 'last-modified': '2025-11-07T15:51:58', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.729603'} 2025-11-07 15:51:59,333 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-07 15:51:59,334 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-83468371 passed 2025-11-07 15:51:59,334 - DEBUG - ====Verifying policy data for ctest-vn4-83468371 in API_Server ====== 2025-11-07 15:51:59,334 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-07 15:51:59,339 - DEBUG - Requesting: http://10.0.0.242:8082/domain/860d3f7d-0152-4986-8a9b-26dbb8901334 2025-11-07 15:51:59,350 - DEBUG - Requesting: http://10.0.0.242:8082/project/63d85bd7-6dd5-4135-b596-85b1f2d059b6 2025-11-07 15:51:59,420 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21dc6c98-3be5-4ca8-9f76-526125cc5d86 2025-11-07 15:51:59,429 - DEBUG - ==>Verifying data for policy with id: 892fc650-9e47-4fdd-b82c-3c71b93e30bc, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-45597804', 'ctest-policy1-80067894'] 2025-11-07 15:51:59,429 - INFO - VN ctest-vn4-83468371 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-07 15:51:59,429 - DEBUG - Verifying the vn in opserver 2025-11-07 15:51:59,429 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371 virtual network link through opserver 10.0.0.242 2025-11-07 15:51:59,429 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-11-07 15:51:59,725 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-11-07 15:51:59,789 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371', 'href': 'http://10.0.0.242:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371?flat'} 2025-11-07 15:51:59,790 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-45597804:ctest-vn4-83468371 is found in opserver 2025-11-07 15:51:59,799 - DEBUG - Do not have enough data to verify VN in agent 2025-11-07 15:51:59,804 - DEBUG - VRF ids for VN ctest-vn4-83468371: {} 2025-11-07 15:51:59,805 - DEBUG - ====Verifying data for ctest-policy1-80067894 in API_Server ====== 2025-11-07 15:51:59,805 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-07 15:51:59,811 - DEBUG - Requesting: http://10.0.0.242:8082/domain/860d3f7d-0152-4986-8a9b-26dbb8901334 2025-11-07 15:51:59,823 - DEBUG - Requesting: http://10.0.0.242:8082/project/63d85bd7-6dd5-4135-b596-85b1f2d059b6 2025-11-07 15:51:59,897 - DEBUG - Requesting: http://10.0.0.242:8082/network-policy/892fc650-9e47-4fdd-b82c-3c71b93e30bc 2025-11-07 15:51:59,907 - INFO - Verified policy ctest-policy1-80067894 in API Server, Result: True 2025-11-07 15:51:59,907 - INFO - Done with setup and verification, moving onto test .. 2025-11-07 15:51:59,916 - INFO - Deleting VN ctest-vn4-83468371 2025-11-07 15:52:00,045 - DEBUG - Response for deleting network () 2025-11-07 15:52:00,045 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/9a909d23-7797-4c51-85d5-76aa22814bb7 2025-11-07 15:52:00,051 - DEBUG - Response Code: 404 2025-11-07 15:52:00,051 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-07 15:52:00,057 - DEBUG - Requesting: http://10.0.0.242:8082/domain/860d3f7d-0152-4986-8a9b-26dbb8901334 2025-11-07 15:52:00,112 - DEBUG - Requesting: http://10.0.0.242:8082/project/63d85bd7-6dd5-4135-b596-85b1f2d059b6 2025-11-07 15:52:00,186 - INFO - Validated that VN ctest-vn4-83468371 is not found in API Server 2025-11-07 15:52:00,196 - DEBUG - VN ctest-vn4-83468371 is not present in Agent 10.0.0.242 2025-11-07 15:52:00,196 - INFO - Validated that VN ctest-vn4-83468371 is not in any agent 2025-11-07 15:52:00,210 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-83468371 info 2025-11-07 15:52:00,237 - INFO - Deleted policy ctest-policy1-80067894 2025-11-07 15:52:00,409 - DEBUG - policy ctest-policy1-80067894 is not found in API Server 2025-11-07 15:52:00,667 - DEBUG - No XMPP flaps were noticed during the test 2025-11-07 15:52:00,667 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-11-07 15:52:00,667 - INFO - -------------------------------------------------------------------------------- 2025-11-07 15:52:00,966 - DEBUG - No XMPP flaps were noticed during the test 2025-11-07 15:52:00,966 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-11-07 15:52:00,966 - INFO - -------------------------------------------------------------------------------- 2025-11-07 15:52:01,687 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-45597804, ID : 63d85bd7-6dd5-4135-b596-85b1f2d059b6