2025-11-05 16:26:58,896 - INFO - Domain Default found not creating 2025-11-05 16:26:59,024 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-73630786 not found, creating it 2025-11-05 16:26:59,443 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-73630786, ID : 0bd96e9c-1c58-4153-8fc3-adbc4949514e 2025-11-05 16:27:00,874 - INFO - ================================================================================ 2025-11-05 16:27:00,875 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-05 16:27:01,131 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.241': '0'}} with 2025-11-05 16:27:01,131 - INFO - Initial checks done. Running the testcase now 2025-11-05 16:27:01,131 - INFO - 2025-11-05 16:27:01,131 - INFO - ================================================================================ 2025-11-05 16:27:01,131 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-05 16:27:01,131 - 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-05 16:27:01,424 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.241': '0'}} with 2025-11-05 16:27:01,424 - INFO - Initial checks done. Running the testcase now 2025-11-05 16:27:01,424 - INFO - 2025-11-05 16:27:01,772 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501, 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-73630786:ctest-vn4-75562501, 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-73630786:ctest-vn4-75562501, 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-73630786:ctest-vn4-75562501, 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-05 16:27:02,268 - DEBUG - Response for create_network : {'network': {'id': 'f837cfbf-8b95-46ce-8dbe-9f3eac21e273', 'name': 'ctest-vn4-75562501', 'tenant_id': '0bd96e9c1c5841538fc3adbc4949514e', 'project_id': '0bd96e9c1c5841538fc3adbc4949514e', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-73630786', 'ctest-vn4-75562501'], 'port_security_enabled': True, 'description': ''}} 2025-11-05 16:27:02,413 - DEBUG - Response for create_subnet : {'subnet': {'id': 'de39e84e-a134-4f09-9336-e8057bd9d210', 'name': '', 'tenant_id': '0bd96e9c1c5841538fc3adbc4949514e', 'network_id': 'f837cfbf-8b95-46ce-8dbe-9f3eac21e273', 'ip_version': 4, 'cidr': '191.182.144.0/26', 'allocation_pools': [{'start': '191.182.144.2', 'end': '191.182.144.62'}], 'gateway_ip': '191.182.144.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '191.182.144.2', 'tags': [], 'project_id': '0bd96e9c1c5841538fc3adbc4949514e'}} 2025-11-05 16:27:02,625 - DEBUG - Response for create_subnet : {'subnet': {'id': '937fc9ca-16b7-4f62-b948-515fa97f6895', 'name': '', 'tenant_id': '0bd96e9c1c5841538fc3adbc4949514e', 'network_id': 'f837cfbf-8b95-46ce-8dbe-9f3eac21e273', 'ip_version': 6, 'cidr': '35a3:c62b:734:50da:ec35:12ca::/96', 'allocation_pools': [{'start': '35a3:c62b:734:50da:ec35:12ca:0:2', 'end': '35a3:c62b:734:50da:ec35:12ca:ffff:fffe'}], 'gateway_ip': '35a3:c62b:734:50da:ec35:12ca:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '35a3:c62b:734:50da:ec35:12ca:0:2', 'tags': [], 'project_id': '0bd96e9c1c5841538fc3adbc4949514e'}} 2025-11-05 16:27:02,643 - INFO - Created VN ctest-vn4-75562501 2025-11-05 16:27:02,694 - DEBUG - VN ctest-vn4-75562501 UUID is f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:02,872 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'f837cfbf-8b95-46ce-8dbe-9f3eac21e273', 'name': 'ctest-vn4-75562501', 'tenant_id': '0bd96e9c1c5841538fc3adbc4949514e', 'project_id': '0bd96e9c1c5841538fc3adbc4949514e', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['de39e84e-a134-4f09-9336-e8057bd9d210', '937fc9ca-16b7-4f62-b948-515fa97f6895'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-73630786', 'ctest-vn4-75562501'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-73630786', 'ctest-policy1-99081063']], 'subnet_ipam': [{'subnet_cidr': '191.182.144.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '35a3:c62b:734:50da:ec35:12ca::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-05 16:27:03,030 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-05 16:27:03,321 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-05 16:27:03,347 - DEBUG - Requesting: http://10.0.0.242:8082/domain/d843e358-7eb4-4378-93a6-b1f6a91ea261 2025-11-05 16:27:03,361 - DEBUG - Requesting: http://10.0.0.242:8082/project/0bd96e9c-1c58-4153-8fc3-adbc4949514e 2025-11-05 16:27:03,432 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,443 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,451 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:03,457 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:03,462 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/cb339a89-3337-42a5-a463-63abd06d5333 2025-11-05 16:27:03,468 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-05 16:27:03,468 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,477 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:03,545 - INFO - Verified VN network id 12 for VN f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,546 - INFO - Verifications in API Server for VN ctest-vn4-75562501 passed 2025-11-05 16:27:03,546 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,554 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:03,560 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:03,566 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/cb339a89-3337-42a5-a463-63abd06d5333 2025-11-05 16:27:03,577 - DEBUG - Control-node 10.0.0.242 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-73630786', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '17885992866712733390', 'uuid-lslong': '10213776096447554163'}, 'enable': 'true', 'created': '2025-11-05T16:27:02', 'last-modified': '2025-11-05T16:27:02', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.726606'} 2025-11-05 16:27:03,582 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-05 16:27:03,582 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-75562501 passed 2025-11-05 16:27:03,582 - DEBUG - ====Verifying policy data for ctest-vn4-75562501 in API_Server ====== 2025-11-05 16:27:03,582 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-05 16:27:03,587 - DEBUG - Requesting: http://10.0.0.242:8082/domain/d843e358-7eb4-4378-93a6-b1f6a91ea261 2025-11-05 16:27:03,598 - DEBUG - Requesting: http://10.0.0.242:8082/project/0bd96e9c-1c58-4153-8fc3-adbc4949514e 2025-11-05 16:27:03,666 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/f837cfbf-8b95-46ce-8dbe-9f3eac21e273 2025-11-05 16:27:03,675 - DEBUG - ==>Verifying data for policy with id: 564b9f60-bf8d-4950-9bdc-8defb4bf3566, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-73630786', 'ctest-policy1-99081063'] 2025-11-05 16:27:03,675 - INFO - VN ctest-vn4-75562501 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-05 16:27:03,675 - DEBUG - Verifying the vn in opserver 2025-11-05 16:27:03,675 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501 virtual network link through opserver 10.0.0.242 2025-11-05 16:27:03,675 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-11-05 16:27:03,962 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-11-05 16:27:04,014 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501', 'href': 'http://10.0.0.242:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501?flat'} 2025-11-05 16:27:04,015 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-73630786:ctest-vn4-75562501 is found in opserver 2025-11-05 16:27:04,025 - DEBUG - Do not have enough data to verify VN in agent 2025-11-05 16:27:04,029 - DEBUG - VRF ids for VN ctest-vn4-75562501: {} 2025-11-05 16:27:04,029 - DEBUG - ====Verifying data for ctest-policy1-99081063 in API_Server ====== 2025-11-05 16:27:04,029 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-05 16:27:04,035 - DEBUG - Requesting: http://10.0.0.242:8082/domain/d843e358-7eb4-4378-93a6-b1f6a91ea261 2025-11-05 16:27:04,045 - DEBUG - Requesting: http://10.0.0.242:8082/project/0bd96e9c-1c58-4153-8fc3-adbc4949514e 2025-11-05 16:27:04,108 - DEBUG - Requesting: http://10.0.0.242:8082/network-policy/564b9f60-bf8d-4950-9bdc-8defb4bf3566 2025-11-05 16:27:04,116 - INFO - Verified policy ctest-policy1-99081063 in API Server, Result: True 2025-11-05 16:27:04,116 - INFO - Done with setup and verification, moving onto test .. 2025-11-05 16:27:04,122 - INFO - Deleting VN ctest-vn4-75562501 2025-11-05 16:27:04,218 - DEBUG - Response for deleting network () 2025-11-05 16:27:04,218 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/688b5d13-7f67-4d06-8d39-aa076d64ad56 2025-11-05 16:27:04,223 - DEBUG - Response Code: 404 2025-11-05 16:27:04,223 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-11-05 16:27:04,228 - DEBUG - Requesting: http://10.0.0.242:8082/domain/d843e358-7eb4-4378-93a6-b1f6a91ea261 2025-11-05 16:27:04,282 - DEBUG - Requesting: http://10.0.0.242:8082/project/0bd96e9c-1c58-4153-8fc3-adbc4949514e 2025-11-05 16:27:04,350 - INFO - Validated that VN ctest-vn4-75562501 is not found in API Server 2025-11-05 16:27:04,359 - DEBUG - VN ctest-vn4-75562501 is not present in Agent 10.0.0.242 2025-11-05 16:27:04,359 - INFO - Validated that VN ctest-vn4-75562501 is not in any agent 2025-11-05 16:27:04,371 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-75562501 info 2025-11-05 16:27:04,393 - INFO - Deleted policy ctest-policy1-99081063 2025-11-05 16:27:04,554 - DEBUG - policy ctest-policy1-99081063 is not found in API Server 2025-11-05 16:27:04,806 - DEBUG - No XMPP flaps were noticed during the test
2025-11-05 16:27:04,806 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03]
2025-11-05 16:27:04,806 - INFO - -------------------------------------------------------------------------------- 2025-11-05 16:27:05,099 - DEBUG - No XMPP flaps were noticed during the test
2025-11-05 16:27:05,099 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2025-11-05 16:27:05,099 - INFO - -------------------------------------------------------------------------------- 2025-11-05 16:27:05,750 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-73630786, ID : 0bd96e9c-1c58-4153-8fc3-adbc4949514e