2025-09-16 12:04:12,303 - INFO - Domain Default found not creating 2025-09-16 12:04:12,435 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-18625926 not found, creating it 2025-09-16 12:04:12,913 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-18625926, ID : 73c75235-50bd-4dcd-9e5b-6295de1fad8d 2025-09-16 12:04:14,285 - INFO - ================================================================================ 2025-09-16 12:04:14,285 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-16 12:04:14,539 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2025-09-16 12:04:14,539 - INFO - Initial checks done. Running the testcase now 2025-09-16 12:04:14,539 - INFO - 2025-09-16 12:04:14,539 - INFO - ================================================================================ 2025-09-16 12:04:14,539 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-16 12:04:14,539 - 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-16 12:04:14,825 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2025-09-16 12:04:14,825 - INFO - Initial checks done. Running the testcase now 2025-09-16 12:04:14,825 - INFO - 2025-09-16 12:04:15,164 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331, 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-18625926:ctest-vn4-93132331, 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-18625926:ctest-vn4-93132331, 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-18625926:ctest-vn4-93132331, 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-16 12:04:15,650 - DEBUG - Response for create_network : {'network': {'id': '53caedbc-c0cd-466b-9913-cedfb823289c', 'name': 'ctest-vn4-93132331', 'tenant_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'project_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-18625926', 'ctest-vn4-93132331'], 'port_security_enabled': True, 'description': ''}} 2025-09-16 12:04:15,853 - DEBUG - Response for create_subnet : {'subnet': {'id': '71ca98c0-4585-4133-bb34-623757126397', 'name': '', 'tenant_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'network_id': '53caedbc-c0cd-466b-9913-cedfb823289c', 'ip_version': 4, 'cidr': '22.174.49.192/26', 'allocation_pools': [{'start': '22.174.49.194', 'end': '22.174.49.254'}], 'gateway_ip': '22.174.49.193', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '22.174.49.194', 'tags': [], 'project_id': '73c7523550bd4dcd9e5b6295de1fad8d'}} 2025-09-16 12:04:16,034 - DEBUG - Response for create_subnet : {'subnet': {'id': '5e38936e-499d-4321-8f25-b454b1b52c1b', 'name': '', 'tenant_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'network_id': '53caedbc-c0cd-466b-9913-cedfb823289c', 'ip_version': 6, 'cidr': '2e77:a017:9d5e:3b2e:3244:bb66::/96', 'allocation_pools': [{'start': '2e77:a017:9d5e:3b2e:3244:bb66:0:2', 'end': '2e77:a017:9d5e:3b2e:3244:bb66:ffff:fffe'}], 'gateway_ip': '2e77:a017:9d5e:3b2e:3244:bb66:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2e77:a017:9d5e:3b2e:3244:bb66:0:2', 'tags': [], 'project_id': '73c7523550bd4dcd9e5b6295de1fad8d'}} 2025-09-16 12:04:16,056 - INFO - Created VN ctest-vn4-93132331 2025-09-16 12:04:16,109 - DEBUG - VN ctest-vn4-93132331 UUID is 53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,298 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '53caedbc-c0cd-466b-9913-cedfb823289c', 'name': 'ctest-vn4-93132331', 'tenant_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'project_id': '73c7523550bd4dcd9e5b6295de1fad8d', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['71ca98c0-4585-4133-bb34-623757126397', '5e38936e-499d-4321-8f25-b454b1b52c1b'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-18625926', 'ctest-vn4-93132331'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-18625926', 'ctest-policy1-95549613']], 'subnet_ipam': [{'subnet_cidr': '22.174.49.192/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2e77:a017:9d5e:3b2e:3244:bb66::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-16 12:04:16,453 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-16 12:04:16,741 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-16 12:04:16,766 - DEBUG - Requesting: http://10.0.0.50:8082/domain/457b366e-c28a-4292-9228-3b0449ec22cc 2025-09-16 12:04:16,778 - DEBUG - Requesting: http://10.0.0.50:8082/project/73c75235-50bd-4dcd-9e5b-6295de1fad8d 2025-09-16 12:04:16,851 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,862 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,871 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:16,877 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:16,883 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/b276d5ab-27ac-4145-a526-263917f279a5 2025-09-16 12:04:16,889 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-16 12:04:16,889 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,898 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:16,911 - INFO - Verified VN network id 12 for VN 53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,911 - INFO - Verifications in API Server for VN ctest-vn4-93132331 passed 2025-09-16 12:04:16,911 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:16,920 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:16,926 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:16,932 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/b276d5ab-27ac-4145-a526-263917f279a5 2025-09-16 12:04:16,942 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-18625926', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '6037899645387884139', 'uuid-lslong': '11030387372622817436'}, 'enable': 'true', 'created': '2025-09-16T12:04:15', 'last-modified': '2025-09-16T12:04:16', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.673651'} 2025-09-16 12:04:16,947 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-16 12:04:16,947 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-93132331 passed 2025-09-16 12:04:16,947 - DEBUG - ====Verifying policy data for ctest-vn4-93132331 in API_Server ====== 2025-09-16 12:04:16,947 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-16 12:04:16,952 - DEBUG - Requesting: http://10.0.0.50:8082/domain/457b366e-c28a-4292-9228-3b0449ec22cc 2025-09-16 12:04:16,961 - DEBUG - Requesting: http://10.0.0.50:8082/project/73c75235-50bd-4dcd-9e5b-6295de1fad8d 2025-09-16 12:04:17,029 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/53caedbc-c0cd-466b-9913-cedfb823289c 2025-09-16 12:04:17,039 - DEBUG - ==>Verifying data for policy with id: 6dbe0ecd-86f6-4f0a-a68e-e26a85aa0672, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-18625926', 'ctest-policy1-95549613'] 2025-09-16 12:04:17,039 - INFO - VN ctest-vn4-93132331 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-16 12:04:17,040 - DEBUG - Verifying the vn in opserver 2025-09-16 12:04:17,040 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331 virtual network link through opserver 10.0.0.50 2025-09-16 12:04:17,040 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-09-16 12:04:17,338 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-09-16 12:04:17,390 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331?flat'} 2025-09-16 12:04:17,390 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-18625926:ctest-vn4-93132331 is found in opserver 2025-09-16 12:04:17,399 - DEBUG - Do not have enough data to verify VN in agent 2025-09-16 12:04:17,403 - DEBUG - VRF ids for VN ctest-vn4-93132331: {} 2025-09-16 12:04:17,403 - DEBUG - ====Verifying data for ctest-policy1-95549613 in API_Server ====== 2025-09-16 12:04:17,403 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-16 12:04:17,408 - DEBUG - Requesting: http://10.0.0.50:8082/domain/457b366e-c28a-4292-9228-3b0449ec22cc 2025-09-16 12:04:17,418 - DEBUG - Requesting: http://10.0.0.50:8082/project/73c75235-50bd-4dcd-9e5b-6295de1fad8d 2025-09-16 12:04:17,485 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/6dbe0ecd-86f6-4f0a-a68e-e26a85aa0672 2025-09-16 12:04:17,494 - INFO - Verified policy ctest-policy1-95549613 in API Server, Result: True 2025-09-16 12:04:17,494 - INFO - Done with setup and verification, moving onto test .. 2025-09-16 12:04:17,500 - INFO - Deleting VN ctest-vn4-93132331 2025-09-16 12:04:17,600 - DEBUG - Response for deleting network () 2025-09-16 12:04:17,600 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/0e42870f-6feb-4a7b-878e-bcaa73f2c367 2025-09-16 12:04:17,605 - DEBUG - Response Code: 404 2025-09-16 12:04:17,605 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-16 12:04:17,611 - DEBUG - Requesting: http://10.0.0.50:8082/domain/457b366e-c28a-4292-9228-3b0449ec22cc 2025-09-16 12:04:17,665 - DEBUG - Requesting: http://10.0.0.50:8082/project/73c75235-50bd-4dcd-9e5b-6295de1fad8d 2025-09-16 12:04:17,733 - INFO - Validated that VN ctest-vn4-93132331 is not found in API Server 2025-09-16 12:04:17,741 - DEBUG - VN ctest-vn4-93132331 is not present in Agent 10.0.0.50 2025-09-16 12:04:17,741 - INFO - Validated that VN ctest-vn4-93132331 is not in any agent 2025-09-16 12:04:17,754 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-93132331 info 2025-09-16 12:04:17,779 - INFO - Deleted policy ctest-policy1-95549613 2025-09-16 12:04:17,937 - DEBUG - policy ctest-policy1-95549613 is not found in API Server 2025-09-16 12:04:18,193 - DEBUG - No XMPP flaps were noticed during the test 2025-09-16 12:04:18,193 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-09-16 12:04:18,194 - INFO - -------------------------------------------------------------------------------- 2025-09-16 12:04:18,484 - DEBUG - No XMPP flaps were noticed during the test 2025-09-16 12:04:18,484 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-09-16 12:04:18,484 - INFO - -------------------------------------------------------------------------------- 2025-09-16 12:04:19,137 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-18625926, ID : 73c75235-50bd-4dcd-9e5b-6295de1fad8d