2025-11-04 07:23:52,801 - INFO - Domain Default found not creating 2025-11-04 07:23:52,932 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-10838507 not found, creating it 2025-11-04 07:23:53,357 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-10838507, ID : c3322e07-b7ca-482d-9704-e7410e16fe7a 2025-11-04 07:23:54,807 - INFO - ================================================================================ 2025-11-04 07:23:54,808 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-04 07:23:55,063 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2025-11-04 07:23:55,063 - INFO - Initial checks done. Running the testcase now 2025-11-04 07:23:55,063 - INFO - 2025-11-04 07:23:55,064 - INFO - ================================================================================ 2025-11-04 07:23:55,064 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-04 07:23:55,064 - 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-04 07:23:55,363 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2025-11-04 07:23:55,363 - INFO - Initial checks done. Running the testcase now 2025-11-04 07:23:55,363 - INFO - 2025-11-04 07:23:55,698 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249, 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-10838507:ctest-vn4-94921249, 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-10838507:ctest-vn4-94921249, 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-10838507:ctest-vn4-94921249, 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-04 07:23:56,190 - DEBUG - Response for create_network : {'network': {'id': '51976006-bab3-4521-b0f7-eafd3f02c24a', 'name': 'ctest-vn4-94921249', 'tenant_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'project_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10838507', 'ctest-vn4-94921249'], 'port_security_enabled': True, 'description': ''}} 2025-11-04 07:23:56,328 - DEBUG - Response for create_subnet : {'subnet': {'id': 'cea43891-80ea-4f85-b9ea-8a21fb1bdd09', 'name': '', 'tenant_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'network_id': '51976006-bab3-4521-b0f7-eafd3f02c24a', 'ip_version': 4, 'cidr': '18.208.55.64/26', 'allocation_pools': [{'start': '18.208.55.66', 'end': '18.208.55.126'}], 'gateway_ip': '18.208.55.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '18.208.55.66', 'tags': [], 'project_id': 'c3322e07b7ca482d9704e7410e16fe7a'}} 2025-11-04 07:23:56,484 - DEBUG - Response for create_subnet : {'subnet': {'id': 'c62ebb3e-6713-4699-88c5-5f85a44c466f', 'name': '', 'tenant_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'network_id': '51976006-bab3-4521-b0f7-eafd3f02c24a', 'ip_version': 6, 'cidr': '3647:f0d9:de88:3914:95ed:28b9::/96', 'allocation_pools': [{'start': '3647:f0d9:de88:3914:95ed:28b9:0:2', 'end': '3647:f0d9:de88:3914:95ed:28b9:ffff:fffe'}], 'gateway_ip': '3647:f0d9:de88:3914:95ed:28b9:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3647:f0d9:de88:3914:95ed:28b9:0:2', 'tags': [], 'project_id': 'c3322e07b7ca482d9704e7410e16fe7a'}} 2025-11-04 07:23:56,499 - INFO - Created VN ctest-vn4-94921249 2025-11-04 07:23:56,551 - DEBUG - VN ctest-vn4-94921249 UUID is 51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:56,733 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '51976006-bab3-4521-b0f7-eafd3f02c24a', 'name': 'ctest-vn4-94921249', 'tenant_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'project_id': 'c3322e07b7ca482d9704e7410e16fe7a', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['cea43891-80ea-4f85-b9ea-8a21fb1bdd09', 'c62ebb3e-6713-4699-88c5-5f85a44c466f'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10838507', 'ctest-vn4-94921249'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10838507', 'ctest-policy1-83813204']], 'subnet_ipam': [{'subnet_cidr': '18.208.55.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3647:f0d9:de88:3914:95ed:28b9::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-04 07:23:56,899 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-11-04 07:23:57,216 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-11-04 07:23:57,239 - DEBUG - Requesting: http://10.0.0.50:8082/domain/252812c3-bbf3-48b8-8f11-d640e38f27f8 2025-11-04 07:23:57,250 - DEBUG - Requesting: http://10.0.0.50:8082/project/c3322e07-b7ca-482d-9704-e7410e16fe7a 2025-11-04 07:23:57,320 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,330 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,338 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:57,344 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:57,349 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/a58f3f37-b140-4819-b28b-e7997f078397 2025-11-04 07:23:57,354 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-04 07:23:57,354 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,361 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:57,372 - INFO - Verified VN network id 11 for VN 51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,373 - INFO - Verifications in API Server for VN ctest-vn4-94921249 passed 2025-11-04 07:23:57,373 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,380 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:57,386 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:57,391 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/a58f3f37-b140-4819-b28b-e7997f078397 2025-11-04 07:23:57,400 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-10838507', 'owner-access': '7', 'group': 'manager', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '5879273420573852961', 'uuid-lslong': '12751919243327619658'}, 'enable': 'true', 'created': '2025-11-04T07:23:56', 'last-modified': '2025-11-04T07:23:56', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.693815'} 2025-11-04 07:23:57,405 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-04 07:23:57,405 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-94921249 passed 2025-11-04 07:23:57,405 - DEBUG - ====Verifying policy data for ctest-vn4-94921249 in API_Server ====== 2025-11-04 07:23:57,405 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-11-04 07:23:57,410 - DEBUG - Requesting: http://10.0.0.50:8082/domain/252812c3-bbf3-48b8-8f11-d640e38f27f8 2025-11-04 07:23:57,420 - DEBUG - Requesting: http://10.0.0.50:8082/project/c3322e07-b7ca-482d-9704-e7410e16fe7a 2025-11-04 07:23:57,486 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/51976006-bab3-4521-b0f7-eafd3f02c24a 2025-11-04 07:23:57,496 - DEBUG - ==>Verifying data for policy with id: 9bf89455-10a6-4dba-8318-11181a36753e, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-10838507', 'ctest-policy1-83813204'] 2025-11-04 07:23:57,496 - INFO - VN ctest-vn4-94921249 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-04 07:23:57,496 - DEBUG - Verifying the vn in opserver 2025-11-04 07:23:57,496 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249 virtual network link through opserver 10.0.0.50 2025-11-04 07:23:57,496 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-11-04 07:23:57,811 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-11-04 07:23:57,859 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249?flat'} 2025-11-04 07:23:57,859 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-10838507:ctest-vn4-94921249 is found in opserver 2025-11-04 07:23:57,868 - DEBUG - Do not have enough data to verify VN in agent 2025-11-04 07:23:57,872 - DEBUG - VRF ids for VN ctest-vn4-94921249: {} 2025-11-04 07:23:57,872 - DEBUG - ====Verifying data for ctest-policy1-83813204 in API_Server ====== 2025-11-04 07:23:57,872 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-11-04 07:23:57,877 - DEBUG - Requesting: http://10.0.0.50:8082/domain/252812c3-bbf3-48b8-8f11-d640e38f27f8 2025-11-04 07:23:57,889 - DEBUG - Requesting: http://10.0.0.50:8082/project/c3322e07-b7ca-482d-9704-e7410e16fe7a 2025-11-04 07:23:57,960 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/9bf89455-10a6-4dba-8318-11181a36753e 2025-11-04 07:23:57,968 - INFO - Verified policy ctest-policy1-83813204 in API Server, Result: True 2025-11-04 07:23:57,968 - INFO - Done with setup and verification, moving onto test .. 2025-11-04 07:23:57,975 - INFO - Deleting VN ctest-vn4-94921249 2025-11-04 07:23:58,075 - DEBUG - Response for deleting network () 2025-11-04 07:23:58,075 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/10bbd409-3e01-48cf-ace1-249fe958525b 2025-11-04 07:23:58,080 - DEBUG - Response Code: 404 2025-11-04 07:23:58,080 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-11-04 07:23:58,084 - DEBUG - Requesting: http://10.0.0.50:8082/domain/252812c3-bbf3-48b8-8f11-d640e38f27f8 2025-11-04 07:23:58,135 - DEBUG - Requesting: http://10.0.0.50:8082/project/c3322e07-b7ca-482d-9704-e7410e16fe7a 2025-11-04 07:23:58,209 - INFO - Validated that VN ctest-vn4-94921249 is not found in API Server 2025-11-04 07:23:58,218 - DEBUG - VN ctest-vn4-94921249 is not present in Agent 10.0.0.50 2025-11-04 07:23:58,218 - INFO - Validated that VN ctest-vn4-94921249 is not in any agent 2025-11-04 07:23:58,233 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-94921249 info 2025-11-04 07:23:58,264 - INFO - Deleted policy ctest-policy1-83813204 2025-11-04 07:23:58,431 - DEBUG - policy ctest-policy1-83813204 is not found in API Server 2025-11-04 07:23:58,684 - DEBUG - No XMPP flaps were noticed during the test