2026-01-09 16:01:14,108 - INFO - Domain Default found not creating 2026-01-09 16:01:14,287 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-92060836 not found, creating it 2026-01-09 16:01:14,768 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-92060836, ID : 84ad1aa9-1123-4cdb-9859-5f618b66041c 2026-01-09 16:01:16,238 - INFO - ================================================================================ 2026-01-09 16:01:16,238 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-09 16:01:16,492 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-01-09 16:01:16,492 - INFO - Initial checks done. Running the testcase now 2026-01-09 16:01:16,492 - INFO - 2026-01-09 16:01:16,492 - INFO - ================================================================================ 2026-01-09 16:01:16,493 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-09 16:01:16,493 - 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. 2026-01-09 16:01:16,784 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-01-09 16:01:16,784 - INFO - Initial checks done. Running the testcase now 2026-01-09 16:01:16,784 - INFO - 2026-01-09 16:01:17,145 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504, 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-92060836:ctest-vn4-82393504, 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-92060836:ctest-vn4-82393504, 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-92060836:ctest-vn4-82393504, 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] 2026-01-09 16:01:17,662 - DEBUG - Response for create_network : {'network': {'id': '334c3e59-253a-4f28-a670-50130fff4699', 'name': 'ctest-vn4-82393504', 'tenant_id': '84ad1aa911234cdb98595f618b66041c', 'project_id': '84ad1aa911234cdb98595f618b66041c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-92060836', 'ctest-vn4-82393504'], 'port_security_enabled': True, 'description': ''}} 2026-01-09 16:01:17,889 - DEBUG - Response for create_subnet : {'subnet': {'id': 'f519bfa0-61fe-4f56-bc6b-f0dc7155ae55', 'name': '', 'tenant_id': '84ad1aa911234cdb98595f618b66041c', 'network_id': '334c3e59-253a-4f28-a670-50130fff4699', 'ip_version': 4, 'cidr': '147.70.204.0/26', 'allocation_pools': [{'start': '147.70.204.2', 'end': '147.70.204.62'}], 'gateway_ip': '147.70.204.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '147.70.204.2', 'tags': [], 'project_id': '84ad1aa911234cdb98595f618b66041c'}} 2026-01-09 16:01:18,071 - DEBUG - Response for create_subnet : {'subnet': {'id': '394e1cc9-8a75-421a-8751-d015a46fb31a', 'name': '', 'tenant_id': '84ad1aa911234cdb98595f618b66041c', 'network_id': '334c3e59-253a-4f28-a670-50130fff4699', 'ip_version': 6, 'cidr': '2791:258f:a38f:5b5e:1881:a524::/96', 'allocation_pools': [{'start': '2791:258f:a38f:5b5e:1881:a524:0:2', 'end': '2791:258f:a38f:5b5e:1881:a524:ffff:fffe'}], 'gateway_ip': '2791:258f:a38f:5b5e:1881:a524:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2791:258f:a38f:5b5e:1881:a524:0:2', 'tags': [], 'project_id': '84ad1aa911234cdb98595f618b66041c'}} 2026-01-09 16:01:18,091 - INFO - Created VN ctest-vn4-82393504 2026-01-09 16:01:18,143 - DEBUG - VN ctest-vn4-82393504 UUID is 334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,342 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '334c3e59-253a-4f28-a670-50130fff4699', 'name': 'ctest-vn4-82393504', 'tenant_id': '84ad1aa911234cdb98595f618b66041c', 'project_id': '84ad1aa911234cdb98595f618b66041c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['f519bfa0-61fe-4f56-bc6b-f0dc7155ae55', '394e1cc9-8a75-421a-8751-d015a46fb31a'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-92060836', 'ctest-vn4-82393504'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-92060836', 'ctest-policy1-88968053']], 'subnet_ipam': [{'subnet_cidr': '147.70.204.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2791:258f:a38f:5b5e:1881:a524::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-01-09 16:01:18,495 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-01-09 16:01:18,787 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-01-09 16:01:18,817 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a3ca9cd7-63c0-45e2-a704-54d5ebd478e3 2026-01-09 16:01:18,830 - DEBUG - Requesting: http://10.0.0.38:8082/project/84ad1aa9-1123-4cdb-9859-5f618b66041c 2026-01-09 16:01:18,902 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,913 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,922 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:18,928 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:18,936 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/d84aab98-6958-4b5d-821b-cb44208fac7d 2026-01-09 16:01:18,942 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-09 16:01:18,942 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,951 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:18,968 - INFO - Verified VN network id 11 for VN 334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,968 - INFO - Verifications in API Server for VN ctest-vn4-82393504 passed 2026-01-09 16:01:18,968 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:18,978 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:18,985 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:18,992 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/d84aab98-6958-4b5d-821b-cb44208fac7d 2026-01-09 16:01:19,003 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-92060836', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '3696397946761924392', 'uuid-lslong': '11993173850490619545'}, 'enable': 'true', 'created': '2026-01-09T16:01:17', 'last-modified': '2026-01-09T16:01:18', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.686706'} 2026-01-09 16:01:19,009 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-09 16:01:19,009 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-82393504 passed 2026-01-09 16:01:19,009 - DEBUG - ====Verifying policy data for ctest-vn4-82393504 in API_Server ====== 2026-01-09 16:01:19,010 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-01-09 16:01:19,017 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a3ca9cd7-63c0-45e2-a704-54d5ebd478e3 2026-01-09 16:01:19,028 - DEBUG - Requesting: http://10.0.0.38:8082/project/84ad1aa9-1123-4cdb-9859-5f618b66041c 2026-01-09 16:01:19,103 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/334c3e59-253a-4f28-a670-50130fff4699 2026-01-09 16:01:19,115 - DEBUG - ==>Verifying data for policy with id: 9ac8cbb9-2c68-49cc-a028-b1a11291a2fe, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-92060836', 'ctest-policy1-88968053'] 2026-01-09 16:01:19,116 - INFO - VN ctest-vn4-82393504 Policy verification: verify_vn_policy_in_api_server, status: True 2026-01-09 16:01:19,116 - DEBUG - Verifying the vn in opserver 2026-01-09 16:01:19,116 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504 virtual network link through opserver 10.0.0.38 2026-01-09 16:01:19,116 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-01-09 16:01:19,411 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-01-09 16:01:19,478 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504?flat'} 2026-01-09 16:01:19,478 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-92060836:ctest-vn4-82393504 is found in opserver 2026-01-09 16:01:19,487 - DEBUG - Do not have enough data to verify VN in agent 2026-01-09 16:01:19,493 - DEBUG - VRF ids for VN ctest-vn4-82393504: {} 2026-01-09 16:01:19,493 - DEBUG - ====Verifying data for ctest-policy1-88968053 in API_Server ====== 2026-01-09 16:01:19,493 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-01-09 16:01:19,499 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a3ca9cd7-63c0-45e2-a704-54d5ebd478e3 2026-01-09 16:01:19,511 - DEBUG - Requesting: http://10.0.0.38:8082/project/84ad1aa9-1123-4cdb-9859-5f618b66041c 2026-01-09 16:01:19,580 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/9ac8cbb9-2c68-49cc-a028-b1a11291a2fe 2026-01-09 16:01:19,589 - INFO - Verified policy ctest-policy1-88968053 in API Server, Result: True 2026-01-09 16:01:19,589 - INFO - Done with setup and verification, moving onto test .. 2026-01-09 16:01:19,597 - INFO - Deleting VN ctest-vn4-82393504 2026-01-09 16:01:19,716 - DEBUG - Response for deleting network () 2026-01-09 16:01:19,717 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/72789c18-a046-41fd-ae26-5a16e1ab9150 2026-01-09 16:01:19,721 - DEBUG - Response Code: 404 2026-01-09 16:01:19,722 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-01-09 16:01:19,726 - DEBUG - Requesting: http://10.0.0.38:8082/domain/a3ca9cd7-63c0-45e2-a704-54d5ebd478e3 2026-01-09 16:01:19,780 - DEBUG - Requesting: http://10.0.0.38:8082/project/84ad1aa9-1123-4cdb-9859-5f618b66041c 2026-01-09 16:01:19,852 - INFO - Validated that VN ctest-vn4-82393504 is not found in API Server 2026-01-09 16:01:19,861 - DEBUG - VN ctest-vn4-82393504 is not present in Agent 10.0.0.38 2026-01-09 16:01:19,861 - INFO - Validated that VN ctest-vn4-82393504 is not in any agent 2026-01-09 16:01:19,875 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-82393504 info 2026-01-09 16:01:19,902 - INFO - Deleted policy ctest-policy1-88968053 2026-01-09 16:01:20,067 - DEBUG - policy ctest-policy1-88968053 is not found in API Server 2026-01-09 16:01:20,320 - DEBUG - No XMPP flaps were noticed during the test 2026-01-09 16:01:20,320 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-01-09 16:01:20,320 - INFO - -------------------------------------------------------------------------------- 2026-01-09 16:01:20,619 - DEBUG - No XMPP flaps were noticed during the test 2026-01-09 16:01:20,619 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-01-09 16:01:20,619 - INFO - -------------------------------------------------------------------------------- 2026-01-09 16:01:21,315 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-92060836, ID : 84ad1aa9-1123-4cdb-9859-5f618b66041c