2025-10-22 08:19:44,172 - INFO - Domain Default found not creating 2025-10-22 08:19:44,320 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-51561716 not found, creating it 2025-10-22 08:19:44,767 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-51561716, ID : 9906be48-234f-4aab-8539-a42f6afa9d63 2025-10-22 08:19:46,220 - INFO - ================================================================================ 2025-10-22 08:19:46,220 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-22 08:19:46,479 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.25': '0'}} with 2025-10-22 08:19:46,479 - INFO - Initial checks done. Running the testcase now 2025-10-22 08:19:46,479 - INFO - 2025-10-22 08:19:46,479 - INFO - ================================================================================ 2025-10-22 08:19:46,479 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-22 08:19:46,479 - 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-10-22 08:19:46,772 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.25': '0'}} with 2025-10-22 08:19:46,772 - INFO - Initial checks done. Running the testcase now 2025-10-22 08:19:46,772 - INFO - 2025-10-22 08:19:47,128 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927, 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-51561716:ctest-vn4-76230927, 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-51561716:ctest-vn4-76230927, 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-51561716:ctest-vn4-76230927, 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-10-22 08:19:47,655 - DEBUG - Response for create_network : {'network': {'id': 'd61dc251-f6d4-4214-88c0-0f56e5093e5c', 'name': 'ctest-vn4-76230927', 'tenant_id': '9906be48234f4aab8539a42f6afa9d63', 'project_id': '9906be48234f4aab8539a42f6afa9d63', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-51561716', 'ctest-vn4-76230927'], 'port_security_enabled': True, 'description': ''}} 2025-10-22 08:19:47,859 - DEBUG - Response for create_subnet : {'subnet': {'id': '5898c3fa-d958-4ea2-80a9-ecc0b0e01606', 'name': '', 'tenant_id': '9906be48234f4aab8539a42f6afa9d63', 'network_id': 'd61dc251-f6d4-4214-88c0-0f56e5093e5c', 'ip_version': 4, 'cidr': '77.133.40.192/26', 'allocation_pools': [{'start': '77.133.40.194', 'end': '77.133.40.254'}], 'gateway_ip': '77.133.40.193', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '77.133.40.194', 'tags': [], 'project_id': '9906be48234f4aab8539a42f6afa9d63'}} 2025-10-22 08:19:48,036 - DEBUG - Response for create_subnet : {'subnet': {'id': '491e4c47-44ab-4052-83f7-9f8af121e0ff', 'name': '', 'tenant_id': '9906be48234f4aab8539a42f6afa9d63', 'network_id': 'd61dc251-f6d4-4214-88c0-0f56e5093e5c', 'ip_version': 6, 'cidr': '3172:7159:2b4a:4470:74e0:7b4e::/96', 'allocation_pools': [{'start': '3172:7159:2b4a:4470:74e0:7b4e:0:2', 'end': '3172:7159:2b4a:4470:74e0:7b4e:ffff:fffe'}], 'gateway_ip': '3172:7159:2b4a:4470:74e0:7b4e:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3172:7159:2b4a:4470:74e0:7b4e:0:2', 'tags': [], 'project_id': '9906be48234f4aab8539a42f6afa9d63'}} 2025-10-22 08:19:48,117 - INFO - Created VN ctest-vn4-76230927 2025-10-22 08:19:48,168 - DEBUG - VN ctest-vn4-76230927 UUID is d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:48,380 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'd61dc251-f6d4-4214-88c0-0f56e5093e5c', 'name': 'ctest-vn4-76230927', 'tenant_id': '9906be48234f4aab8539a42f6afa9d63', 'project_id': '9906be48234f4aab8539a42f6afa9d63', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['5898c3fa-d958-4ea2-80a9-ecc0b0e01606', '491e4c47-44ab-4052-83f7-9f8af121e0ff'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-51561716', 'ctest-vn4-76230927'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-51561716', 'ctest-policy1-46676270']], 'subnet_ipam': [{'subnet_cidr': '77.133.40.192/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3172:7159:2b4a:4470:74e0:7b4e::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-10-22 08:19:48,539 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-22 08:19:48,836 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-22 08:19:48,870 - DEBUG - Requesting: http://10.0.0.254:8082/domain/6b130d95-afea-4e1f-a530-123c9a77c62a 2025-10-22 08:19:48,885 - DEBUG - Requesting: http://10.0.0.254:8082/project/9906be48-234f-4aab-8539-a42f6afa9d63 2025-10-22 08:19:48,954 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:48,969 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:48,979 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:48,987 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:48,994 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/ebd93cf0-c6ab-47e0-a41c-760e761e530b 2025-10-22 08:19:49,000 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-22 08:19:49,000 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:49,009 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:49,023 - INFO - Verified VN network id 11 for VN d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:49,023 - INFO - Verifications in API Server for VN ctest-vn4-76230927 passed 2025-10-22 08:19:49,023 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:49,033 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:49,041 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:49,048 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/ebd93cf0-c6ab-47e0-a41c-760e761e530b 2025-10-22 08:19:49,060 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-51561716', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '15428701555730432532', 'uuid-lslong': '9853892850570837596'}, 'enable': 'true', 'created': '2025-10-22T08:19:47', 'last-modified': '2025-10-22T08:19:48', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.709704'} 2025-10-22 08:19:49,065 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-22 08:19:49,065 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-76230927 passed 2025-10-22 08:19:49,065 - DEBUG - ====Verifying policy data for ctest-vn4-76230927 in API_Server ====== 2025-10-22 08:19:49,065 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-22 08:19:49,071 - DEBUG - Requesting: http://10.0.0.254:8082/domain/6b130d95-afea-4e1f-a530-123c9a77c62a 2025-10-22 08:19:49,082 - DEBUG - Requesting: http://10.0.0.254:8082/project/9906be48-234f-4aab-8539-a42f6afa9d63 2025-10-22 08:19:49,154 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/d61dc251-f6d4-4214-88c0-0f56e5093e5c 2025-10-22 08:19:49,164 - DEBUG - ==>Verifying data for policy with id: 2065e93d-6e61-43e0-b0d7-41fa59214612, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-51561716', 'ctest-policy1-46676270'] 2025-10-22 08:19:49,164 - INFO - VN ctest-vn4-76230927 Policy verification: verify_vn_policy_in_api_server, status: True 2025-10-22 08:19:49,164 - DEBUG - Verifying the vn in opserver 2025-10-22 08:19:49,164 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927 virtual network link through opserver 10.0.0.254 2025-10-22 08:19:49,165 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-10-22 08:19:49,458 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-10-22 08:19:49,513 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927?flat'} 2025-10-22 08:19:49,513 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-51561716:ctest-vn4-76230927 is found in opserver 2025-10-22 08:19:49,522 - DEBUG - Do not have enough data to verify VN in agent 2025-10-22 08:19:49,527 - DEBUG - VRF ids for VN ctest-vn4-76230927: {} 2025-10-22 08:19:49,527 - DEBUG - ====Verifying data for ctest-policy1-46676270 in API_Server ====== 2025-10-22 08:19:49,527 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-22 08:19:49,533 - DEBUG - Requesting: http://10.0.0.254:8082/domain/6b130d95-afea-4e1f-a530-123c9a77c62a 2025-10-22 08:19:49,542 - DEBUG - Requesting: http://10.0.0.254:8082/project/9906be48-234f-4aab-8539-a42f6afa9d63 2025-10-22 08:19:49,617 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/2065e93d-6e61-43e0-b0d7-41fa59214612 2025-10-22 08:19:49,627 - INFO - Verified policy ctest-policy1-46676270 in API Server, Result: True 2025-10-22 08:19:49,627 - INFO - Done with setup and verification, moving onto test .. 2025-10-22 08:19:49,635 - INFO - Deleting VN ctest-vn4-76230927 2025-10-22 08:19:49,762 - DEBUG - Response for deleting network () 2025-10-22 08:19:49,762 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/8bfea31e-7f28-48a1-9d29-8435bf072e17 2025-10-22 08:19:49,768 - DEBUG - Response Code: 404 2025-10-22 08:19:49,769 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-22 08:19:49,774 - DEBUG - Requesting: http://10.0.0.254:8082/domain/6b130d95-afea-4e1f-a530-123c9a77c62a 2025-10-22 08:19:49,829 - DEBUG - Requesting: http://10.0.0.254:8082/project/9906be48-234f-4aab-8539-a42f6afa9d63 2025-10-22 08:19:49,900 - INFO - Validated that VN ctest-vn4-76230927 is not found in API Server 2025-10-22 08:19:49,910 - DEBUG - VN ctest-vn4-76230927 is not present in Agent 10.0.0.254 2025-10-22 08:19:49,910 - INFO - Validated that VN ctest-vn4-76230927 is not in any agent 2025-10-22 08:19:49,924 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-76230927 info 2025-10-22 08:19:49,953 - INFO - Deleted policy ctest-policy1-46676270 2025-10-22 08:19:50,123 - DEBUG - policy ctest-policy1-46676270 is not found in API Server 2025-10-22 08:19:50,376 - DEBUG - No XMPP flaps were noticed during the test 2025-10-22 08:19:50,376 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-10-22 08:19:50,376 - INFO - -------------------------------------------------------------------------------- 2025-10-22 08:19:50,664 - DEBUG - No XMPP flaps were noticed during the test 2025-10-22 08:19:50,664 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-10-22 08:19:50,664 - INFO - -------------------------------------------------------------------------------- 2025-10-22 08:19:51,340 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-51561716, ID : 9906be48-234f-4aab-8539-a42f6afa9d63