2025-08-07 14:23:27,576 - INFO - Domain Default found not creating 2025-08-07 14:23:27,754 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-42229916 not found, creating it 2025-08-07 14:23:28,292 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-42229916, ID : 5277ada8-31ea-476d-b72f-1228028dfca2 2025-08-07 14:23:29,958 - INFO - ================================================================================ 2025-08-07 14:23:29,959 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-07 14:23:30,221 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2025-08-07 14:23:30,221 - INFO - Initial checks done. Running the testcase now 2025-08-07 14:23:30,221 - INFO - 2025-08-07 14:23:30,221 - INFO - ================================================================================ 2025-08-07 14:23:30,221 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-07 14:23:30,221 - 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-07 14:23:30,522 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.17': '0'}} with 2025-08-07 14:23:30,522 - INFO - Initial checks done. Running the testcase now 2025-08-07 14:23:30,522 - INFO - 2025-08-07 14:23:30,939 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579, 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-42229916:ctest-vn4-61976579, 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-42229916:ctest-vn4-61976579, 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-42229916:ctest-vn4-61976579, 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-07 14:23:31,517 - DEBUG - Response for create_network : {'network': {'id': 'bee669b1-9c4d-4dd2-b01a-b95e17928763', 'name': 'ctest-vn4-61976579', 'tenant_id': '5277ada831ea476db72f1228028dfca2', 'project_id': '5277ada831ea476db72f1228028dfca2', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-42229916', 'ctest-vn4-61976579'], 'port_security_enabled': True, 'description': ''}} 2025-08-07 14:23:31,728 - DEBUG - Response for create_subnet : {'subnet': {'id': '3c1bd0dc-a302-41d8-9d5f-5dc5f2831d16', 'name': '', 'tenant_id': '5277ada831ea476db72f1228028dfca2', 'network_id': 'bee669b1-9c4d-4dd2-b01a-b95e17928763', 'ip_version': 4, 'cidr': '164.167.59.0/26', 'allocation_pools': [{'start': '164.167.59.2', 'end': '164.167.59.62'}], 'gateway_ip': '164.167.59.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '164.167.59.2', 'tags': [], 'project_id': '5277ada831ea476db72f1228028dfca2'}} 2025-08-07 14:23:31,926 - DEBUG - Response for create_subnet : {'subnet': {'id': 'c72b7e1c-0988-41a9-b2bc-55b69e1904d3', 'name': '', 'tenant_id': '5277ada831ea476db72f1228028dfca2', 'network_id': 'bee669b1-9c4d-4dd2-b01a-b95e17928763', 'ip_version': 6, 'cidr': '38d0:aa38:a66f:ef7c:3f2e:d1e6::/96', 'allocation_pools': [{'start': '38d0:aa38:a66f:ef7c:3f2e:d1e6:0:2', 'end': '38d0:aa38:a66f:ef7c:3f2e:d1e6:ffff:fffe'}], 'gateway_ip': '38d0:aa38:a66f:ef7c:3f2e:d1e6:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '38d0:aa38:a66f:ef7c:3f2e:d1e6:0:2', 'tags': [], 'project_id': '5277ada831ea476db72f1228028dfca2'}} 2025-08-07 14:23:31,952 - INFO - Created VN ctest-vn4-61976579 2025-08-07 14:23:32,005 - DEBUG - VN ctest-vn4-61976579 UUID is bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:32,275 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'bee669b1-9c4d-4dd2-b01a-b95e17928763', 'name': 'ctest-vn4-61976579', 'tenant_id': '5277ada831ea476db72f1228028dfca2', 'project_id': '5277ada831ea476db72f1228028dfca2', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['3c1bd0dc-a302-41d8-9d5f-5dc5f2831d16', 'c72b7e1c-0988-41a9-b2bc-55b69e1904d3'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-42229916', 'ctest-vn4-61976579'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-42229916', 'ctest-policy1-03650411']], 'subnet_ipam': [{'subnet_cidr': '164.167.59.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '38d0:aa38:a66f:ef7c:3f2e:d1e6::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-07 14:23:32,441 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-08-07 14:23:32,781 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-08-07 14:23:32,815 - DEBUG - Requesting: http://10.0.0.38:8082/domain/b8a0d0b8-4c65-4c5d-a22f-785df37aa8fa 2025-08-07 14:23:32,833 - DEBUG - Requesting: http://10.0.0.38:8082/project/5277ada8-31ea-476d-b72f-1228028dfca2 2025-08-07 14:23:32,915 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:32,931 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:32,944 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:32,954 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:32,963 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/008a3498-27ae-42dc-aaa2-4967b3b01052 2025-08-07 14:23:32,971 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-07 14:23:32,971 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:32,983 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:33,002 - INFO - Verified VN network id 11 for VN bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:33,002 - INFO - Verifications in API Server for VN ctest-vn4-61976579 passed 2025-08-07 14:23:33,002 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:33,016 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:33,025 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:33,035 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/008a3498-27ae-42dc-aaa2-4967b3b01052 2025-08-07 14:23:33,051 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-42229916', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '13755798323402198482', 'uuid-lslong': '12689658713843337059'}, 'enable': 'true', 'created': '2025-08-07T14:23:31', 'last-modified': '2025-08-07T14:23:32', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.824471'} 2025-08-07 14:23:33,059 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-07 14:23:33,059 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-61976579 passed 2025-08-07 14:23:33,059 - DEBUG - ====Verifying policy data for ctest-vn4-61976579 in API_Server ====== 2025-08-07 14:23:33,059 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-08-07 14:23:33,068 - DEBUG - Requesting: http://10.0.0.38:8082/domain/b8a0d0b8-4c65-4c5d-a22f-785df37aa8fa 2025-08-07 14:23:33,082 - DEBUG - Requesting: http://10.0.0.38:8082/project/5277ada8-31ea-476d-b72f-1228028dfca2 2025-08-07 14:23:33,162 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/bee669b1-9c4d-4dd2-b01a-b95e17928763 2025-08-07 14:23:33,175 - DEBUG - ==>Verifying data for policy with id: f446afe6-de4a-4827-8f5d-734ce40a8a8f, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-42229916', 'ctest-policy1-03650411'] 2025-08-07 14:23:33,176 - INFO - VN ctest-vn4-61976579 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-07 14:23:33,176 - DEBUG - Verifying the vn in opserver 2025-08-07 14:23:33,176 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579 virtual network link through opserver 10.0.0.38 2025-08-07 14:23:33,176 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-08-07 14:23:33,523 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-08-07 14:23:33,591 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579?flat'} 2025-08-07 14:23:33,591 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-42229916:ctest-vn4-61976579 is found in opserver 2025-08-07 14:23:33,605 - DEBUG - Do not have enough data to verify VN in agent 2025-08-07 14:23:33,611 - DEBUG - VRF ids for VN ctest-vn4-61976579: {} 2025-08-07 14:23:33,612 - DEBUG - ====Verifying data for ctest-policy1-03650411 in API_Server ====== 2025-08-07 14:23:33,612 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-08-07 14:23:33,619 - DEBUG - Requesting: http://10.0.0.38:8082/domain/b8a0d0b8-4c65-4c5d-a22f-785df37aa8fa 2025-08-07 14:23:33,635 - DEBUG - Requesting: http://10.0.0.38:8082/project/5277ada8-31ea-476d-b72f-1228028dfca2 2025-08-07 14:23:33,716 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/f446afe6-de4a-4827-8f5d-734ce40a8a8f 2025-08-07 14:23:33,730 - INFO - Verified policy ctest-policy1-03650411 in API Server, Result: True 2025-08-07 14:23:33,730 - INFO - Done with setup and verification, moving onto test .. 2025-08-07 14:23:33,741 - INFO - Deleting VN ctest-vn4-61976579 2025-08-07 14:23:33,902 - DEBUG - Response for deleting network () 2025-08-07 14:23:33,903 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/bd64a3b6-d32c-4203-afd1-2175ef726ad0 2025-08-07 14:23:33,912 - DEBUG - Response Code: 404 2025-08-07 14:23:33,912 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-08-07 14:23:33,919 - DEBUG - Requesting: http://10.0.0.38:8082/domain/b8a0d0b8-4c65-4c5d-a22f-785df37aa8fa 2025-08-07 14:23:33,978 - DEBUG - Requesting: http://10.0.0.38:8082/project/5277ada8-31ea-476d-b72f-1228028dfca2 2025-08-07 14:23:34,061 - INFO - Validated that VN ctest-vn4-61976579 is not found in API Server 2025-08-07 14:23:34,074 - DEBUG - VN ctest-vn4-61976579 is not present in Agent 10.0.0.38 2025-08-07 14:23:34,075 - INFO - Validated that VN ctest-vn4-61976579 is not in any agent 2025-08-07 14:23:34,097 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-61976579 info 2025-08-07 14:23:34,133 - INFO - Deleted policy ctest-policy1-03650411 2025-08-07 14:23:34,313 - DEBUG - policy ctest-policy1-03650411 is not found in API Server 2025-08-07 14:23:34,584 - DEBUG - No XMPP flaps were noticed during the test 2025-08-07 14:23:34,584 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-07 14:23:34,584 - INFO - -------------------------------------------------------------------------------- 2025-08-07 14:23:34,879 - DEBUG - No XMPP flaps were noticed during the test 2025-08-07 14:23:34,879 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-08-07 14:23:34,879 - INFO - -------------------------------------------------------------------------------- 2025-08-07 14:23:35,679 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-42229916, ID : 5277ada8-31ea-476d-b72f-1228028dfca2