2026-04-21 10:00:17,883 - INFO - Domain Default found not creating 2026-04-21 10:00:18,090 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-88175283 not found, creating it 2026-04-21 10:00:18,647 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-88175283, ID : 158c7c29-4eff-42ed-8408-29805e6fa242 2026-04-21 10:00:20,330 - INFO - ================================================================================ 2026-04-21 10:00:20,331 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-21 10:00:20,603 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-04-21 10:00:20,603 - INFO - Initial checks done. Running the testcase now 2026-04-21 10:00:20,603 - INFO - 2026-04-21 10:00:20,603 - INFO - ================================================================================ 2026-04-21 10:00:20,603 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-21 10:00:20,603 - 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-04-21 10:00:20,897 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2026-04-21 10:00:20,898 - INFO - Initial checks done. Running the testcase now 2026-04-21 10:00:20,898 - INFO - 2026-04-21 10:00:21,281 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320, 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-88175283:ctest-vn4-69517320, 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-88175283:ctest-vn4-69517320, 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-88175283:ctest-vn4-69517320, 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-04-21 10:00:21,839 - DEBUG - Response for create_network : {'network': {'id': '6e18ed3d-db49-4483-805f-5e336268213b', 'name': 'ctest-vn4-69517320', 'tenant_id': '158c7c294eff42ed840829805e6fa242', 'project_id': '158c7c294eff42ed840829805e6fa242', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-88175283', 'ctest-vn4-69517320'], 'port_security_enabled': True, 'description': ''}} 2026-04-21 10:00:22,019 - DEBUG - Response for create_subnet : {'subnet': {'id': '840c953d-921b-40bd-bb36-455bfef5cbdc', 'name': '', 'tenant_id': '158c7c294eff42ed840829805e6fa242', 'network_id': '6e18ed3d-db49-4483-805f-5e336268213b', 'ip_version': 4, 'cidr': '46.63.198.128/26', 'allocation_pools': [{'start': '46.63.198.130', 'end': '46.63.198.190'}], 'gateway_ip': '46.63.198.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '46.63.198.130', 'tags': [], 'project_id': '158c7c294eff42ed840829805e6fa242'}} 2026-04-21 10:00:22,195 - DEBUG - Response for create_subnet : {'subnet': {'id': 'ef08a2b0-091c-4306-879f-de715b05d57e', 'name': '', 'tenant_id': '158c7c294eff42ed840829805e6fa242', 'network_id': '6e18ed3d-db49-4483-805f-5e336268213b', 'ip_version': 6, 'cidr': '20c4:366a:42b6:c89f:bb89:2cb7::/96', 'allocation_pools': [{'start': '20c4:366a:42b6:c89f:bb89:2cb7:0:2', 'end': '20c4:366a:42b6:c89f:bb89:2cb7:ffff:fffe'}], 'gateway_ip': '20c4:366a:42b6:c89f:bb89:2cb7:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '20c4:366a:42b6:c89f:bb89:2cb7:0:2', 'tags': [], 'project_id': '158c7c294eff42ed840829805e6fa242'}} 2026-04-21 10:00:22,220 - INFO - Created VN ctest-vn4-69517320 2026-04-21 10:00:22,278 - DEBUG - VN ctest-vn4-69517320 UUID is 6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:22,517 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '6e18ed3d-db49-4483-805f-5e336268213b', 'name': 'ctest-vn4-69517320', 'tenant_id': '158c7c294eff42ed840829805e6fa242', 'project_id': '158c7c294eff42ed840829805e6fa242', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['840c953d-921b-40bd-bb36-455bfef5cbdc', 'ef08a2b0-091c-4306-879f-de715b05d57e'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-88175283', 'ctest-vn4-69517320'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-88175283', 'ctest-policy1-36272857']], 'subnet_ipam': [{'subnet_cidr': '46.63.198.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '20c4:366a:42b6:c89f:bb89:2cb7::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-04-21 10:00:22,694 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-21 10:00:22,997 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-21 10:00:23,041 - DEBUG - Requesting: http://10.0.0.38:8082/domain/f9ef1414-5d8a-4c7b-a71e-d0b6e1ef50ce 2026-04-21 10:00:23,060 - DEBUG - Requesting: http://10.0.0.38:8082/project/158c7c29-4eff-42ed-8408-29805e6fa242 2026-04-21 10:00:23,138 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,154 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,165 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:23,173 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:23,182 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/ddab7c1a-bbb4-4106-9bc7-9425e627b43e 2026-04-21 10:00:23,189 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-21 10:00:23,189 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,202 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:23,219 - INFO - Verified VN network id 12 for VN 6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,219 - INFO - Verifications in API Server for VN ctest-vn4-69517320 passed 2026-04-21 10:00:23,219 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,231 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:23,239 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:23,250 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/ddab7c1a-bbb4-4106-9bc7-9425e627b43e 2026-04-21 10:00:23,268 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-88175283', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '7933351593540928643', 'uuid-lslong': '9250215734429622587'}, 'enable': 'true', 'created': '2026-04-21T10:00:21', 'last-modified': '2026-04-21T10:00:22', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.774276'} 2026-04-21 10:00:23,274 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-21 10:00:23,274 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-69517320 passed 2026-04-21 10:00:23,274 - DEBUG - ====Verifying policy data for ctest-vn4-69517320 in API_Server ====== 2026-04-21 10:00:23,275 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-21 10:00:23,281 - DEBUG - Requesting: http://10.0.0.38:8082/domain/f9ef1414-5d8a-4c7b-a71e-d0b6e1ef50ce 2026-04-21 10:00:23,295 - DEBUG - Requesting: http://10.0.0.38:8082/project/158c7c29-4eff-42ed-8408-29805e6fa242 2026-04-21 10:00:23,372 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/6e18ed3d-db49-4483-805f-5e336268213b 2026-04-21 10:00:23,385 - DEBUG - ==>Verifying data for policy with id: d1a4ab7a-ed92-4255-97e8-2ff6c2abadef, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-88175283', 'ctest-policy1-36272857'] 2026-04-21 10:00:23,385 - INFO - VN ctest-vn4-69517320 Policy verification: verify_vn_policy_in_api_server, status: True 2026-04-21 10:00:23,385 - DEBUG - Verifying the vn in opserver 2026-04-21 10:00:23,385 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320 virtual network link through opserver 10.0.0.38 2026-04-21 10:00:23,385 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-04-21 10:00:23,687 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2026-04-21 10:00:23,771 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320?flat'} 2026-04-21 10:00:23,771 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-88175283:ctest-vn4-69517320 is found in opserver 2026-04-21 10:00:23,784 - DEBUG - Do not have enough data to verify VN in agent 2026-04-21 10:00:23,791 - DEBUG - VRF ids for VN ctest-vn4-69517320: {} 2026-04-21 10:00:23,791 - DEBUG - ====Verifying data for ctest-policy1-36272857 in API_Server ====== 2026-04-21 10:00:23,791 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-21 10:00:23,800 - DEBUG - Requesting: http://10.0.0.38:8082/domain/f9ef1414-5d8a-4c7b-a71e-d0b6e1ef50ce 2026-04-21 10:00:23,817 - DEBUG - Requesting: http://10.0.0.38:8082/project/158c7c29-4eff-42ed-8408-29805e6fa242 2026-04-21 10:00:23,896 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/d1a4ab7a-ed92-4255-97e8-2ff6c2abadef 2026-04-21 10:00:23,906 - INFO - Verified policy ctest-policy1-36272857 in API Server, Result: True 2026-04-21 10:00:23,907 - INFO - Done with setup and verification, moving onto test .. 2026-04-21 10:00:23,917 - INFO - Deleting VN ctest-vn4-69517320 2026-04-21 10:00:24,070 - DEBUG - Response for deleting network () 2026-04-21 10:00:24,070 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/9830622d-6934-40eb-9c78-6335a3fa1717 2026-04-21 10:00:24,077 - DEBUG - Response Code: 404 2026-04-21 10:00:24,077 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2026-04-21 10:00:24,085 - DEBUG - Requesting: http://10.0.0.38:8082/domain/f9ef1414-5d8a-4c7b-a71e-d0b6e1ef50ce 2026-04-21 10:00:24,140 - DEBUG - Requesting: http://10.0.0.38:8082/project/158c7c29-4eff-42ed-8408-29805e6fa242 2026-04-21 10:00:24,219 - INFO - Validated that VN ctest-vn4-69517320 is not found in API Server 2026-04-21 10:00:24,230 - DEBUG - VN ctest-vn4-69517320 is not present in Agent 10.0.0.38 2026-04-21 10:00:24,231 - INFO - Validated that VN ctest-vn4-69517320 is not in any agent 2026-04-21 10:00:24,248 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-69517320 info 2026-04-21 10:00:24,284 - INFO - Deleted policy ctest-policy1-36272857 2026-04-21 10:00:24,465 - DEBUG - policy ctest-policy1-36272857 is not found in API Server 2026-04-21 10:00:24,726 - DEBUG - No XMPP flaps were noticed during the test 2026-04-21 10:00:24,726 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-04-21 10:00:24,726 - INFO - -------------------------------------------------------------------------------- 2026-04-21 10:00:25,020 - DEBUG - No XMPP flaps were noticed during the test 2026-04-21 10:00:25,021 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2026-04-21 10:00:25,021 - INFO - -------------------------------------------------------------------------------- 2026-04-21 10:00:25,764 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-88175283, ID : 158c7c29-4eff-42ed-8408-29805e6fa242