2025-11-05 08:20:46,031 - INFO - Domain Default found not creating 2025-11-05 08:20:46,167 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-69975505 not found, creating it 2025-11-05 08:20:46,574 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-69975505, ID : ee577541-7541-45d3-b2b1-95d032ef2992 2025-11-05 08:20:47,948 - INFO - ================================================================================ 2025-11-05 08:20:47,949 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-05 08:20:48,200 - DEBUG - Nothing to compare xmpp stats {'10.0.0.131': {'10.20.0.18': '0'}} with 2025-11-05 08:20:48,200 - INFO - Initial checks done. Running the testcase now 2025-11-05 08:20:48,200 - INFO - 2025-11-05 08:20:48,200 - INFO - ================================================================================ 2025-11-05 08:20:48,200 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-05 08:20:48,201 - 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-11-05 08:20:48,491 - DEBUG - Nothing to compare xmpp stats {'10.0.0.131': {'10.20.0.18': '0'}} with 2025-11-05 08:20:48,491 - INFO - Initial checks done. Running the testcase now 2025-11-05 08:20:48,491 - INFO - 2025-11-05 08:20:48,828 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657, 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-69975505:ctest-vn4-55040657, 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-69975505:ctest-vn4-55040657, 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-69975505:ctest-vn4-55040657, 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-11-05 08:20:49,307 - DEBUG - Response for create_network : {'network': {'id': 'ba92e461-3f3b-4790-a6c8-d6449e93bd96', 'name': 'ctest-vn4-55040657', 'tenant_id': 'ee577541754145d3b2b195d032ef2992', 'project_id': 'ee577541754145d3b2b195d032ef2992', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-69975505', 'ctest-vn4-55040657'], 'port_security_enabled': True, 'description': ''}} 2025-11-05 08:20:49,488 - DEBUG - Response for create_subnet : {'subnet': {'id': 'e4ca277e-95f6-4d4c-a126-121fbe57612d', 'name': '', 'tenant_id': 'ee577541754145d3b2b195d032ef2992', 'network_id': 'ba92e461-3f3b-4790-a6c8-d6449e93bd96', 'ip_version': 4, 'cidr': '80.49.120.0/26', 'allocation_pools': [{'start': '80.49.120.2', 'end': '80.49.120.62'}], 'gateway_ip': '80.49.120.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '80.49.120.2', 'tags': [], 'project_id': 'ee577541754145d3b2b195d032ef2992'}} 2025-11-05 08:20:49,640 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a316e60f-abe9-4620-8b67-608808c9cabb', 'name': '', 'tenant_id': 'ee577541754145d3b2b195d032ef2992', 'network_id': 'ba92e461-3f3b-4790-a6c8-d6449e93bd96', 'ip_version': 6, 'cidr': '3dab:1dec:aae0:612:6901:a8de::/96', 'allocation_pools': [{'start': '3dab:1dec:aae0:612:6901:a8de:0:2', 'end': '3dab:1dec:aae0:612:6901:a8de:ffff:fffe'}], 'gateway_ip': '3dab:1dec:aae0:612:6901:a8de:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3dab:1dec:aae0:612:6901:a8de:0:2', 'tags': [], 'project_id': 'ee577541754145d3b2b195d032ef2992'}} 2025-11-05 08:20:49,658 - INFO - Created VN ctest-vn4-55040657 2025-11-05 08:20:49,707 - DEBUG - VN ctest-vn4-55040657 UUID is ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:49,903 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'ba92e461-3f3b-4790-a6c8-d6449e93bd96', 'name': 'ctest-vn4-55040657', 'tenant_id': 'ee577541754145d3b2b195d032ef2992', 'project_id': 'ee577541754145d3b2b195d032ef2992', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['e4ca277e-95f6-4d4c-a126-121fbe57612d', 'a316e60f-abe9-4620-8b67-608808c9cabb'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-69975505', 'ctest-vn4-55040657'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-69975505', 'ctest-policy1-60861561']], 'subnet_ipam': [{'subnet_cidr': '80.49.120.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3dab:1dec:aae0:612:6901:a8de::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-05 08:20:50,063 - DEBUG - Requesting: http://10.0.0.131:8082/domains 2025-11-05 08:20:50,354 - DEBUG - Requesting: http://10.0.0.131:8082/domains 2025-11-05 08:20:50,382 - DEBUG - Requesting: http://10.0.0.131:8082/domain/7a620f37-a3d5-4e73-8333-5ca467258adb 2025-11-05 08:20:50,392 - DEBUG - Requesting: http://10.0.0.131:8082/project/ee577541-7541-45d3-b2b1-95d032ef2992 2025-11-05 08:20:50,462 - DEBUG - Requesting: http://10.0.0.131:8082/virtual-network/ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,472 - DEBUG - Requesting: http://10.0.0.131:8082/virtual-network/ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,480 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:50,486 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:50,492 - DEBUG - Requesting: http://10.0.0.131:8082/route-target/5df9d0d6-62dd-43eb-8d95-b45f86a42701 2025-11-05 08:20:50,497 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-05 08:20:50,497 - DEBUG - Requesting: http://10.0.0.131:8082/virtual-network/ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,504 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:50,516 - INFO - Verified VN network id 9 for VN ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,516 - INFO - Verifications in API Server for VN ctest-vn4-55040657 passed 2025-11-05 08:20:50,516 - DEBUG - Requesting: http://10.0.0.131:8082/virtual-network/ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,523 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:50,528 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:50,533 - DEBUG - Requesting: http://10.0.0.131:8082/route-target/5df9d0d6-62dd-43eb-8d95-b45f86a42701 2025-11-05 08:20:50,542 - DEBUG - Control-node 10.0.0.131 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-69975505', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '13444058943978162064', 'uuid-lslong': '12018091195844771222'}, 'enable': 'true', 'created': '2025-11-05T08:20:49', 'last-modified': '2025-11-05T08:20:49', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.663402'} 2025-11-05 08:20:50,547 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-05 08:20:50,547 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-55040657 passed 2025-11-05 08:20:50,547 - DEBUG - ====Verifying policy data for ctest-vn4-55040657 in API_Server ====== 2025-11-05 08:20:50,547 - DEBUG - Requesting: http://10.0.0.131:8082/domains 2025-11-05 08:20:50,552 - DEBUG - Requesting: http://10.0.0.131:8082/domain/7a620f37-a3d5-4e73-8333-5ca467258adb 2025-11-05 08:20:50,562 - DEBUG - Requesting: http://10.0.0.131:8082/project/ee577541-7541-45d3-b2b1-95d032ef2992 2025-11-05 08:20:50,626 - DEBUG - Requesting: http://10.0.0.131:8082/virtual-network/ba92e461-3f3b-4790-a6c8-d6449e93bd96 2025-11-05 08:20:50,635 - DEBUG - ==>Verifying data for policy with id: 9e584db9-9ff9-4d97-969a-9554631ad8ff, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-69975505', 'ctest-policy1-60861561'] 2025-11-05 08:20:50,635 - INFO - VN ctest-vn4-55040657 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-05 08:20:50,635 - DEBUG - Verifying the vn in opserver 2025-11-05 08:20:50,635 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657 virtual network link through opserver 10.0.0.131 2025-11-05 08:20:50,635 - DEBUG - Requesting: http://10.0.0.131:8081/analytics/uves/virtual-networks 2025-11-05 08:20:50,924 - DEBUG - Requesting: http://10.0.0.131:8081/analytics/uves/virtual-networks 2025-11-05 08:20:50,980 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657', 'href': 'http://10.0.0.131:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657?flat'} 2025-11-05 08:20:50,980 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-69975505:ctest-vn4-55040657 is found in opserver 2025-11-05 08:20:50,989 - DEBUG - Do not have enough data to verify VN in agent 2025-11-05 08:20:50,993 - DEBUG - VRF ids for VN ctest-vn4-55040657: {} 2025-11-05 08:20:50,994 - DEBUG - ====Verifying data for ctest-policy1-60861561 in API_Server ====== 2025-11-05 08:20:50,994 - DEBUG - Requesting: http://10.0.0.131:8082/domains 2025-11-05 08:20:50,999 - DEBUG - Requesting: http://10.0.0.131:8082/domain/7a620f37-a3d5-4e73-8333-5ca467258adb 2025-11-05 08:20:51,011 - DEBUG - Requesting: http://10.0.0.131:8082/project/ee577541-7541-45d3-b2b1-95d032ef2992 2025-11-05 08:20:51,080 - DEBUG - Requesting: http://10.0.0.131:8082/network-policy/9e584db9-9ff9-4d97-969a-9554631ad8ff 2025-11-05 08:20:51,089 - INFO - Verified policy ctest-policy1-60861561 in API Server, Result: True 2025-11-05 08:20:51,090 - INFO - Done with setup and verification, moving onto test .. 2025-11-05 08:20:51,096 - INFO - Deleting VN ctest-vn4-55040657 2025-11-05 08:20:51,198 - DEBUG - Response for deleting network () 2025-11-05 08:20:51,198 - DEBUG - Requesting: http://10.0.0.131:8082/routing-instance/90e3d095-eb9c-4c77-b757-cb6a7bd85867 2025-11-05 08:20:51,202 - DEBUG - Response Code: 404 2025-11-05 08:20:51,203 - DEBUG - Requesting: http://10.0.0.131:8082/domains 2025-11-05 08:20:51,207 - DEBUG - Requesting: http://10.0.0.131:8082/domain/7a620f37-a3d5-4e73-8333-5ca467258adb 2025-11-05 08:20:51,264 - DEBUG - Requesting: http://10.0.0.131:8082/project/ee577541-7541-45d3-b2b1-95d032ef2992 2025-11-05 08:20:51,329 - INFO - Validated that VN ctest-vn4-55040657 is not found in API Server 2025-11-05 08:20:51,338 - DEBUG - VN ctest-vn4-55040657 is not present in Agent 10.0.0.131 2025-11-05 08:20:51,338 - INFO - Validated that VN ctest-vn4-55040657 is not in any agent 2025-11-05 08:20:51,351 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-55040657 info 2025-11-05 08:20:51,372 - INFO - Deleted policy ctest-policy1-60861561 2025-11-05 08:20:51,539 - DEBUG - policy ctest-policy1-60861561 is not found in API Server 2025-11-05 08:20:51,792 - DEBUG - No XMPP flaps were noticed during the test
2025-11-05 08:20:51,792 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03]
2025-11-05 08:20:51,792 - INFO - -------------------------------------------------------------------------------- 2025-11-05 08:20:52,080 - DEBUG - No XMPP flaps were noticed during the test
2025-11-05 08:20:52,081 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2025-11-05 08:20:52,081 - INFO - -------------------------------------------------------------------------------- 2025-11-05 08:20:52,742 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-69975505, ID : ee577541-7541-45d3-b2b1-95d032ef2992