2025-08-11 12:15:42,731 - INFO - Domain Default found not creating 2025-08-11 12:15:42,847 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-70961234 not found, creating it 2025-08-11 12:15:43,347 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-70961234, ID : 9b2beee4-632b-406f-81ef-664dd2305677 2025-08-11 12:15:44,625 - INFO - ================================================================================ 2025-08-11 12:15:44,625 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-11 12:15:44,876 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.14': '0'}} with 2025-08-11 12:15:44,876 - INFO - Initial checks done. Running the testcase now 2025-08-11 12:15:44,876 - INFO - 2025-08-11 12:15:44,876 - INFO - ================================================================================ 2025-08-11 12:15:44,876 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-11 12:15:44,876 - 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 12:15:45,163 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.14': '0'}} with 2025-08-11 12:15:45,163 - INFO - Initial checks done. Running the testcase now 2025-08-11 12:15:45,163 - INFO - 2025-08-11 12:15:45,495 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519, 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-70961234:ctest-vn4-31560519, 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-70961234:ctest-vn4-31560519, 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-70961234:ctest-vn4-31560519, 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 12:15:45,978 - DEBUG - Response for create_network : {'network': {'id': 'de14b0cf-2c90-4abe-a783-4163608b6b04', 'name': 'ctest-vn4-31560519', 'tenant_id': '9b2beee4632b406f81ef664dd2305677', 'project_id': '9b2beee4632b406f81ef664dd2305677', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70961234', 'ctest-vn4-31560519'], 'port_security_enabled': True, 'description': ''}} 2025-08-11 12:15:46,121 - DEBUG - Response for create_subnet : {'subnet': {'id': '1fc94b61-936c-488d-8171-56732aaca184', 'name': '', 'tenant_id': '9b2beee4632b406f81ef664dd2305677', 'network_id': 'de14b0cf-2c90-4abe-a783-4163608b6b04', 'ip_version': 4, 'cidr': '220.128.221.128/26', 'allocation_pools': [{'start': '220.128.221.130', 'end': '220.128.221.190'}], 'gateway_ip': '220.128.221.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '220.128.221.130', 'tags': [], 'project_id': '9b2beee4632b406f81ef664dd2305677'}} 2025-08-11 12:15:46,275 - DEBUG - Response for create_subnet : {'subnet': {'id': '6ed9fab3-ef60-40f6-8538-a515e20c5bdd', 'name': '', 'tenant_id': '9b2beee4632b406f81ef664dd2305677', 'network_id': 'de14b0cf-2c90-4abe-a783-4163608b6b04', 'ip_version': 6, 'cidr': '3db5:b4af:9831:8281:cdf2:93df::/96', 'allocation_pools': [{'start': '3db5:b4af:9831:8281:cdf2:93df:0:2', 'end': '3db5:b4af:9831:8281:cdf2:93df:ffff:fffe'}], 'gateway_ip': '3db5:b4af:9831:8281:cdf2:93df:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3db5:b4af:9831:8281:cdf2:93df:0:2', 'tags': [], 'project_id': '9b2beee4632b406f81ef664dd2305677'}} 2025-08-11 12:15:46,291 - INFO - Created VN ctest-vn4-31560519 2025-08-11 12:15:46,343 - DEBUG - VN ctest-vn4-31560519 UUID is de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:46,543 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'de14b0cf-2c90-4abe-a783-4163608b6b04', 'name': 'ctest-vn4-31560519', 'tenant_id': '9b2beee4632b406f81ef664dd2305677', 'project_id': '9b2beee4632b406f81ef664dd2305677', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['1fc94b61-936c-488d-8171-56732aaca184', '6ed9fab3-ef60-40f6-8538-a515e20c5bdd'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70961234', 'ctest-vn4-31560519'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70961234', 'ctest-policy1-20301088']], 'subnet_ipam': [{'subnet_cidr': '220.128.221.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3db5:b4af:9831:8281:cdf2:93df::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-11 12:15:46,711 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-08-11 12:15:46,997 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-08-11 12:15:47,021 - DEBUG - Requesting: http://10.0.0.249:8082/domain/f0993ec5-e211-4fc3-88e7-a27cd3ba1cf8 2025-08-11 12:15:47,032 - DEBUG - Requesting: http://10.0.0.249:8082/project/9b2beee4-632b-406f-81ef-664dd2305677 2025-08-11 12:15:47,099 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,110 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,118 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,124 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,130 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/cc1c5e66-8fe4-4ce0-8447-cfe2547f67f1 2025-08-11 12:15:47,135 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-11 12:15:47,135 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,143 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,155 - INFO - Verified VN network id 11 for VN de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,155 - INFO - Verifications in API Server for VN ctest-vn4-31560519 passed 2025-08-11 12:15:47,155 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,165 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,171 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,176 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/cc1c5e66-8fe4-4ce0-8447-cfe2547f67f1 2025-08-11 12:15:47,186 - DEBUG - Control-node 10.0.0.249 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-70961234', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '16002609779806587582', 'uuid-lslong': '12070563321360378628'}, 'enable': 'true', 'created': '2025-08-11T12:15:45', 'last-modified': '2025-08-11T12:15:46', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.680785'} 2025-08-11 12:15:47,192 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-11 12:15:47,192 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-31560519 passed 2025-08-11 12:15:47,192 - DEBUG - ====Verifying policy data for ctest-vn4-31560519 in API_Server ====== 2025-08-11 12:15:47,192 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-08-11 12:15:47,197 - DEBUG - Requesting: http://10.0.0.249:8082/domain/f0993ec5-e211-4fc3-88e7-a27cd3ba1cf8 2025-08-11 12:15:47,206 - DEBUG - Requesting: http://10.0.0.249:8082/project/9b2beee4-632b-406f-81ef-664dd2305677 2025-08-11 12:15:47,272 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/de14b0cf-2c90-4abe-a783-4163608b6b04 2025-08-11 12:15:47,281 - DEBUG - ==>Verifying data for policy with id: 4ae20739-1746-4e7b-b618-22a3981e05f2, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-70961234', 'ctest-policy1-20301088'] 2025-08-11 12:15:47,281 - INFO - VN ctest-vn4-31560519 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-11 12:15:47,281 - DEBUG - Verifying the vn in opserver 2025-08-11 12:15:47,281 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519 virtual network link through opserver 10.0.0.249 2025-08-11 12:15:47,282 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2025-08-11 12:15:47,568 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2025-08-11 12:15:47,614 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519', 'href': 'http://10.0.0.249:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519?flat'} 2025-08-11 12:15:47,614 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-70961234:ctest-vn4-31560519 is found in opserver 2025-08-11 12:15:47,623 - DEBUG - Do not have enough data to verify VN in agent 2025-08-11 12:15:47,628 - DEBUG - VRF ids for VN ctest-vn4-31560519: {} 2025-08-11 12:15:47,628 - DEBUG - ====Verifying data for ctest-policy1-20301088 in API_Server ====== 2025-08-11 12:15:47,628 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-08-11 12:15:47,633 - DEBUG - Requesting: http://10.0.0.249:8082/domain/f0993ec5-e211-4fc3-88e7-a27cd3ba1cf8 2025-08-11 12:15:47,642 - DEBUG - Requesting: http://10.0.0.249:8082/project/9b2beee4-632b-406f-81ef-664dd2305677 2025-08-11 12:15:47,712 - DEBUG - Requesting: http://10.0.0.249:8082/network-policy/4ae20739-1746-4e7b-b618-22a3981e05f2 2025-08-11 12:15:47,721 - INFO - Verified policy ctest-policy1-20301088 in API Server, Result: True 2025-08-11 12:15:47,721 - INFO - Done with setup and verification, moving onto test .. 2025-08-11 12:15:47,727 - INFO - Deleting VN ctest-vn4-31560519 2025-08-11 12:15:47,835 - DEBUG - Response for deleting network () 2025-08-11 12:15:47,835 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/34d7005a-22db-4821-a419-573918816d5a 2025-08-11 12:15:47,841 - DEBUG - Response Code: 404 2025-08-11 12:15:47,841 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-08-11 12:15:47,846 - DEBUG - Requesting: http://10.0.0.249:8082/domain/f0993ec5-e211-4fc3-88e7-a27cd3ba1cf8 2025-08-11 12:15:47,899 - DEBUG - Requesting: http://10.0.0.249:8082/project/9b2beee4-632b-406f-81ef-664dd2305677 2025-08-11 12:15:47,968 - INFO - Validated that VN ctest-vn4-31560519 is not found in API Server 2025-08-11 12:15:47,977 - DEBUG - VN ctest-vn4-31560519 is not present in Agent 10.0.0.249 2025-08-11 12:15:47,977 - INFO - Validated that VN ctest-vn4-31560519 is not in any agent 2025-08-11 12:15:47,991 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-31560519 info 2025-08-11 12:15:48,013 - INFO - Deleted policy ctest-policy1-20301088 2025-08-11 12:15:48,170 - DEBUG - policy ctest-policy1-20301088 is not found in API Server 2025-08-11 12:15:48,423 - DEBUG - No XMPP flaps were noticed during the test 2025-08-11 12:15:48,424 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-11 12:15:48,424 - INFO - -------------------------------------------------------------------------------- 2025-08-11 12:15:48,711 - DEBUG - No XMPP flaps were noticed during the test 2025-08-11 12:15:48,711 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-11 12:15:48,711 - INFO - -------------------------------------------------------------------------------- 2025-08-11 12:15:49,349 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-70961234, ID : 9b2beee4-632b-406f-81ef-664dd2305677