2025-09-05 20:16:53,718 - INFO - Domain Default found not creating 2025-09-05 20:16:54,051 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-59439580 not found, creating it 2025-09-05 20:16:54,589 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-59439580, ID : b6dc66c7-eb06-44ff-97d9-6a925873d0e5 2025-09-05 20:16:56,493 - INFO - ================================================================================ 2025-09-05 20:16:56,494 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-05 20:16:56,812 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2025-09-05 20:16:56,813 - INFO - Initial checks done. Running the testcase now 2025-09-05 20:16:56,813 - INFO - 2025-09-05 20:16:56,813 - INFO - ================================================================================ 2025-09-05 20:16:56,813 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-05 20:16:56,813 - 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-05 20:16:57,142 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.254': '0'}} with 2025-09-05 20:16:57,142 - INFO - Initial checks done. Running the testcase now 2025-09-05 20:16:57,142 - INFO - 2025-09-05 20:16:57,558 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132, 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-59439580:ctest-vn4-32838132, 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-59439580:ctest-vn4-32838132, 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-59439580:ctest-vn4-32838132, 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-05 20:16:58,322 - DEBUG - Response for create_network : {'network': {'id': 'df966b35-ed6a-40b6-adb7-a5ee75c3ba5d', 'name': 'ctest-vn4-32838132', 'tenant_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'project_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-59439580', 'ctest-vn4-32838132'], 'port_security_enabled': True, 'description': ''}} 2025-09-05 20:16:58,502 - DEBUG - Response for create_subnet : {'subnet': {'id': '34638f9a-491c-40f3-9862-9a8be80b950c', 'name': '', 'tenant_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'network_id': 'df966b35-ed6a-40b6-adb7-a5ee75c3ba5d', 'ip_version': 4, 'cidr': '184.146.31.0/26', 'allocation_pools': [{'start': '184.146.31.2', 'end': '184.146.31.62'}], 'gateway_ip': '184.146.31.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '184.146.31.2', 'tags': [], 'project_id': 'b6dc66c7eb0644ff97d96a925873d0e5'}} 2025-09-05 20:16:58,756 - DEBUG - Response for create_subnet : {'subnet': {'id': 'f111c7fa-fd27-4470-99b1-e437166fc64f', 'name': '', 'tenant_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'network_id': 'df966b35-ed6a-40b6-adb7-a5ee75c3ba5d', 'ip_version': 6, 'cidr': '3444:6c0a:4b58:fc1c:50d1:1a55::/96', 'allocation_pools': [{'start': '3444:6c0a:4b58:fc1c:50d1:1a55:0:2', 'end': '3444:6c0a:4b58:fc1c:50d1:1a55:ffff:fffe'}], 'gateway_ip': '3444:6c0a:4b58:fc1c:50d1:1a55:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3444:6c0a:4b58:fc1c:50d1:1a55:0:2', 'tags': [], 'project_id': 'b6dc66c7eb0644ff97d96a925873d0e5'}} 2025-09-05 20:16:58,786 - INFO - Created VN ctest-vn4-32838132 2025-09-05 20:16:58,850 - DEBUG - VN ctest-vn4-32838132 UUID is df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:16:59,281 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'df966b35-ed6a-40b6-adb7-a5ee75c3ba5d', 'name': 'ctest-vn4-32838132', 'tenant_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'project_id': 'b6dc66c7eb0644ff97d96a925873d0e5', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['34638f9a-491c-40f3-9862-9a8be80b950c', 'f111c7fa-fd27-4470-99b1-e437166fc64f'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-59439580', 'ctest-vn4-32838132'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-59439580', 'ctest-policy1-51067045']], 'subnet_ipam': [{'subnet_cidr': '184.146.31.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3444:6c0a:4b58:fc1c:50d1:1a55::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-05 20:16:59,471 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-05 20:16:59,782 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-05 20:16:59,824 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a220d87a-df46-4ec0-8dde-a7b39f0ead8d 2025-09-05 20:16:59,857 - DEBUG - Requesting: http://10.0.0.38:8082/project/b6dc66c7-eb06-44ff-97d9-6a925873d0e5 2025-09-05 20:16:59,982 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,013 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,042 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:00,061 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:00,079 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/20afc589-54fe-4fcc-932a-234e709f3678 2025-09-05 20:17:00,096 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-05 20:17:00,096 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,125 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:00,168 - INFO - Verified VN network id 11 for VN df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,168 - INFO - Verifications in API Server for VN ctest-vn4-32838132 passed 2025-09-05 20:17:00,169 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,197 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:00,211 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:00,226 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/20afc589-54fe-4fcc-932a-234e709f3678 2025-09-05 20:17:00,256 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-59439580', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '16111182596325130422', 'uuid-lslong': '12517656132896143965'}, 'enable': 'true', 'created': '2025-09-05T20:16:58', 'last-modified': '2025-09-05T20:16:59', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:01.026868'} 2025-09-05 20:17:00,273 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-05 20:17:00,273 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-32838132 passed 2025-09-05 20:17:00,274 - DEBUG - ====Verifying policy data for ctest-vn4-32838132 in API_Server ====== 2025-09-05 20:17:00,274 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-05 20:17:00,284 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a220d87a-df46-4ec0-8dde-a7b39f0ead8d 2025-09-05 20:17:00,310 - DEBUG - Requesting: http://10.0.0.38:8082/project/b6dc66c7-eb06-44ff-97d9-6a925873d0e5 2025-09-05 20:17:00,422 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/df966b35-ed6a-40b6-adb7-a5ee75c3ba5d 2025-09-05 20:17:00,439 - DEBUG - ==>Verifying data for policy with id: a5bcdae3-f504-455e-8c14-45dcd8cb4a91, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-59439580', 'ctest-policy1-51067045'] 2025-09-05 20:17:00,439 - INFO - VN ctest-vn4-32838132 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-05 20:17:00,440 - DEBUG - Verifying the vn in opserver 2025-09-05 20:17:00,440 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132 virtual network link through opserver 10.0.0.38 2025-09-05 20:17:00,440 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-09-05 20:17:00,749 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-09-05 20:17:00,829 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132?flat'} 2025-09-05 20:17:00,830 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-59439580:ctest-vn4-32838132 is found in opserver 2025-09-05 20:17:00,851 - DEBUG - Do not have enough data to verify VN in agent 2025-09-05 20:17:00,863 - DEBUG - VRF ids for VN ctest-vn4-32838132: {} 2025-09-05 20:17:00,864 - DEBUG - ====Verifying data for ctest-policy1-51067045 in API_Server ====== 2025-09-05 20:17:00,864 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-05 20:17:00,878 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a220d87a-df46-4ec0-8dde-a7b39f0ead8d 2025-09-05 20:17:00,907 - DEBUG - Requesting: http://10.0.0.38:8082/project/b6dc66c7-eb06-44ff-97d9-6a925873d0e5 2025-09-05 20:17:01,005 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/a5bcdae3-f504-455e-8c14-45dcd8cb4a91 2025-09-05 20:17:01,026 - INFO - Verified policy ctest-policy1-51067045 in API Server, Result: True 2025-09-05 20:17:01,026 - INFO - Done with setup and verification, moving onto test .. 2025-09-05 20:17:01,039 - INFO - Deleting VN ctest-vn4-32838132 2025-09-05 20:17:01,297 - DEBUG - Response for deleting network () 2025-09-05 20:17:01,297 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/6876703d-bdd6-4378-9873-311ec1402366 2025-09-05 20:17:01,303 - DEBUG - Response Code: 404 2025-09-05 20:17:01,303 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-09-05 20:17:01,309 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a220d87a-df46-4ec0-8dde-a7b39f0ead8d 2025-09-05 20:17:01,366 - DEBUG - Requesting: http://10.0.0.38:8082/project/b6dc66c7-eb06-44ff-97d9-6a925873d0e5 2025-09-05 20:17:01,467 - INFO - Validated that VN ctest-vn4-32838132 is not found in API Server 2025-09-05 20:17:01,490 - DEBUG - VN ctest-vn4-32838132 is not present in Agent 10.0.0.38 2025-09-05 20:17:01,490 - INFO - Validated that VN ctest-vn4-32838132 is not in any agent 2025-09-05 20:17:01,527 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-32838132 info 2025-09-05 20:17:01,601 - INFO - Deleted policy ctest-policy1-51067045 2025-09-05 20:17:01,794 - DEBUG - policy ctest-policy1-51067045 is not found in API Server 2025-09-05 20:17:02,110 - DEBUG - No XMPP flaps were noticed during the test 2025-09-05 20:17:02,111 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:06] 2025-09-05 20:17:02,111 - INFO - -------------------------------------------------------------------------------- 2025-09-05 20:17:02,448 - DEBUG - No XMPP flaps were noticed during the test 2025-09-05 20:17:02,449 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:06] 2025-09-05 20:17:02,449 - INFO - -------------------------------------------------------------------------------- 2025-09-05 20:17:03,386 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-59439580, ID : b6dc66c7-eb06-44ff-97d9-6a925873d0e5