2025-08-11 16:47:55,717 - INFO - Domain Default found not creating 2025-08-11 16:47:55,837 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-80380693 not found, creating it 2025-08-11 16:47:56,339 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-80380693, ID : db45b9bd-e521-4aac-89c1-4d44a3653e82 2025-08-11 16:47:57,619 - INFO - ================================================================================ 2025-08-11 16:47:57,619 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-11 16:47:57,869 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.254': '0'}} with 2025-08-11 16:47:57,869 - INFO - Initial checks done. Running the testcase now 2025-08-11 16:47:57,869 - INFO - 2025-08-11 16:47:57,869 - INFO - ================================================================================ 2025-08-11 16:47:57,869 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-11 16:47:57,869 - 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-08-11 16:47:58,156 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.254': '0'}} with 2025-08-11 16:47:58,156 - INFO - Initial checks done. Running the testcase now 2025-08-11 16:47:58,156 - INFO - 2025-08-11 16:47:58,493 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732, 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-80380693:ctest-vn4-59679732, 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-80380693:ctest-vn4-59679732, 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-80380693:ctest-vn4-59679732, 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-08-11 16:47:58,986 - DEBUG - Response for create_network : {'network': {'id': '62ed3e71-63d6-41f2-b40e-42bd510f5017', 'name': 'ctest-vn4-59679732', 'tenant_id': 'db45b9bde5214aac89c14d44a3653e82', 'project_id': 'db45b9bde5214aac89c14d44a3653e82', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-80380693', 'ctest-vn4-59679732'], 'port_security_enabled': True, 'description': ''}} 2025-08-11 16:47:59,168 - DEBUG - Response for create_subnet : {'subnet': {'id': 'ee454d3f-6827-4296-a86c-bb3747669770', 'name': '', 'tenant_id': 'db45b9bde5214aac89c14d44a3653e82', 'network_id': '62ed3e71-63d6-41f2-b40e-42bd510f5017', 'ip_version': 4, 'cidr': '29.10.199.128/26', 'allocation_pools': [{'start': '29.10.199.130', 'end': '29.10.199.190'}], 'gateway_ip': '29.10.199.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '29.10.199.130', 'tags': [], 'project_id': 'db45b9bde5214aac89c14d44a3653e82'}} 2025-08-11 16:47:59,362 - DEBUG - Response for create_subnet : {'subnet': {'id': 'd9588ff6-198d-4440-9555-7288c150fe41', 'name': '', 'tenant_id': 'db45b9bde5214aac89c14d44a3653e82', 'network_id': '62ed3e71-63d6-41f2-b40e-42bd510f5017', 'ip_version': 6, 'cidr': '2a7a:4b4b:fb31:7ad5:6a81:f5d4::/96', 'allocation_pools': [{'start': '2a7a:4b4b:fb31:7ad5:6a81:f5d4:0:2', 'end': '2a7a:4b4b:fb31:7ad5:6a81:f5d4:ffff:fffe'}], 'gateway_ip': '2a7a:4b4b:fb31:7ad5:6a81:f5d4:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2a7a:4b4b:fb31:7ad5:6a81:f5d4:0:2', 'tags': [], 'project_id': 'db45b9bde5214aac89c14d44a3653e82'}} 2025-08-11 16:47:59,378 - INFO - Created VN ctest-vn4-59679732 2025-08-11 16:47:59,427 - DEBUG - VN ctest-vn4-59679732 UUID is 62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:47:59,618 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '62ed3e71-63d6-41f2-b40e-42bd510f5017', 'name': 'ctest-vn4-59679732', 'tenant_id': 'db45b9bde5214aac89c14d44a3653e82', 'project_id': 'db45b9bde5214aac89c14d44a3653e82', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['ee454d3f-6827-4296-a86c-bb3747669770', 'd9588ff6-198d-4440-9555-7288c150fe41'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-80380693', 'ctest-vn4-59679732'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-80380693', 'ctest-policy1-77492132']], 'subnet_ipam': [{'subnet_cidr': '29.10.199.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2a7a:4b4b:fb31:7ad5:6a81:f5d4::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-11 16:47:59,787 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-08-11 16:48:00,074 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-08-11 16:48:00,099 - DEBUG - Requesting: http://10.0.0.22:8082/domain/cccc9324-b118-457c-9075-f4ad0c706549 2025-08-11 16:48:00,110 - DEBUG - Requesting: http://10.0.0.22:8082/project/db45b9bd-e521-4aac-89c1-4d44a3653e82 2025-08-11 16:48:00,183 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,194 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,203 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,210 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,216 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/323f81a6-99f2-4649-a041-d2941369060f 2025-08-11 16:48:00,222 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-11 16:48:00,222 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,230 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,242 - INFO - Verified VN network id 11 for VN 62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,244 - INFO - Verifications in API Server for VN ctest-vn4-59679732 passed 2025-08-11 16:48:00,244 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,253 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,258 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,264 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/323f81a6-99f2-4649-a041-d2941369060f 2025-08-11 16:48:00,277 - DEBUG - Control-node 10.0.0.22 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-80380693', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '7128422441924575730', 'uuid-lslong': '12974380957377187863'}, 'enable': 'true', 'created': '2025-08-11T16:47:58', 'last-modified': '2025-08-11T16:47:59', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.689607'} 2025-08-11 16:48:00,284 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-11 16:48:00,284 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-59679732 passed 2025-08-11 16:48:00,284 - DEBUG - ====Verifying policy data for ctest-vn4-59679732 in API_Server ====== 2025-08-11 16:48:00,284 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-08-11 16:48:00,289 - DEBUG - Requesting: http://10.0.0.22:8082/domain/cccc9324-b118-457c-9075-f4ad0c706549 2025-08-11 16:48:00,300 - DEBUG - Requesting: http://10.0.0.22:8082/project/db45b9bd-e521-4aac-89c1-4d44a3653e82 2025-08-11 16:48:00,375 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/62ed3e71-63d6-41f2-b40e-42bd510f5017 2025-08-11 16:48:00,389 - DEBUG - ==>Verifying data for policy with id: 268e0039-4d7a-457f-8259-e0ef40269ac0, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-80380693', 'ctest-policy1-77492132'] 2025-08-11 16:48:00,389 - INFO - VN ctest-vn4-59679732 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-11 16:48:00,389 - DEBUG - Verifying the vn in opserver 2025-08-11 16:48:00,389 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732 virtual network link through opserver 10.0.0.22 2025-08-11 16:48:00,390 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-08-11 16:48:00,679 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-08-11 16:48:00,731 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732', 'href': 'http://10.0.0.22:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732?flat'} 2025-08-11 16:48:00,731 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-80380693:ctest-vn4-59679732 is found in opserver 2025-08-11 16:48:00,741 - DEBUG - Do not have enough data to verify VN in agent 2025-08-11 16:48:00,746 - DEBUG - VRF ids for VN ctest-vn4-59679732: {} 2025-08-11 16:48:00,746 - DEBUG - ====Verifying data for ctest-policy1-77492132 in API_Server ====== 2025-08-11 16:48:00,746 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-08-11 16:48:00,751 - DEBUG - Requesting: http://10.0.0.22:8082/domain/cccc9324-b118-457c-9075-f4ad0c706549 2025-08-11 16:48:00,762 - DEBUG - Requesting: http://10.0.0.22:8082/project/db45b9bd-e521-4aac-89c1-4d44a3653e82 2025-08-11 16:48:00,833 - DEBUG - Requesting: http://10.0.0.22:8082/network-policy/268e0039-4d7a-457f-8259-e0ef40269ac0 2025-08-11 16:48:00,842 - INFO - Verified policy ctest-policy1-77492132 in API Server, Result: True 2025-08-11 16:48:00,843 - INFO - Done with setup and verification, moving onto test .. 2025-08-11 16:48:00,849 - INFO - Deleting VN ctest-vn4-59679732 2025-08-11 16:48:00,950 - DEBUG - Response for deleting network () 2025-08-11 16:48:00,950 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/96b1d53c-44dc-44a6-b26f-f01db7881669 2025-08-11 16:48:00,955 - DEBUG - Response Code: 404 2025-08-11 16:48:00,955 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-08-11 16:48:00,959 - DEBUG - Requesting: http://10.0.0.22:8082/domain/cccc9324-b118-457c-9075-f4ad0c706549 2025-08-11 16:48:01,011 - DEBUG - Requesting: http://10.0.0.22:8082/project/db45b9bd-e521-4aac-89c1-4d44a3653e82 2025-08-11 16:48:01,080 - INFO - Validated that VN ctest-vn4-59679732 is not found in API Server 2025-08-11 16:48:01,090 - DEBUG - VN ctest-vn4-59679732 is not present in Agent 10.0.0.22 2025-08-11 16:48:01,090 - INFO - Validated that VN ctest-vn4-59679732 is not in any agent 2025-08-11 16:48:01,104 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-59679732 info 2025-08-11 16:48:01,126 - INFO - Deleted policy ctest-policy1-77492132 2025-08-11 16:48:01,291 - DEBUG - policy ctest-policy1-77492132 is not found in API Server 2025-08-11 16:48:01,544 - DEBUG - No XMPP flaps were noticed during the test 2025-08-11 16:48:01,544 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-11 16:48:01,544 - INFO - -------------------------------------------------------------------------------- 2025-08-11 16:48:01,828 - DEBUG - No XMPP flaps were noticed during the test 2025-08-11 16:48:01,828 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-11 16:48:01,828 - INFO - -------------------------------------------------------------------------------- 2025-08-11 16:48:02,469 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-80380693, ID : db45b9bd-e521-4aac-89c1-4d44a3653e82