2025-11-22 09:46:06,793 - INFO - Domain Default found not creating 2025-11-22 09:46:06,971 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-35587315 not found, creating it 2025-11-22 09:46:07,429 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-35587315, ID : 54420986-d1dd-4dd4-a716-4c5299d617ed 2025-11-22 09:46:08,963 - INFO - ================================================================================ 2025-11-22 09:46:08,963 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-22 09:46:09,222 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.17': '0'}} with 2025-11-22 09:46:09,222 - INFO - Initial checks done. Running the testcase now 2025-11-22 09:46:09,222 - INFO - 2025-11-22 09:46:09,222 - INFO - ================================================================================ 2025-11-22 09:46:09,222 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-22 09:46:09,222 - 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-22 09:46:09,519 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.17': '0'}} with 2025-11-22 09:46:09,519 - INFO - Initial checks done. Running the testcase now 2025-11-22 09:46:09,520 - INFO - 2025-11-22 09:46:09,877 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148, 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-35587315:ctest-vn4-44591148, 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-35587315:ctest-vn4-44591148, 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-35587315:ctest-vn4-44591148, 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-22 09:46:10,403 - DEBUG - Response for create_network : {'network': {'id': '66a29052-4858-4b03-a793-4f2e427d70f7', 'name': 'ctest-vn4-44591148', 'tenant_id': '54420986d1dd4dd4a7164c5299d617ed', 'project_id': '54420986d1dd4dd4a7164c5299d617ed', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35587315', 'ctest-vn4-44591148'], 'port_security_enabled': True, 'description': ''}} 2025-11-22 09:46:10,622 - DEBUG - Response for create_subnet : {'subnet': {'id': '05a506f5-82e8-4bd6-b7dd-4ba9d3e1bab2', 'name': '', 'tenant_id': '54420986d1dd4dd4a7164c5299d617ed', 'network_id': '66a29052-4858-4b03-a793-4f2e427d70f7', 'ip_version': 4, 'cidr': '46.51.197.128/26', 'allocation_pools': [{'start': '46.51.197.130', 'end': '46.51.197.190'}], 'gateway_ip': '46.51.197.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '46.51.197.130', 'tags': [], 'project_id': '54420986d1dd4dd4a7164c5299d617ed'}} 2025-11-22 09:46:10,823 - DEBUG - Response for create_subnet : {'subnet': {'id': 'd155a7d1-6fb3-4973-9399-78eea47ffcb9', 'name': '', 'tenant_id': '54420986d1dd4dd4a7164c5299d617ed', 'network_id': '66a29052-4858-4b03-a793-4f2e427d70f7', 'ip_version': 6, 'cidr': '2bfd:5201:4781:9064:180c:4ba5::/96', 'allocation_pools': [{'start': '2bfd:5201:4781:9064:180c:4ba5:0:2', 'end': '2bfd:5201:4781:9064:180c:4ba5:ffff:fffe'}], 'gateway_ip': '2bfd:5201:4781:9064:180c:4ba5:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2bfd:5201:4781:9064:180c:4ba5:0:2', 'tags': [], 'project_id': '54420986d1dd4dd4a7164c5299d617ed'}} 2025-11-22 09:46:10,847 - INFO - Created VN ctest-vn4-44591148 2025-11-22 09:46:10,900 - DEBUG - VN ctest-vn4-44591148 UUID is 66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,138 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '66a29052-4858-4b03-a793-4f2e427d70f7', 'name': 'ctest-vn4-44591148', 'tenant_id': '54420986d1dd4dd4a7164c5299d617ed', 'project_id': '54420986d1dd4dd4a7164c5299d617ed', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['05a506f5-82e8-4bd6-b7dd-4ba9d3e1bab2', 'd155a7d1-6fb3-4973-9399-78eea47ffcb9'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35587315', 'ctest-vn4-44591148'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35587315', 'ctest-policy1-43773709']], 'subnet_ipam': [{'subnet_cidr': '46.51.197.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2bfd:5201:4781:9064:180c:4ba5::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-22 09:46:11,308 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-11-22 09:46:11,606 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-11-22 09:46:11,640 - DEBUG - Requesting: http://10.0.0.249:8082/domain/c7ece9bf-6624-4e3a-b318-c7aae69af5ff 2025-11-22 09:46:11,652 - DEBUG - Requesting: http://10.0.0.249:8082/project/54420986-d1dd-4dd4-a716-4c5299d617ed 2025-11-22 09:46:11,721 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,740 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,770 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:11,779 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:11,787 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/33432361-86ee-437f-8b80-11b687bed0fa 2025-11-22 09:46:11,794 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-22 09:46:11,794 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,803 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:11,818 - INFO - Verified VN network id 11 for VN 66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,819 - INFO - Verifications in API Server for VN ctest-vn4-44591148 passed 2025-11-22 09:46:11,819 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,829 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:11,836 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:11,842 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/33432361-86ee-437f-8b80-11b687bed0fa 2025-11-22 09:46:11,855 - DEBUG - Control-node 10.0.0.249 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-35587315', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '7395632221171239683', 'uuid-lslong': '12075082086013038839'}, 'enable': 'true', 'created': '2025-11-22T09:46:10', 'last-modified': '2025-11-22T09:46:11', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.751362'} 2025-11-22 09:46:11,861 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-22 09:46:11,861 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-44591148 passed 2025-11-22 09:46:11,862 - DEBUG - ====Verifying policy data for ctest-vn4-44591148 in API_Server ====== 2025-11-22 09:46:11,862 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-11-22 09:46:11,868 - DEBUG - Requesting: http://10.0.0.249:8082/domain/c7ece9bf-6624-4e3a-b318-c7aae69af5ff 2025-11-22 09:46:11,879 - DEBUG - Requesting: http://10.0.0.249:8082/project/54420986-d1dd-4dd4-a716-4c5299d617ed 2025-11-22 09:46:11,954 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/66a29052-4858-4b03-a793-4f2e427d70f7 2025-11-22 09:46:11,964 - DEBUG - ==>Verifying data for policy with id: 66bf9e77-8c90-4289-bbf7-2bc06e90ba52, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35587315', 'ctest-policy1-43773709'] 2025-11-22 09:46:11,964 - INFO - VN ctest-vn4-44591148 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-22 09:46:11,964 - DEBUG - Verifying the vn in opserver 2025-11-22 09:46:11,964 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148 virtual network link through opserver 10.0.0.249 2025-11-22 09:46:11,964 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2025-11-22 09:46:12,261 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2025-11-22 09:46:12,334 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148', 'href': 'http://10.0.0.249:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148?flat'} 2025-11-22 09:46:12,334 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35587315:ctest-vn4-44591148 is found in opserver 2025-11-22 09:46:12,345 - DEBUG - Do not have enough data to verify VN in agent 2025-11-22 09:46:12,350 - DEBUG - VRF ids for VN ctest-vn4-44591148: {} 2025-11-22 09:46:12,351 - DEBUG - ====Verifying data for ctest-policy1-43773709 in API_Server ====== 2025-11-22 09:46:12,351 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-11-22 09:46:12,357 - DEBUG - Requesting: http://10.0.0.249:8082/domain/c7ece9bf-6624-4e3a-b318-c7aae69af5ff 2025-11-22 09:46:12,367 - DEBUG - Requesting: http://10.0.0.249:8082/project/54420986-d1dd-4dd4-a716-4c5299d617ed 2025-11-22 09:46:12,442 - DEBUG - Requesting: http://10.0.0.249:8082/network-policy/66bf9e77-8c90-4289-bbf7-2bc06e90ba52 2025-11-22 09:46:12,452 - INFO - Verified policy ctest-policy1-43773709 in API Server, Result: True 2025-11-22 09:46:12,452 - INFO - Done with setup and verification, moving onto test .. 2025-11-22 09:46:12,462 - INFO - Deleting VN ctest-vn4-44591148 2025-11-22 09:46:12,585 - DEBUG - Response for deleting network () 2025-11-22 09:46:12,585 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/475a235e-8dfc-40c1-b4fb-47ca8cfeeae5 2025-11-22 09:46:12,591 - DEBUG - Response Code: 404 2025-11-22 09:46:12,591 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2025-11-22 09:46:12,598 - DEBUG - Requesting: http://10.0.0.249:8082/domain/c7ece9bf-6624-4e3a-b318-c7aae69af5ff 2025-11-22 09:46:12,653 - DEBUG - Requesting: http://10.0.0.249:8082/project/54420986-d1dd-4dd4-a716-4c5299d617ed 2025-11-22 09:46:12,727 - INFO - Validated that VN ctest-vn4-44591148 is not found in API Server 2025-11-22 09:46:12,738 - DEBUG - VN ctest-vn4-44591148 is not present in Agent 10.0.0.249 2025-11-22 09:46:12,738 - INFO - Validated that VN ctest-vn4-44591148 is not in any agent 2025-11-22 09:46:12,752 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-44591148 info 2025-11-22 09:46:12,778 - INFO - Deleted policy ctest-policy1-43773709 2025-11-22 09:46:12,939 - DEBUG - policy ctest-policy1-43773709 is not found in API Server 2025-11-22 09:46:13,199 - DEBUG - No XMPP flaps were noticed during the test 2025-11-22 09:46:13,199 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-11-22 09:46:13,199 - INFO - -------------------------------------------------------------------------------- 2025-11-22 09:46:13,489 - DEBUG - No XMPP flaps were noticed during the test 2025-11-22 09:46:13,489 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-11-22 09:46:13,489 - INFO - -------------------------------------------------------------------------------- 2025-11-22 09:46:14,211 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-35587315, ID : 54420986-d1dd-4dd4-a716-4c5299d617ed