2025-11-10 18:51:44,469 - INFO - Domain Default found not creating 2025-11-10 18:51:44,698 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-85374382 not found, creating it 2025-11-10 18:51:45,184 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-85374382, ID : e005c571-2536-4a9d-84f2-06b11e228cc8 2025-11-10 18:51:46,863 - INFO - ================================================================================ 2025-11-10 18:51:46,863 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-10 18:51:47,156 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.14': '0'}} with 2025-11-10 18:51:47,156 - INFO - Initial checks done. Running the testcase now 2025-11-10 18:51:47,156 - INFO - 2025-11-10 18:51:47,157 - INFO - ================================================================================ 2025-11-10 18:51:47,157 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-10 18:51:47,157 - 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-10 18:51:47,460 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.14': '0'}} with 2025-11-10 18:51:47,460 - INFO - Initial checks done. Running the testcase now 2025-11-10 18:51:47,460 - INFO - 2025-11-10 18:51:47,835 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692, 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-85374382:ctest-vn4-32034692, 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-85374382:ctest-vn4-32034692, 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-85374382:ctest-vn4-32034692, 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-10 18:51:48,496 - DEBUG - Response for create_network : {'network': {'id': 'e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622', 'name': 'ctest-vn4-32034692', 'tenant_id': 'e005c57125364a9d84f206b11e228cc8', 'project_id': 'e005c57125364a9d84f206b11e228cc8', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85374382', 'ctest-vn4-32034692'], 'port_security_enabled': True, 'description': ''}} 2025-11-10 18:51:48,693 - DEBUG - Response for create_subnet : {'subnet': {'id': '8d06add8-b413-41fe-8294-33bfc4bb15bb', 'name': '', 'tenant_id': 'e005c57125364a9d84f206b11e228cc8', 'network_id': 'e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622', 'ip_version': 4, 'cidr': '45.216.60.0/26', 'allocation_pools': [{'start': '45.216.60.2', 'end': '45.216.60.62'}], 'gateway_ip': '45.216.60.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '45.216.60.2', 'tags': [], 'project_id': 'e005c57125364a9d84f206b11e228cc8'}} 2025-11-10 18:51:48,876 - DEBUG - Response for create_subnet : {'subnet': {'id': 'ff9eeec7-85a8-4594-adbe-20e427f0098c', 'name': '', 'tenant_id': 'e005c57125364a9d84f206b11e228cc8', 'network_id': 'e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622', 'ip_version': 6, 'cidr': '3d1f:a1da:bfb5:7d55:e22:3bb2::/96', 'allocation_pools': [{'start': '3d1f:a1da:bfb5:7d55:e22:3bb2:0:2', 'end': '3d1f:a1da:bfb5:7d55:e22:3bb2:ffff:fffe'}], 'gateway_ip': '3d1f:a1da:bfb5:7d55:e22:3bb2:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3d1f:a1da:bfb5:7d55:e22:3bb2:0:2', 'tags': [], 'project_id': 'e005c57125364a9d84f206b11e228cc8'}} 2025-11-10 18:51:48,898 - INFO - Created VN ctest-vn4-32034692 2025-11-10 18:51:48,954 - DEBUG - VN ctest-vn4-32034692 UUID is e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,154 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622', 'name': 'ctest-vn4-32034692', 'tenant_id': 'e005c57125364a9d84f206b11e228cc8', 'project_id': 'e005c57125364a9d84f206b11e228cc8', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['8d06add8-b413-41fe-8294-33bfc4bb15bb', 'ff9eeec7-85a8-4594-adbe-20e427f0098c'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85374382', 'ctest-vn4-32034692'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85374382', 'ctest-policy1-71344393']], 'subnet_ipam': [{'subnet_cidr': '45.216.60.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3d1f:a1da:bfb5:7d55:e22:3bb2::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-10 18:51:49,326 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-10 18:51:49,625 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-10 18:51:49,667 - DEBUG - Requesting: http://10.0.0.22:8082/domain/01806cc8-88b6-4291-a70d-f67bc75f47ee 2025-11-10 18:51:49,695 - DEBUG - Requesting: http://10.0.0.22:8082/project/e005c571-2536-4a9d-84f2-06b11e228cc8 2025-11-10 18:51:49,774 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,788 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,797 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:49,804 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:49,811 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/69dbd50a-2d25-416a-9b17-86d94a9f5cd8 2025-11-10 18:51:49,818 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-10 18:51:49,818 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,829 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:49,844 - INFO - Verified VN network id 12 for VN e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,844 - INFO - Verifications in API Server for VN ctest-vn4-32034692 passed 2025-11-10 18:51:49,844 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:49,856 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:49,865 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:49,874 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/69dbd50a-2d25-416a-9b17-86d94a9f5cd8 2025-11-10 18:51:49,887 - DEBUG - Control-node 10.0.0.22 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-85374382', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '16564141548469829817', 'uuid-lslong': '10327877080261326370'}, 'enable': 'true', 'created': '2025-11-10T18:51:48', 'last-modified': '2025-11-10T18:51:49', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.758640'} 2025-11-10 18:51:49,896 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-10 18:51:49,896 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-32034692 passed 2025-11-10 18:51:49,896 - DEBUG - ====Verifying policy data for ctest-vn4-32034692 in API_Server ====== 2025-11-10 18:51:49,897 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-10 18:51:49,902 - DEBUG - Requesting: http://10.0.0.22:8082/domain/01806cc8-88b6-4291-a70d-f67bc75f47ee 2025-11-10 18:51:49,915 - DEBUG - Requesting: http://10.0.0.22:8082/project/e005c571-2536-4a9d-84f2-06b11e228cc8 2025-11-10 18:51:49,994 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/e5dfa6fa-4dd5-40b9-8f53-fd7c2cdff622 2025-11-10 18:51:50,011 - DEBUG - ==>Verifying data for policy with id: 39cd78ff-2ce4-40c3-9167-21f6a6ca87e2, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85374382', 'ctest-policy1-71344393'] 2025-11-10 18:51:50,011 - INFO - VN ctest-vn4-32034692 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-10 18:51:50,011 - DEBUG - Verifying the vn in opserver 2025-11-10 18:51:50,012 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692 virtual network link through opserver 10.0.0.22 2025-11-10 18:51:50,012 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-11-10 18:51:50,320 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-11-10 18:51:50,382 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692', 'href': 'http://10.0.0.22:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692?flat'} 2025-11-10 18:51:50,382 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85374382:ctest-vn4-32034692 is found in opserver 2025-11-10 18:51:50,393 - DEBUG - Do not have enough data to verify VN in agent 2025-11-10 18:51:50,399 - DEBUG - VRF ids for VN ctest-vn4-32034692: {} 2025-11-10 18:51:50,399 - DEBUG - ====Verifying data for ctest-policy1-71344393 in API_Server ====== 2025-11-10 18:51:50,399 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-10 18:51:50,405 - DEBUG - Requesting: http://10.0.0.22:8082/domain/01806cc8-88b6-4291-a70d-f67bc75f47ee 2025-11-10 18:51:50,416 - DEBUG - Requesting: http://10.0.0.22:8082/project/e005c571-2536-4a9d-84f2-06b11e228cc8 2025-11-10 18:51:50,489 - DEBUG - Requesting: http://10.0.0.22:8082/network-policy/39cd78ff-2ce4-40c3-9167-21f6a6ca87e2 2025-11-10 18:51:50,500 - INFO - Verified policy ctest-policy1-71344393 in API Server, Result: True 2025-11-10 18:51:50,500 - INFO - Done with setup and verification, moving onto test .. 2025-11-10 18:51:50,508 - INFO - Deleting VN ctest-vn4-32034692 2025-11-10 18:51:50,618 - DEBUG - Response for deleting network () 2025-11-10 18:51:50,618 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/b7d621ca-0966-414c-a145-118c439f5d06 2025-11-10 18:51:50,623 - DEBUG - Response Code: 404 2025-11-10 18:51:50,623 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-10 18:51:50,628 - DEBUG - Requesting: http://10.0.0.22:8082/domain/01806cc8-88b6-4291-a70d-f67bc75f47ee 2025-11-10 18:51:50,679 - DEBUG - Requesting: http://10.0.0.22:8082/project/e005c571-2536-4a9d-84f2-06b11e228cc8 2025-11-10 18:51:50,752 - INFO - Validated that VN ctest-vn4-32034692 is not found in API Server 2025-11-10 18:51:50,761 - DEBUG - VN ctest-vn4-32034692 is not present in Agent 10.0.0.22 2025-11-10 18:51:50,762 - INFO - Validated that VN ctest-vn4-32034692 is not in any agent 2025-11-10 18:51:50,776 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-32034692 info 2025-11-10 18:51:50,803 - INFO - Deleted policy ctest-policy1-71344393 2025-11-10 18:51:50,986 - DEBUG - policy ctest-policy1-71344393 is not found in API Server 2025-11-10 18:51:51,285 - DEBUG - No XMPP flaps were noticed during the test
2025-11-10 18:51:51,285 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-11-10 18:51:51,285 - INFO - -------------------------------------------------------------------------------- 2025-11-10 18:51:51,624 - DEBUG - No XMPP flaps were noticed during the test
2025-11-10 18:51:51,624 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2025-11-10 18:51:51,624 - INFO - -------------------------------------------------------------------------------- 2025-11-10 18:51:52,353 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-85374382, ID : e005c571-2536-4a9d-84f2-06b11e228cc8