2025-09-23 20:35:57,484 - INFO - Domain Default found not creating 2025-09-23 20:35:57,858 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-25561076 not found, creating it 2025-09-23 20:35:58,646 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-25561076, ID : 0694af17-e046-4f69-8161-a70926b4f5d3 2025-09-23 20:36:00,881 - INFO - ================================================================================ 2025-09-23 20:36:00,882 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-23 20:36:01,193 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.17': '0'}} with 2025-09-23 20:36:01,193 - INFO - Initial checks done. Running the testcase now 2025-09-23 20:36:01,194 - INFO - 2025-09-23 20:36:01,194 - INFO - ================================================================================ 2025-09-23 20:36:01,194 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-23 20:36:01,194 - 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-23 20:36:01,532 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.17': '0'}} with 2025-09-23 20:36:01,533 - INFO - Initial checks done. Running the testcase now 2025-09-23 20:36:01,533 - INFO - 2025-09-23 20:36:01,937 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901, 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-25561076:ctest-vn4-44238901, 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-25561076:ctest-vn4-44238901, 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-25561076:ctest-vn4-44238901, 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-23 20:36:02,711 - DEBUG - Response for create_network : {'network': {'id': 'c485f865-1190-440d-8e20-988adce9e893', 'name': 'ctest-vn4-44238901', 'tenant_id': '0694af17e0464f698161a70926b4f5d3', 'project_id': '0694af17e0464f698161a70926b4f5d3', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-25561076', 'ctest-vn4-44238901'], 'port_security_enabled': True, 'description': ''}} 2025-09-23 20:36:02,966 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a2ac5be7-b38d-4999-8acf-4782807b6fea', 'name': '', 'tenant_id': '0694af17e0464f698161a70926b4f5d3', 'network_id': 'c485f865-1190-440d-8e20-988adce9e893', 'ip_version': 4, 'cidr': '157.250.168.128/26', 'allocation_pools': [{'start': '157.250.168.130', 'end': '157.250.168.190'}], 'gateway_ip': '157.250.168.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '157.250.168.130', 'tags': [], 'project_id': '0694af17e0464f698161a70926b4f5d3'}} 2025-09-23 20:36:03,204 - DEBUG - Response for create_subnet : {'subnet': {'id': '81851019-a8d5-464a-b217-7a028f2c437b', 'name': '', 'tenant_id': '0694af17e0464f698161a70926b4f5d3', 'network_id': 'c485f865-1190-440d-8e20-988adce9e893', 'ip_version': 6, 'cidr': '2251:809c:7129:265c:dd82:176::/96', 'allocation_pools': [{'start': '2251:809c:7129:265c:dd82:176:0:2', 'end': '2251:809c:7129:265c:dd82:176:ffff:fffe'}], 'gateway_ip': '2251:809c:7129:265c:dd82:176:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2251:809c:7129:265c:dd82:176:0:2', 'tags': [], 'project_id': '0694af17e0464f698161a70926b4f5d3'}} 2025-09-23 20:36:03,238 - INFO - Created VN ctest-vn4-44238901 2025-09-23 20:36:03,304 - DEBUG - VN ctest-vn4-44238901 UUID is c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:03,680 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'c485f865-1190-440d-8e20-988adce9e893', 'name': 'ctest-vn4-44238901', 'tenant_id': '0694af17e0464f698161a70926b4f5d3', 'project_id': '0694af17e0464f698161a70926b4f5d3', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['a2ac5be7-b38d-4999-8acf-4782807b6fea', '81851019-a8d5-464a-b217-7a028f2c437b'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-25561076', 'ctest-vn4-44238901'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-25561076', 'ctest-policy1-24649121']], 'subnet_ipam': [{'subnet_cidr': '157.250.168.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2251:809c:7129:265c:dd82:176::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-23 20:36:03,887 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-09-23 20:36:04,248 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-09-23 20:36:04,278 - DEBUG - Requesting: http://10.0.0.48:8082/domain/0e306419-b187-46e7-a5cc-c5c009990e70 2025-09-23 20:36:04,294 - DEBUG - Requesting: http://10.0.0.48:8082/project/0694af17-e046-4f69-8161-a70926b4f5d3 2025-09-23 20:36:04,389 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,405 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,424 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:04,435 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:04,444 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/ddf02efc-fa34-403c-acfb-2652b40e043b 2025-09-23 20:36:04,452 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-23 20:36:04,452 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,464 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:04,482 - INFO - Verified VN network id 11 for VN c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,483 - INFO - Verifications in API Server for VN ctest-vn4-44238901 passed 2025-09-23 20:36:04,483 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,500 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:04,513 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:04,526 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/ddf02efc-fa34-403c-acfb-2652b40e043b 2025-09-23 20:36:04,548 - DEBUG - Control-node 10.0.0.48 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-25561076', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '14160997716306445325', 'uuid-lslong': '10241353274819733651'}, 'enable': 'true', 'created': '2025-09-23T20:36:02', 'last-modified': '2025-09-23T20:36:03', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.929251'} 2025-09-23 20:36:04,560 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-23 20:36:04,560 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-44238901 passed 2025-09-23 20:36:04,561 - DEBUG - ====Verifying policy data for ctest-vn4-44238901 in API_Server ====== 2025-09-23 20:36:04,561 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-09-23 20:36:04,570 - DEBUG - Requesting: http://10.0.0.48:8082/domain/0e306419-b187-46e7-a5cc-c5c009990e70 2025-09-23 20:36:04,592 - DEBUG - Requesting: http://10.0.0.48:8082/project/0694af17-e046-4f69-8161-a70926b4f5d3 2025-09-23 20:36:04,694 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/c485f865-1190-440d-8e20-988adce9e893 2025-09-23 20:36:04,707 - DEBUG - ==>Verifying data for policy with id: 39b17c39-41cc-4eb3-8fe3-df0c81d6856c, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-25561076', 'ctest-policy1-24649121'] 2025-09-23 20:36:04,707 - INFO - VN ctest-vn4-44238901 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-23 20:36:04,707 - DEBUG - Verifying the vn in opserver 2025-09-23 20:36:04,707 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901 virtual network link through opserver 10.0.0.48 2025-09-23 20:36:04,707 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-09-23 20:36:05,024 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-09-23 20:36:05,147 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901', 'href': 'http://10.0.0.48:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901?flat'} 2025-09-23 20:36:05,147 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-25561076:ctest-vn4-44238901 is found in opserver 2025-09-23 20:36:05,176 - DEBUG - Do not have enough data to verify VN in agent 2025-09-23 20:36:05,189 - DEBUG - VRF ids for VN ctest-vn4-44238901: {} 2025-09-23 20:36:05,190 - DEBUG - ====Verifying data for ctest-policy1-24649121 in API_Server ====== 2025-09-23 20:36:05,191 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-09-23 20:36:05,200 - DEBUG - Requesting: http://10.0.0.48:8082/domain/0e306419-b187-46e7-a5cc-c5c009990e70 2025-09-23 20:36:05,223 - DEBUG - Requesting: http://10.0.0.48:8082/project/0694af17-e046-4f69-8161-a70926b4f5d3 2025-09-23 20:36:05,314 - DEBUG - Requesting: http://10.0.0.48:8082/network-policy/39b17c39-41cc-4eb3-8fe3-df0c81d6856c 2025-09-23 20:36:05,331 - INFO - Verified policy ctest-policy1-24649121 in API Server, Result: True 2025-09-23 20:36:05,331 - INFO - Done with setup and verification, moving onto test .. 2025-09-23 20:36:05,347 - INFO - Deleting VN ctest-vn4-44238901 2025-09-23 20:36:05,508 - DEBUG - Response for deleting network () 2025-09-23 20:36:05,508 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/0ec5395a-d4c8-4dbf-9032-0bac8385477f 2025-09-23 20:36:05,513 - DEBUG - Response Code: 404 2025-09-23 20:36:05,513 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-09-23 20:36:05,518 - DEBUG - Requesting: http://10.0.0.48:8082/domain/0e306419-b187-46e7-a5cc-c5c009990e70 2025-09-23 20:36:05,572 - DEBUG - Requesting: http://10.0.0.48:8082/project/0694af17-e046-4f69-8161-a70926b4f5d3 2025-09-23 20:36:05,656 - INFO - Validated that VN ctest-vn4-44238901 is not found in API Server 2025-09-23 20:36:05,670 - DEBUG - VN ctest-vn4-44238901 is not present in Agent 10.0.0.48 2025-09-23 20:36:05,670 - INFO - Validated that VN ctest-vn4-44238901 is not in any agent 2025-09-23 20:36:05,686 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-44238901 info 2025-09-23 20:36:05,718 - INFO - Deleted policy ctest-policy1-24649121 2025-09-23 20:36:05,899 - DEBUG - policy ctest-policy1-24649121 is not found in API Server 2025-09-23 20:36:06,219 - DEBUG - No XMPP flaps were noticed during the test 2025-09-23 20:36:06,219 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-09-23 20:36:06,219 - INFO - -------------------------------------------------------------------------------- 2025-09-23 20:36:06,566 - DEBUG - No XMPP flaps were noticed during the test 2025-09-23 20:36:06,567 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:06] 2025-09-23 20:36:06,567 - INFO - -------------------------------------------------------------------------------- 2025-09-23 20:36:07,416 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-25561076, ID : 0694af17-e046-4f69-8161-a70926b4f5d3