2025-10-21 15:25:12,998 - INFO - Domain Default found not creating 2025-10-21 15:25:13,171 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-66347537 not found, creating it 2025-10-21 15:25:13,600 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-66347537, ID : a872a63b-699d-4092-9eed-56856c0b8d9c 2025-10-21 15:25:14,936 - INFO - ================================================================================ 2025-10-21 15:25:14,937 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-21 15:25:15,186 - DEBUG - Nothing to compare xmpp stats {'10.0.0.41': {'10.20.0.17': '0'}} with 2025-10-21 15:25:15,186 - INFO - Initial checks done. Running the testcase now 2025-10-21 15:25:15,186 - INFO - 2025-10-21 15:25:15,186 - INFO - ================================================================================ 2025-10-21 15:25:15,186 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-21 15:25:15,186 - 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-21 15:25:15,486 - DEBUG - Nothing to compare xmpp stats {'10.0.0.41': {'10.20.0.17': '0'}} with 2025-10-21 15:25:15,486 - INFO - Initial checks done. Running the testcase now 2025-10-21 15:25:15,486 - INFO - 2025-10-21 15:25:15,825 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723, 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-66347537:ctest-vn4-13167723, 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-66347537:ctest-vn4-13167723, 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-66347537:ctest-vn4-13167723, 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-21 15:25:16,299 - DEBUG - Response for create_network : {'network': {'id': '5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb', 'name': 'ctest-vn4-13167723', 'tenant_id': 'a872a63b699d40929eed56856c0b8d9c', 'project_id': 'a872a63b699d40929eed56856c0b8d9c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-66347537', 'ctest-vn4-13167723'], 'port_security_enabled': True, 'description': ''}} 2025-10-21 15:25:16,454 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a37f4bf1-b272-4a36-9ffd-7c77b15446ea', 'name': '', 'tenant_id': 'a872a63b699d40929eed56856c0b8d9c', 'network_id': '5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb', 'ip_version': 4, 'cidr': '208.75.94.128/26', 'allocation_pools': [{'start': '208.75.94.130', 'end': '208.75.94.190'}], 'gateway_ip': '208.75.94.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '208.75.94.130', 'tags': [], 'project_id': 'a872a63b699d40929eed56856c0b8d9c'}} 2025-10-21 15:25:16,610 - DEBUG - Response for create_subnet : {'subnet': {'id': 'dee69a75-bc20-426c-acb2-beefff395d32', 'name': '', 'tenant_id': 'a872a63b699d40929eed56856c0b8d9c', 'network_id': '5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb', 'ip_version': 6, 'cidr': '2dea:c485:d4f9:37b8:7e68:8f3c::/96', 'allocation_pools': [{'start': '2dea:c485:d4f9:37b8:7e68:8f3c:0:2', 'end': '2dea:c485:d4f9:37b8:7e68:8f3c:ffff:fffe'}], 'gateway_ip': '2dea:c485:d4f9:37b8:7e68:8f3c:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2dea:c485:d4f9:37b8:7e68:8f3c:0:2', 'tags': [], 'project_id': 'a872a63b699d40929eed56856c0b8d9c'}} 2025-10-21 15:25:16,627 - INFO - Created VN ctest-vn4-13167723 2025-10-21 15:25:16,678 - DEBUG - VN ctest-vn4-13167723 UUID is 5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:16,868 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb', 'name': 'ctest-vn4-13167723', 'tenant_id': 'a872a63b699d40929eed56856c0b8d9c', 'project_id': 'a872a63b699d40929eed56856c0b8d9c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['a37f4bf1-b272-4a36-9ffd-7c77b15446ea', 'dee69a75-bc20-426c-acb2-beefff395d32'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-66347537', 'ctest-vn4-13167723'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-66347537', 'ctest-policy1-22536547']], 'subnet_ipam': [{'subnet_cidr': '208.75.94.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2dea:c485:d4f9:37b8:7e68:8f3c::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-10-21 15:25:17,030 - DEBUG - Requesting: http://10.0.0.41:8082/domains 2025-10-21 15:25:17,318 - DEBUG - Requesting: http://10.0.0.41:8082/domains 2025-10-21 15:25:17,343 - DEBUG - Requesting: http://10.0.0.41:8082/domain/cb0d9fe4-4f68-4853-be03-f69af2411f49 2025-10-21 15:25:17,354 - DEBUG - Requesting: http://10.0.0.41:8082/project/a872a63b-699d-4092-9eed-56856c0b8d9c 2025-10-21 15:25:17,421 - DEBUG - Requesting: http://10.0.0.41:8082/virtual-network/5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,432 - DEBUG - Requesting: http://10.0.0.41:8082/virtual-network/5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,440 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:17,445 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:17,450 - DEBUG - Requesting: http://10.0.0.41:8082/route-target/917ea747-84c2-4f1d-9523-10d1d98ae96c 2025-10-21 15:25:17,455 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-21 15:25:17,455 - DEBUG - Requesting: http://10.0.0.41:8082/virtual-network/5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,462 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:17,474 - INFO - Verified VN network id 12 for VN 5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,474 - INFO - Verifications in API Server for VN ctest-vn4-13167723 passed 2025-10-21 15:25:17,474 - DEBUG - Requesting: http://10.0.0.41:8082/virtual-network/5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,482 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:17,487 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:17,492 - DEBUG - Requesting: http://10.0.0.41:8082/route-target/917ea747-84c2-4f1d-9523-10d1d98ae96c 2025-10-21 15:25:17,501 - DEBUG - Control-node 10.0.0.41 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-66347537', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '6518169510857689828', 'uuid-lslong': '10127165980377456363'}, 'enable': 'true', 'created': '2025-10-21T15:25:16', 'last-modified': '2025-10-21T15:25:16', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.663720'} 2025-10-21 15:25:17,506 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-21 15:25:17,506 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-13167723 passed 2025-10-21 15:25:17,506 - DEBUG - ====Verifying policy data for ctest-vn4-13167723 in API_Server ====== 2025-10-21 15:25:17,506 - DEBUG - Requesting: http://10.0.0.41:8082/domains 2025-10-21 15:25:17,511 - DEBUG - Requesting: http://10.0.0.41:8082/domain/cb0d9fe4-4f68-4853-be03-f69af2411f49 2025-10-21 15:25:17,521 - DEBUG - Requesting: http://10.0.0.41:8082/project/a872a63b-699d-4092-9eed-56856c0b8d9c 2025-10-21 15:25:17,589 - DEBUG - Requesting: http://10.0.0.41:8082/virtual-network/5a7530a2-a874-4ae4-8c8a-ebcd99d19eeb 2025-10-21 15:25:17,598 - DEBUG - ==>Verifying data for policy with id: 60265462-253c-4946-8e13-71ea5c783f1a, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-66347537', 'ctest-policy1-22536547'] 2025-10-21 15:25:17,598 - INFO - VN ctest-vn4-13167723 Policy verification: verify_vn_policy_in_api_server, status: True 2025-10-21 15:25:17,598 - DEBUG - Verifying the vn in opserver 2025-10-21 15:25:17,598 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723 virtual network link through opserver 10.0.0.41 2025-10-21 15:25:17,598 - DEBUG - Requesting: http://10.0.0.41:8081/analytics/uves/virtual-networks 2025-10-21 15:25:17,886 - DEBUG - Requesting: http://10.0.0.41:8081/analytics/uves/virtual-networks 2025-10-21 15:25:17,934 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723', 'href': 'http://10.0.0.41:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723?flat'} 2025-10-21 15:25:17,934 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-66347537:ctest-vn4-13167723 is found in opserver 2025-10-21 15:25:17,942 - DEBUG - Do not have enough data to verify VN in agent 2025-10-21 15:25:17,947 - DEBUG - VRF ids for VN ctest-vn4-13167723: {} 2025-10-21 15:25:17,947 - DEBUG - ====Verifying data for ctest-policy1-22536547 in API_Server ====== 2025-10-21 15:25:17,947 - DEBUG - Requesting: http://10.0.0.41:8082/domains 2025-10-21 15:25:17,952 - DEBUG - Requesting: http://10.0.0.41:8082/domain/cb0d9fe4-4f68-4853-be03-f69af2411f49 2025-10-21 15:25:17,961 - DEBUG - Requesting: http://10.0.0.41:8082/project/a872a63b-699d-4092-9eed-56856c0b8d9c 2025-10-21 15:25:18,031 - DEBUG - Requesting: http://10.0.0.41:8082/network-policy/60265462-253c-4946-8e13-71ea5c783f1a 2025-10-21 15:25:18,040 - INFO - Verified policy ctest-policy1-22536547 in API Server, Result: True 2025-10-21 15:25:18,040 - INFO - Done with setup and verification, moving onto test .. 2025-10-21 15:25:18,046 - INFO - Deleting VN ctest-vn4-13167723 2025-10-21 15:25:18,147 - DEBUG - Response for deleting network () 2025-10-21 15:25:18,147 - DEBUG - Requesting: http://10.0.0.41:8082/routing-instance/2276b12b-2d43-41fc-88b3-19095aeeae37 2025-10-21 15:25:18,151 - DEBUG - Response Code: 404 2025-10-21 15:25:18,151 - DEBUG - Requesting: http://10.0.0.41:8082/domains 2025-10-21 15:25:18,156 - DEBUG - Requesting: http://10.0.0.41:8082/domain/cb0d9fe4-4f68-4853-be03-f69af2411f49 2025-10-21 15:25:18,206 - DEBUG - Requesting: http://10.0.0.41:8082/project/a872a63b-699d-4092-9eed-56856c0b8d9c 2025-10-21 15:25:18,273 - INFO - Validated that VN ctest-vn4-13167723 is not found in API Server 2025-10-21 15:25:18,281 - DEBUG - VN ctest-vn4-13167723 is not present in Agent 10.0.0.41 2025-10-21 15:25:18,281 - INFO - Validated that VN ctest-vn4-13167723 is not in any agent 2025-10-21 15:25:18,292 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-13167723 info 2025-10-21 15:25:18,313 - INFO - Deleted policy ctest-policy1-22536547 2025-10-21 15:25:18,469 - DEBUG - policy ctest-policy1-22536547 is not found in API Server 2025-10-21 15:25:18,721 - DEBUG - No XMPP flaps were noticed during the test 2025-10-21 15:25:18,721 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03] 2025-10-21 15:25:18,722 - INFO - -------------------------------------------------------------------------------- 2025-10-21 15:25:19,010 - DEBUG - No XMPP flaps were noticed during the test 2025-10-21 15:25:19,010 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-10-21 15:25:19,010 - INFO - -------------------------------------------------------------------------------- 2025-10-21 15:25:19,666 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-66347537, ID : a872a63b-699d-4092-9eed-56856c0b8d9c