2025-09-11 11:22:25,897 - INFO - Domain Default found not creating 2025-09-11 11:22:26,040 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-56984511 not found, creating it 2025-09-11 11:22:26,480 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-56984511, ID : 25043c37-4f84-4f3a-8d29-863df75b4cbe 2025-09-11 11:22:27,919 - INFO - ================================================================================ 2025-09-11 11:22:27,919 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-11 11:22:28,174 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2025-09-11 11:22:28,174 - INFO - Initial checks done. Running the testcase now 2025-09-11 11:22:28,174 - INFO - 2025-09-11 11:22:28,174 - INFO - ================================================================================ 2025-09-11 11:22:28,174 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-11 11:22:28,174 - 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-09-11 11:22:28,469 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2025-09-11 11:22:28,469 - INFO - Initial checks done. Running the testcase now 2025-09-11 11:22:28,469 - INFO - 2025-09-11 11:22:28,856 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984, 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-56984511:ctest-vn4-34951984, 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-56984511:ctest-vn4-34951984, 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-56984511:ctest-vn4-34951984, 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-09-11 11:22:29,371 - DEBUG - Response for create_network : {'network': {'id': '79cb6032-0428-439f-a336-a291623ea3bc', 'name': 'ctest-vn4-34951984', 'tenant_id': '25043c374f844f3a8d29863df75b4cbe', 'project_id': '25043c374f844f3a8d29863df75b4cbe', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-56984511', 'ctest-vn4-34951984'], 'port_security_enabled': True, 'description': ''}} 2025-09-11 11:22:29,540 - DEBUG - Response for create_subnet : {'subnet': {'id': '67c2acd2-a489-4496-8d95-75d2c40b03c0', 'name': '', 'tenant_id': '25043c374f844f3a8d29863df75b4cbe', 'network_id': '79cb6032-0428-439f-a336-a291623ea3bc', 'ip_version': 4, 'cidr': '70.61.153.0/26', 'allocation_pools': [{'start': '70.61.153.2', 'end': '70.61.153.62'}], 'gateway_ip': '70.61.153.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '70.61.153.2', 'tags': [], 'project_id': '25043c374f844f3a8d29863df75b4cbe'}} 2025-09-11 11:22:29,746 - DEBUG - Response for create_subnet : {'subnet': {'id': 'dd045649-373c-4c8a-89df-cd47188b7550', 'name': '', 'tenant_id': '25043c374f844f3a8d29863df75b4cbe', 'network_id': '79cb6032-0428-439f-a336-a291623ea3bc', 'ip_version': 6, 'cidr': '36cf:6205:94ab:bdc9:3407:de9::/96', 'allocation_pools': [{'start': '36cf:6205:94ab:bdc9:3407:de9:0:2', 'end': '36cf:6205:94ab:bdc9:3407:de9:ffff:fffe'}], 'gateway_ip': '36cf:6205:94ab:bdc9:3407:de9:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '36cf:6205:94ab:bdc9:3407:de9:0:2', 'tags': [], 'project_id': '25043c374f844f3a8d29863df75b4cbe'}} 2025-09-11 11:22:29,770 - INFO - Created VN ctest-vn4-34951984 2025-09-11 11:22:29,824 - DEBUG - VN ctest-vn4-34951984 UUID is 79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,014 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '79cb6032-0428-439f-a336-a291623ea3bc', 'name': 'ctest-vn4-34951984', 'tenant_id': '25043c374f844f3a8d29863df75b4cbe', 'project_id': '25043c374f844f3a8d29863df75b4cbe', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['67c2acd2-a489-4496-8d95-75d2c40b03c0', 'dd045649-373c-4c8a-89df-cd47188b7550'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-56984511', 'ctest-vn4-34951984'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-56984511', 'ctest-policy1-93858583']], 'subnet_ipam': [{'subnet_cidr': '70.61.153.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '36cf:6205:94ab:bdc9:3407:de9::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-11 11:22:30,177 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-11 11:22:30,465 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-11 11:22:30,491 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fcd05486-4794-4521-a44f-dc0b67f859be 2025-09-11 11:22:30,502 - DEBUG - Requesting: http://10.0.0.38:8082/project/25043c37-4f84-4f3a-8d29-863df75b4cbe 2025-09-11 11:22:30,572 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,584 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,594 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:30,601 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:30,607 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/45a9f4e4-5a4c-400c-82a6-c2d6f3447952 2025-09-11 11:22:30,613 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-11 11:22:30,613 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,621 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:30,636 - INFO - Verified VN network id 12 for VN 79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,636 - INFO - Verifications in API Server for VN ctest-vn4-34951984 passed 2025-09-11 11:22:30,636 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,644 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:30,650 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:30,657 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/45a9f4e4-5a4c-400c-82a6-c2d6f3447952 2025-09-11 11:22:30,670 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-56984511', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '8776214066795922335', 'uuid-lslong': '11760766222226858940'}, 'enable': 'true', 'created': '2025-09-11T11:22:29', 'last-modified': '2025-09-11T11:22:29', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.679837'} 2025-09-11 11:22:30,676 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-11 11:22:30,677 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-34951984 passed 2025-09-11 11:22:30,677 - DEBUG - ====Verifying policy data for ctest-vn4-34951984 in API_Server ====== 2025-09-11 11:22:30,677 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-11 11:22:30,682 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fcd05486-4794-4521-a44f-dc0b67f859be 2025-09-11 11:22:30,694 - DEBUG - Requesting: http://10.0.0.38:8082/project/25043c37-4f84-4f3a-8d29-863df75b4cbe 2025-09-11 11:22:30,765 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/79cb6032-0428-439f-a336-a291623ea3bc 2025-09-11 11:22:30,775 - DEBUG - ==>Verifying data for policy with id: 1540da9e-72f7-442b-be81-da15f9ff046f, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-56984511', 'ctest-policy1-93858583'] 2025-09-11 11:22:30,775 - INFO - VN ctest-vn4-34951984 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-11 11:22:30,775 - DEBUG - Verifying the vn in opserver 2025-09-11 11:22:30,775 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984 virtual network link through opserver 10.0.0.38 2025-09-11 11:22:30,775 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-09-11 11:22:31,070 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-09-11 11:22:31,120 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984?flat'} 2025-09-11 11:22:31,120 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-56984511:ctest-vn4-34951984 is found in opserver 2025-09-11 11:22:31,129 - DEBUG - Do not have enough data to verify VN in agent 2025-09-11 11:22:31,134 - DEBUG - VRF ids for VN ctest-vn4-34951984: {} 2025-09-11 11:22:31,134 - DEBUG - ====Verifying data for ctest-policy1-93858583 in API_Server ====== 2025-09-11 11:22:31,134 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-11 11:22:31,139 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fcd05486-4794-4521-a44f-dc0b67f859be 2025-09-11 11:22:31,149 - DEBUG - Requesting: http://10.0.0.38:8082/project/25043c37-4f84-4f3a-8d29-863df75b4cbe 2025-09-11 11:22:31,217 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/1540da9e-72f7-442b-be81-da15f9ff046f 2025-09-11 11:22:31,227 - INFO - Verified policy ctest-policy1-93858583 in API Server, Result: True 2025-09-11 11:22:31,227 - INFO - Done with setup and verification, moving onto test .. 2025-09-11 11:22:31,234 - INFO - Deleting VN ctest-vn4-34951984 2025-09-11 11:22:31,344 - DEBUG - Response for deleting network () 2025-09-11 11:22:31,344 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/7bff3067-490f-4bd2-821e-2868437b3960 2025-09-11 11:22:31,349 - DEBUG - Response Code: 404 2025-09-11 11:22:31,349 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-11 11:22:31,354 - DEBUG - Requesting: http://10.0.0.38:8082/domain/fcd05486-4794-4521-a44f-dc0b67f859be 2025-09-11 11:22:31,405 - DEBUG - Requesting: http://10.0.0.38:8082/project/25043c37-4f84-4f3a-8d29-863df75b4cbe 2025-09-11 11:22:31,472 - INFO - Validated that VN ctest-vn4-34951984 is not found in API Server 2025-09-11 11:22:31,482 - DEBUG - VN ctest-vn4-34951984 is not present in Agent 10.0.0.38 2025-09-11 11:22:31,482 - INFO - Validated that VN ctest-vn4-34951984 is not in any agent 2025-09-11 11:22:31,495 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-34951984 info 2025-09-11 11:22:31,520 - INFO - Deleted policy ctest-policy1-93858583 2025-09-11 11:22:31,684 - DEBUG - policy ctest-policy1-93858583 is not found in API Server 2025-09-11 11:22:31,955 - DEBUG - No XMPP flaps were noticed during the test 2025-09-11 11:22:31,955 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03] 2025-09-11 11:22:31,955 - INFO - -------------------------------------------------------------------------------- 2025-09-11 11:22:32,241 - DEBUG - No XMPP flaps were noticed during the test 2025-09-11 11:22:32,241 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-09-11 11:22:32,241 - INFO - -------------------------------------------------------------------------------- 2025-09-11 11:22:32,968 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-56984511, ID : 25043c37-4f84-4f3a-8d29-863df75b4cbe