2025-08-12 16:34:30,325 - INFO - Domain Default found not creating 2025-08-12 16:34:30,455 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-35762198 not found, creating it 2025-08-12 16:34:30,871 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-35762198, ID : d2a6e096-c92f-439d-b769-5de6e3568fa1 2025-08-12 16:34:32,186 - INFO - ================================================================================ 2025-08-12 16:34:32,186 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-12 16:34:32,443 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-08-12 16:34:32,443 - INFO - Initial checks done. Running the testcase now 2025-08-12 16:34:32,443 - INFO - 2025-08-12 16:34:32,443 - INFO - ================================================================================ 2025-08-12 16:34:32,443 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-12 16:34:32,443 - 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-08-12 16:34:32,747 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-08-12 16:34:32,747 - INFO - Initial checks done. Running the testcase now 2025-08-12 16:34:32,747 - INFO - 2025-08-12 16:34:33,081 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607, 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-35762198:ctest-vn4-58575607, 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-35762198:ctest-vn4-58575607, 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-35762198:ctest-vn4-58575607, 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-08-12 16:34:33,571 - DEBUG - Response for create_network : {'network': {'id': '0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1', 'name': 'ctest-vn4-58575607', 'tenant_id': 'd2a6e096c92f439db7695de6e3568fa1', 'project_id': 'd2a6e096c92f439db7695de6e3568fa1', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35762198', 'ctest-vn4-58575607'], 'port_security_enabled': True, 'description': ''}} 2025-08-12 16:34:33,781 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a441e828-2899-4add-a5a8-f2827159ac8b', 'name': '', 'tenant_id': 'd2a6e096c92f439db7695de6e3568fa1', 'network_id': '0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1', 'ip_version': 4, 'cidr': '74.202.250.192/26', 'allocation_pools': [{'start': '74.202.250.194', 'end': '74.202.250.254'}], 'gateway_ip': '74.202.250.193', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '74.202.250.194', 'tags': [], 'project_id': 'd2a6e096c92f439db7695de6e3568fa1'}} 2025-08-12 16:34:33,934 - DEBUG - Response for create_subnet : {'subnet': {'id': '9f9c33cf-1557-4452-a9f9-4b5f40f7272c', 'name': '', 'tenant_id': 'd2a6e096c92f439db7695de6e3568fa1', 'network_id': '0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1', 'ip_version': 6, 'cidr': '2d99:6d0f:eb3c:10f7:26ec:7ae6::/96', 'allocation_pools': [{'start': '2d99:6d0f:eb3c:10f7:26ec:7ae6:0:2', 'end': '2d99:6d0f:eb3c:10f7:26ec:7ae6:ffff:fffe'}], 'gateway_ip': '2d99:6d0f:eb3c:10f7:26ec:7ae6:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2d99:6d0f:eb3c:10f7:26ec:7ae6:0:2', 'tags': [], 'project_id': 'd2a6e096c92f439db7695de6e3568fa1'}} 2025-08-12 16:34:33,951 - INFO - Created VN ctest-vn4-58575607 2025-08-12 16:34:34,002 - DEBUG - VN ctest-vn4-58575607 UUID is 0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,177 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1', 'name': 'ctest-vn4-58575607', 'tenant_id': 'd2a6e096c92f439db7695de6e3568fa1', 'project_id': 'd2a6e096c92f439db7695de6e3568fa1', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['a441e828-2899-4add-a5a8-f2827159ac8b', '9f9c33cf-1557-4452-a9f9-4b5f40f7272c'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35762198', 'ctest-vn4-58575607'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35762198', 'ctest-policy1-18287225']], 'subnet_ipam': [{'subnet_cidr': '74.202.250.192/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2d99:6d0f:eb3c:10f7:26ec:7ae6::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-12 16:34:34,338 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-12 16:34:34,624 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-12 16:34:34,648 - DEBUG - Requesting: http://10.0.0.254:8082/domain/3eb6089a-0f0d-4d39-a57e-fc885ba675d3 2025-08-12 16:34:34,659 - DEBUG - Requesting: http://10.0.0.254:8082/project/d2a6e096-c92f-439d-b769-5de6e3568fa1 2025-08-12 16:34:34,727 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,738 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,747 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:34,753 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:34,758 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/08aa8547-8a7f-455e-89fb-8e5f11925373 2025-08-12 16:34:34,764 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-12 16:34:34,764 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,772 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:34,784 - INFO - Verified VN network id 11 for VN 0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,784 - INFO - Verifications in API Server for VN ctest-vn4-58575607 passed 2025-08-12 16:34:34,784 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,793 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:34,799 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:34,804 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/08aa8547-8a7f-455e-89fb-8e5f11925373 2025-08-12 16:34:34,814 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-35762198', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '397111777063422862', 'uuid-lslong': '13201972362692120545'}, 'enable': 'true', 'created': '2025-08-12T16:34:33', 'last-modified': '2025-08-12T16:34:34', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.662255'} 2025-08-12 16:34:34,820 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-12 16:34:34,820 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-58575607 passed 2025-08-12 16:34:34,820 - DEBUG - ====Verifying policy data for ctest-vn4-58575607 in API_Server ====== 2025-08-12 16:34:34,820 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-12 16:34:34,825 - DEBUG - Requesting: http://10.0.0.254:8082/domain/3eb6089a-0f0d-4d39-a57e-fc885ba675d3 2025-08-12 16:34:34,834 - DEBUG - Requesting: http://10.0.0.254:8082/project/d2a6e096-c92f-439d-b769-5de6e3568fa1 2025-08-12 16:34:34,903 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/0582d30e-a7fd-4b8e-b736-d3eab4c9cfe1 2025-08-12 16:34:34,912 - DEBUG - ==>Verifying data for policy with id: 53c1912a-9f32-4c3e-b80d-b04563bbcf0f, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-35762198', 'ctest-policy1-18287225'] 2025-08-12 16:34:34,912 - INFO - VN ctest-vn4-58575607 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-12 16:34:34,912 - DEBUG - Verifying the vn in opserver 2025-08-12 16:34:34,912 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607 virtual network link through opserver 10.0.0.254 2025-08-12 16:34:34,913 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-12 16:34:35,201 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-12 16:34:35,251 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607?flat'} 2025-08-12 16:34:35,252 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-35762198:ctest-vn4-58575607 is found in opserver 2025-08-12 16:34:35,263 - DEBUG - Do not have enough data to verify VN in agent 2025-08-12 16:34:35,273 - DEBUG - VRF ids for VN ctest-vn4-58575607: {} 2025-08-12 16:34:35,273 - DEBUG - ====Verifying data for ctest-policy1-18287225 in API_Server ====== 2025-08-12 16:34:35,273 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-12 16:34:35,279 - DEBUG - Requesting: http://10.0.0.254:8082/domain/3eb6089a-0f0d-4d39-a57e-fc885ba675d3 2025-08-12 16:34:35,289 - DEBUG - Requesting: http://10.0.0.254:8082/project/d2a6e096-c92f-439d-b769-5de6e3568fa1 2025-08-12 16:34:35,360 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/53c1912a-9f32-4c3e-b80d-b04563bbcf0f 2025-08-12 16:34:35,370 - INFO - Verified policy ctest-policy1-18287225 in API Server, Result: True 2025-08-12 16:34:35,370 - INFO - Done with setup and verification, moving onto test .. 2025-08-12 16:34:35,378 - INFO - Deleting VN ctest-vn4-58575607 2025-08-12 16:34:35,490 - DEBUG - Response for deleting network () 2025-08-12 16:34:35,490 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/9b41a613-b580-4067-a66e-b7f54ac908c2 2025-08-12 16:34:35,494 - DEBUG - Response Code: 404 2025-08-12 16:34:35,494 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-12 16:34:35,499 - DEBUG - Requesting: http://10.0.0.254:8082/domain/3eb6089a-0f0d-4d39-a57e-fc885ba675d3 2025-08-12 16:34:35,550 - DEBUG - Requesting: http://10.0.0.254:8082/project/d2a6e096-c92f-439d-b769-5de6e3568fa1 2025-08-12 16:34:35,622 - INFO - Validated that VN ctest-vn4-58575607 is not found in API Server 2025-08-12 16:34:35,633 - DEBUG - VN ctest-vn4-58575607 is not present in Agent 10.0.0.254 2025-08-12 16:34:35,633 - INFO - Validated that VN ctest-vn4-58575607 is not in any agent 2025-08-12 16:34:35,648 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-58575607 info 2025-08-12 16:34:35,671 - INFO - Deleted policy ctest-policy1-18287225 2025-08-12 16:34:35,837 - DEBUG - policy ctest-policy1-18287225 is not found in API Server 2025-08-12 16:34:36,103 - DEBUG - No XMPP flaps were noticed during the test 2025-08-12 16:34:36,103 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-12 16:34:36,103 - INFO - -------------------------------------------------------------------------------- 2025-08-12 16:34:36,400 - DEBUG - No XMPP flaps were noticed during the test 2025-08-12 16:34:36,400 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-12 16:34:36,400 - INFO - -------------------------------------------------------------------------------- 2025-08-12 16:34:37,041 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-35762198, ID : d2a6e096-c92f-439d-b769-5de6e3568fa1