2026-01-20 16:06:45,252 - INFO - Domain Default found not creating 2026-01-20 16:06:45,419 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-91237270 not found, creating it 2026-01-20 16:06:45,911 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-91237270, ID : 79528e43-94a0-42ba-ab1a-8e13597d7619 2026-01-20 16:06:47,410 - INFO - ================================================================================ 2026-01-20 16:06:47,410 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-20 16:06:47,663 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.14': '0'}} with 2026-01-20 16:06:47,663 - INFO - Initial checks done. Running the testcase now 2026-01-20 16:06:47,663 - INFO - 2026-01-20 16:06:47,663 - INFO - ================================================================================ 2026-01-20 16:06:47,663 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-20 16:06:47,663 - 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-20 16:06:47,951 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.14': '0'}} with 2026-01-20 16:06:47,951 - INFO - Initial checks done. Running the testcase now 2026-01-20 16:06:47,951 - INFO - 2026-01-20 16:06:48,315 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351, 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-91237270:ctest-vn4-67412351, 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-91237270:ctest-vn4-67412351, 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-91237270:ctest-vn4-67412351, 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-20 16:06:48,839 - DEBUG - Response for create_network : {'network': {'id': '9eb6cc9f-c540-4053-a28e-2cb79a1518b5', 'name': 'ctest-vn4-67412351', 'tenant_id': '79528e4394a042baab1a8e13597d7619', 'project_id': '79528e4394a042baab1a8e13597d7619', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-91237270', 'ctest-vn4-67412351'], 'port_security_enabled': True, 'description': ''}} 2026-01-20 16:06:48,987 - DEBUG - Response for create_subnet : {'subnet': {'id': '628f64d5-7f6e-400e-9e91-063358c89039', 'name': '', 'tenant_id': '79528e4394a042baab1a8e13597d7619', 'network_id': '9eb6cc9f-c540-4053-a28e-2cb79a1518b5', 'ip_version': 4, 'cidr': '58.59.212.0/26', 'allocation_pools': [{'start': '58.59.212.2', 'end': '58.59.212.62'}], 'gateway_ip': '58.59.212.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '58.59.212.2', 'tags': [], 'project_id': '79528e4394a042baab1a8e13597d7619'}} 2026-01-20 16:06:49,183 - DEBUG - Response for create_subnet : {'subnet': {'id': '62d4678e-f531-4415-b603-e9bd1a90c65c', 'name': '', 'tenant_id': '79528e4394a042baab1a8e13597d7619', 'network_id': '9eb6cc9f-c540-4053-a28e-2cb79a1518b5', 'ip_version': 6, 'cidr': '2bbe:683f:564c:b99d:bb4a:b202::/96', 'allocation_pools': [{'start': '2bbe:683f:564c:b99d:bb4a:b202:0:2', 'end': '2bbe:683f:564c:b99d:bb4a:b202:ffff:fffe'}], 'gateway_ip': '2bbe:683f:564c:b99d:bb4a:b202:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2bbe:683f:564c:b99d:bb4a:b202:0:2', 'tags': [], 'project_id': '79528e4394a042baab1a8e13597d7619'}} 2026-01-20 16:06:49,204 - INFO - Created VN ctest-vn4-67412351 2026-01-20 16:06:49,258 - DEBUG - VN ctest-vn4-67412351 UUID is 9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:49,461 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '9eb6cc9f-c540-4053-a28e-2cb79a1518b5', 'name': 'ctest-vn4-67412351', 'tenant_id': '79528e4394a042baab1a8e13597d7619', 'project_id': '79528e4394a042baab1a8e13597d7619', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['628f64d5-7f6e-400e-9e91-063358c89039', '62d4678e-f531-4415-b603-e9bd1a90c65c'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-91237270', 'ctest-vn4-67412351'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-91237270', 'ctest-policy1-06405252']], 'subnet_ipam': [{'subnet_cidr': '58.59.212.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2bbe:683f:564c:b99d:bb4a:b202::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-01-20 16:06:49,626 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-01-20 16:06:49,920 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-01-20 16:06:49,952 - DEBUG - Requesting: http://10.0.0.249:8082/domain/1468b355-74b5-4efb-b99e-aa824e64b549 2026-01-20 16:06:49,964 - DEBUG - Requesting: http://10.0.0.249:8082/project/79528e43-94a0-42ba-ab1a-8e13597d7619 2026-01-20 16:06:50,044 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,056 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,065 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,071 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,078 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/69f263c1-c03e-49f0-b0da-d8edd8e345c8 2026-01-20 16:06:50,085 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-20 16:06:50,085 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,096 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,112 - INFO - Verified VN network id 11 for VN 9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,112 - INFO - Verifications in API Server for VN ctest-vn4-67412351 passed 2026-01-20 16:06:50,112 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,122 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,129 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,136 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/69f263c1-c03e-49f0-b0da-d8edd8e345c8 2026-01-20 16:06:50,147 - DEBUG - Control-node 10.0.0.249 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-91237270', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '11436553290335141971', 'uuid-lslong': '11713348847912949941'}, 'enable': 'true', 'created': '2026-01-20T16:06:48', 'last-modified': '2026-01-20T16:06:49', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.714925'} 2026-01-20 16:06:50,153 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-20 16:06:50,153 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-67412351 passed 2026-01-20 16:06:50,153 - DEBUG - ====Verifying policy data for ctest-vn4-67412351 in API_Server ====== 2026-01-20 16:06:50,153 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-01-20 16:06:50,158 - DEBUG - Requesting: http://10.0.0.249:8082/domain/1468b355-74b5-4efb-b99e-aa824e64b549 2026-01-20 16:06:50,169 - DEBUG - Requesting: http://10.0.0.249:8082/project/79528e43-94a0-42ba-ab1a-8e13597d7619 2026-01-20 16:06:50,237 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/9eb6cc9f-c540-4053-a28e-2cb79a1518b5 2026-01-20 16:06:50,248 - DEBUG - ==>Verifying data for policy with id: 4dc8b33d-1343-443e-9b3d-bcc3979d5d83, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-91237270', 'ctest-policy1-06405252'] 2026-01-20 16:06:50,248 - INFO - VN ctest-vn4-67412351 Policy verification: verify_vn_policy_in_api_server, status: True 2026-01-20 16:06:50,248 - DEBUG - Verifying the vn in opserver 2026-01-20 16:06:50,248 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351 virtual network link through opserver 10.0.0.249 2026-01-20 16:06:50,249 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2026-01-20 16:06:50,545 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2026-01-20 16:06:50,608 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351', 'href': 'http://10.0.0.249:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351?flat'} 2026-01-20 16:06:50,608 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-91237270:ctest-vn4-67412351 is found in opserver 2026-01-20 16:06:50,617 - DEBUG - Do not have enough data to verify VN in agent 2026-01-20 16:06:50,621 - DEBUG - VRF ids for VN ctest-vn4-67412351: {} 2026-01-20 16:06:50,621 - DEBUG - ====Verifying data for ctest-policy1-06405252 in API_Server ====== 2026-01-20 16:06:50,621 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-01-20 16:06:50,626 - DEBUG - Requesting: http://10.0.0.249:8082/domain/1468b355-74b5-4efb-b99e-aa824e64b549 2026-01-20 16:06:50,637 - DEBUG - Requesting: http://10.0.0.249:8082/project/79528e43-94a0-42ba-ab1a-8e13597d7619 2026-01-20 16:06:50,711 - DEBUG - Requesting: http://10.0.0.249:8082/network-policy/4dc8b33d-1343-443e-9b3d-bcc3979d5d83 2026-01-20 16:06:50,720 - INFO - Verified policy ctest-policy1-06405252 in API Server, Result: True 2026-01-20 16:06:50,720 - INFO - Done with setup and verification, moving onto test .. 2026-01-20 16:06:50,727 - INFO - Deleting VN ctest-vn4-67412351 2026-01-20 16:06:50,854 - DEBUG - Response for deleting network () 2026-01-20 16:06:50,854 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/5f834bf2-0191-4258-b185-730595f18086 2026-01-20 16:06:50,859 - DEBUG - Response Code: 404 2026-01-20 16:06:50,859 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-01-20 16:06:50,864 - DEBUG - Requesting: http://10.0.0.249:8082/domain/1468b355-74b5-4efb-b99e-aa824e64b549 2026-01-20 16:06:50,919 - DEBUG - Requesting: http://10.0.0.249:8082/project/79528e43-94a0-42ba-ab1a-8e13597d7619 2026-01-20 16:06:50,989 - INFO - Validated that VN ctest-vn4-67412351 is not found in API Server 2026-01-20 16:06:50,999 - DEBUG - VN ctest-vn4-67412351 is not present in Agent 10.0.0.249 2026-01-20 16:06:51,000 - INFO - Validated that VN ctest-vn4-67412351 is not in any agent 2026-01-20 16:06:51,015 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-67412351 info 2026-01-20 16:06:51,041 - INFO - Deleted policy ctest-policy1-06405252 2026-01-20 16:06:51,202 - DEBUG - policy ctest-policy1-06405252 is not found in API Server 2026-01-20 16:06:51,454 - DEBUG - No XMPP flaps were noticed during the test 2026-01-20 16:06:51,454 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-01-20 16:06:51,454 - INFO - -------------------------------------------------------------------------------- 2026-01-20 16:06:51,743 - DEBUG - No XMPP flaps were noticed during the test 2026-01-20 16:06:51,743 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2026-01-20 16:06:51,743 - INFO - -------------------------------------------------------------------------------- 2026-01-20 16:06:52,420 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-91237270, ID : 79528e43-94a0-42ba-ab1a-8e13597d7619