2025-08-20 09:08:37,141 - INFO - Domain Default found not creating 2025-08-20 09:08:37,259 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-23225664 not found, creating it 2025-08-20 09:08:37,723 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-23225664, ID : 8e6f729f-d898-4684-87bf-3aef0ac38797 2025-08-20 09:08:39,006 - INFO - ================================================================================ 2025-08-20 09:08:39,007 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-20 09:08:39,264 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.0.0.50': '0'}} with 2025-08-20 09:08:39,264 - INFO - Initial checks done. Running the testcase now 2025-08-20 09:08:39,264 - INFO - 2025-08-20 09:08:39,264 - INFO - ================================================================================ 2025-08-20 09:08:39,264 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-20 09:08:39,264 - 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-20 09:08:39,557 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.0.0.50': '0'}} with 2025-08-20 09:08:39,557 - INFO - Initial checks done. Running the testcase now 2025-08-20 09:08:39,557 - INFO - 2025-08-20 09:08:39,893 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429, 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-23225664:ctest-vn4-40029429, 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-23225664:ctest-vn4-40029429, 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-23225664:ctest-vn4-40029429, 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-20 09:08:40,392 - DEBUG - Response for create_network : {'network': {'id': '790598b5-20d2-4687-9996-a460a9930ad5', 'name': 'ctest-vn4-40029429', 'tenant_id': '8e6f729fd898468487bf3aef0ac38797', 'project_id': '8e6f729fd898468487bf3aef0ac38797', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-23225664', 'ctest-vn4-40029429'], 'port_security_enabled': True, 'description': ''}} 2025-08-20 09:08:40,577 - DEBUG - Response for create_subnet : {'subnet': {'id': 'e52d0465-b7d9-4ffa-bdcf-a6c07ecdbd49', 'name': '', 'tenant_id': '8e6f729fd898468487bf3aef0ac38797', 'network_id': '790598b5-20d2-4687-9996-a460a9930ad5', 'ip_version': 4, 'cidr': '218.239.20.192/26', 'allocation_pools': [{'start': '218.239.20.194', 'end': '218.239.20.254'}], 'gateway_ip': '218.239.20.193', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '218.239.20.194', 'tags': [], 'project_id': '8e6f729fd898468487bf3aef0ac38797'}} 2025-08-20 09:08:40,760 - DEBUG - Response for create_subnet : {'subnet': {'id': 'e55c2a07-a165-4aaa-8908-6e7ae2c7ab90', 'name': '', 'tenant_id': '8e6f729fd898468487bf3aef0ac38797', 'network_id': '790598b5-20d2-4687-9996-a460a9930ad5', 'ip_version': 6, 'cidr': '2d58:b28:7d64:2be2:52df:48cd::/96', 'allocation_pools': [{'start': '2d58:b28:7d64:2be2:52df:48cd:0:2', 'end': '2d58:b28:7d64:2be2:52df:48cd:ffff:fffe'}], 'gateway_ip': '2d58:b28:7d64:2be2:52df:48cd:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2d58:b28:7d64:2be2:52df:48cd:0:2', 'tags': [], 'project_id': '8e6f729fd898468487bf3aef0ac38797'}} 2025-08-20 09:08:40,776 - INFO - Created VN ctest-vn4-40029429 2025-08-20 09:08:40,827 - DEBUG - VN ctest-vn4-40029429 UUID is 790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,011 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '790598b5-20d2-4687-9996-a460a9930ad5', 'name': 'ctest-vn4-40029429', 'tenant_id': '8e6f729fd898468487bf3aef0ac38797', 'project_id': '8e6f729fd898468487bf3aef0ac38797', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['e52d0465-b7d9-4ffa-bdcf-a6c07ecdbd49', 'e55c2a07-a165-4aaa-8908-6e7ae2c7ab90'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-23225664', 'ctest-vn4-40029429'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-23225664', 'ctest-policy1-04836604']], 'subnet_ipam': [{'subnet_cidr': '218.239.20.192/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2d58:b28:7d64:2be2:52df:48cd::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-20 09:08:41,179 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-08-20 09:08:41,466 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-08-20 09:08:41,491 - DEBUG - Requesting: http://10.0.0.50:8082/domain/e8a7ce66-cd45-4e0f-bb23-46d15f99ef7e 2025-08-20 09:08:41,503 - DEBUG - Requesting: http://10.0.0.50:8082/project/8e6f729f-d898-4684-87bf-3aef0ac38797 2025-08-20 09:08:41,573 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,584 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,592 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:41,597 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:41,602 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/d452f8d9-5431-4ea2-99f5-918adaa680e0 2025-08-20 09:08:41,607 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-20 09:08:41,607 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,614 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:41,625 - INFO - Verified VN network id 12 for VN 790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,625 - INFO - Verifications in API Server for VN ctest-vn4-40029429 passed 2025-08-20 09:08:41,625 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,633 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:41,638 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:41,643 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/d452f8d9-5431-4ea2-99f5-918adaa680e0 2025-08-20 09:08:41,652 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-23225664', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '8720544157179987591', 'uuid-lslong': '11067213869378374357'}, 'enable': 'true', 'created': '2025-08-20T09:08:40', 'last-modified': '2025-08-20T09:08:40', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.671292'} 2025-08-20 09:08:41,658 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-20 09:08:41,658 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-40029429 passed 2025-08-20 09:08:41,658 - DEBUG - ====Verifying policy data for ctest-vn4-40029429 in API_Server ====== 2025-08-20 09:08:41,658 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-08-20 09:08:41,662 - DEBUG - Requesting: http://10.0.0.50:8082/domain/e8a7ce66-cd45-4e0f-bb23-46d15f99ef7e 2025-08-20 09:08:41,671 - DEBUG - Requesting: http://10.0.0.50:8082/project/8e6f729f-d898-4684-87bf-3aef0ac38797 2025-08-20 09:08:41,745 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/790598b5-20d2-4687-9996-a460a9930ad5 2025-08-20 09:08:41,754 - DEBUG - ==>Verifying data for policy with id: 2b9bb139-dc9f-42fe-b50a-d2199e4861ae, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-23225664', 'ctest-policy1-04836604'] 2025-08-20 09:08:41,754 - INFO - VN ctest-vn4-40029429 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-20 09:08:41,754 - DEBUG - Verifying the vn in opserver 2025-08-20 09:08:41,754 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429 virtual network link through opserver 10.0.0.50 2025-08-20 09:08:41,754 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-08-20 09:08:42,041 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-08-20 09:08:42,088 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429?flat'} 2025-08-20 09:08:42,088 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-23225664:ctest-vn4-40029429 is found in opserver 2025-08-20 09:08:42,097 - DEBUG - Do not have enough data to verify VN in agent 2025-08-20 09:08:42,101 - DEBUG - VRF ids for VN ctest-vn4-40029429: {} 2025-08-20 09:08:42,101 - DEBUG - ====Verifying data for ctest-policy1-04836604 in API_Server ====== 2025-08-20 09:08:42,102 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-08-20 09:08:42,106 - DEBUG - Requesting: http://10.0.0.50:8082/domain/e8a7ce66-cd45-4e0f-bb23-46d15f99ef7e 2025-08-20 09:08:42,115 - DEBUG - Requesting: http://10.0.0.50:8082/project/8e6f729f-d898-4684-87bf-3aef0ac38797 2025-08-20 09:08:42,185 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/2b9bb139-dc9f-42fe-b50a-d2199e4861ae 2025-08-20 09:08:42,193 - INFO - Verified policy ctest-policy1-04836604 in API Server, Result: True 2025-08-20 09:08:42,193 - INFO - Done with setup and verification, moving onto test .. 2025-08-20 09:08:42,199 - INFO - Deleting VN ctest-vn4-40029429 2025-08-20 09:08:42,306 - DEBUG - Response for deleting network () 2025-08-20 09:08:42,306 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/acc17a92-63f9-42c3-9c7c-9c73fa436629 2025-08-20 09:08:42,310 - DEBUG - Response Code: 404 2025-08-20 09:08:42,311 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-08-20 09:08:42,315 - DEBUG - Requesting: http://10.0.0.50:8082/domain/e8a7ce66-cd45-4e0f-bb23-46d15f99ef7e 2025-08-20 09:08:42,368 - DEBUG - Requesting: http://10.0.0.50:8082/project/8e6f729f-d898-4684-87bf-3aef0ac38797 2025-08-20 09:08:42,436 - INFO - Validated that VN ctest-vn4-40029429 is not found in API Server 2025-08-20 09:08:42,445 - DEBUG - VN ctest-vn4-40029429 is not present in Agent 10.0.0.50 2025-08-20 09:08:42,445 - INFO - Validated that VN ctest-vn4-40029429 is not in any agent 2025-08-20 09:08:42,457 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-40029429 info 2025-08-20 09:08:42,479 - INFO - Deleted policy ctest-policy1-04836604 2025-08-20 09:08:42,635 - DEBUG - policy ctest-policy1-04836604 is not found in API Server 2025-08-20 09:08:42,884 - DEBUG - No XMPP flaps were noticed during the test
2025-08-20 09:08:42,884 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03]
2025-08-20 09:08:42,884 - INFO - -------------------------------------------------------------------------------- 2025-08-20 09:08:43,171 - DEBUG - No XMPP flaps were noticed during the test
2025-08-20 09:08:43,171 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-08-20 09:08:43,171 - INFO - -------------------------------------------------------------------------------- 2025-08-20 09:08:43,812 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-23225664, ID : 8e6f729f-d898-4684-87bf-3aef0ac38797