2025-11-07 13:30:42,684 - INFO - Domain Default found not creating 2025-11-07 13:30:42,854 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-76294426 not found, creating it 2025-11-07 13:30:43,338 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-76294426, ID : 10fc9f2a-dd9a-4257-90e1-0a1c4494bd06 2025-11-07 13:30:44,764 - INFO - ================================================================================ 2025-11-07 13:30:44,765 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-07 13:30:45,020 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.18': '0'}} with 2025-11-07 13:30:45,020 - INFO - Initial checks done. Running the testcase now 2025-11-07 13:30:45,020 - INFO - 2025-11-07 13:30:45,020 - INFO - ================================================================================ 2025-11-07 13:30:45,020 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-07 13:30:45,020 - 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-07 13:30:45,316 - DEBUG - Nothing to compare xmpp stats {'10.0.0.38': {'10.20.0.18': '0'}} with 2025-11-07 13:30:45,316 - INFO - Initial checks done. Running the testcase now 2025-11-07 13:30:45,316 - INFO - 2025-11-07 13:30:45,672 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480, 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-76294426:ctest-vn4-87013480, 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-76294426:ctest-vn4-87013480, 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-76294426:ctest-vn4-87013480, 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-07 13:30:46,199 - DEBUG - Response for create_network : {'network': {'id': 'e9594228-8976-4f0d-9a2f-624d54130fb1', 'name': 'ctest-vn4-87013480', 'tenant_id': '10fc9f2add9a425790e10a1c4494bd06', 'project_id': '10fc9f2add9a425790e10a1c4494bd06', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-76294426', 'ctest-vn4-87013480'], 'port_security_enabled': True, 'description': ''}} 2025-11-07 13:30:46,420 - DEBUG - Response for create_subnet : {'subnet': {'id': 'b569c42f-6295-4109-ac94-ee3532561889', 'name': '', 'tenant_id': '10fc9f2add9a425790e10a1c4494bd06', 'network_id': 'e9594228-8976-4f0d-9a2f-624d54130fb1', 'ip_version': 4, 'cidr': '75.251.184.0/26', 'allocation_pools': [{'start': '75.251.184.2', 'end': '75.251.184.62'}], 'gateway_ip': '75.251.184.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '75.251.184.2', 'tags': [], 'project_id': '10fc9f2add9a425790e10a1c4494bd06'}} 2025-11-07 13:30:46,634 - DEBUG - Response for create_subnet : {'subnet': {'id': '1aaee84d-a70b-492d-8e87-70cb6f3c4774', 'name': '', 'tenant_id': '10fc9f2add9a425790e10a1c4494bd06', 'network_id': 'e9594228-8976-4f0d-9a2f-624d54130fb1', 'ip_version': 6, 'cidr': '2ba7:956a:b9b5:be8b:d1c5:3a01::/96', 'allocation_pools': [{'start': '2ba7:956a:b9b5:be8b:d1c5:3a01:0:2', 'end': '2ba7:956a:b9b5:be8b:d1c5:3a01:ffff:fffe'}], 'gateway_ip': '2ba7:956a:b9b5:be8b:d1c5:3a01:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2ba7:956a:b9b5:be8b:d1c5:3a01:0:2', 'tags': [], 'project_id': '10fc9f2add9a425790e10a1c4494bd06'}} 2025-11-07 13:30:46,660 - INFO - Created VN ctest-vn4-87013480 2025-11-07 13:30:46,714 - DEBUG - VN ctest-vn4-87013480 UUID is e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:46,947 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'e9594228-8976-4f0d-9a2f-624d54130fb1', 'name': 'ctest-vn4-87013480', 'tenant_id': '10fc9f2add9a425790e10a1c4494bd06', 'project_id': '10fc9f2add9a425790e10a1c4494bd06', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['b569c42f-6295-4109-ac94-ee3532561889', '1aaee84d-a70b-492d-8e87-70cb6f3c4774'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-76294426', 'ctest-vn4-87013480'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-76294426', 'ctest-policy1-01721679']], 'subnet_ipam': [{'subnet_cidr': '75.251.184.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2ba7:956a:b9b5:be8b:d1c5:3a01::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-07 13:30:47,114 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-11-07 13:30:47,406 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-11-07 13:30:47,441 - DEBUG - Requesting: http://10.0.0.38:8082/domain/056d5a6e-916c-4124-858a-8b323dc4a83d 2025-11-07 13:30:47,453 - DEBUG - Requesting: http://10.0.0.38:8082/project/10fc9f2a-dd9a-4257-90e1-0a1c4494bd06 2025-11-07 13:30:47,532 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,544 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,555 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:47,562 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:47,569 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/1e1b3438-0219-4e17-8c9f-cb769a69e7b8 2025-11-07 13:30:47,576 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-07 13:30:47,577 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,588 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:47,606 - INFO - Verified VN network id 11 for VN e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,606 - INFO - Verifications in API Server for VN ctest-vn4-87013480 passed 2025-11-07 13:30:47,606 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,617 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:47,627 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:47,634 - DEBUG - Requesting: http://10.0.0.38:8082/route-target/1e1b3438-0219-4e17-8c9f-cb769a69e7b8 2025-11-07 13:30:47,648 - DEBUG - Control-node 10.0.0.38 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-76294426', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '16814543425636814605', 'uuid-lslong': '11110206890008842161'}, 'enable': 'true', 'created': '2025-11-07T13:30:46', 'last-modified': '2025-11-07T13:30:46', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.737185'} 2025-11-07 13:30:47,656 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-07 13:30:47,656 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-87013480 passed 2025-11-07 13:30:47,657 - DEBUG - ====Verifying policy data for ctest-vn4-87013480 in API_Server ====== 2025-11-07 13:30:47,657 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-11-07 13:30:47,665 - DEBUG - Requesting: http://10.0.0.38:8082/domain/056d5a6e-916c-4124-858a-8b323dc4a83d 2025-11-07 13:30:47,678 - DEBUG - Requesting: http://10.0.0.38:8082/project/10fc9f2a-dd9a-4257-90e1-0a1c4494bd06 2025-11-07 13:30:47,750 - DEBUG - Requesting: http://10.0.0.38:8082/virtual-network/e9594228-8976-4f0d-9a2f-624d54130fb1 2025-11-07 13:30:47,763 - DEBUG - ==>Verifying data for policy with id: 33674bd0-afd3-4d7a-8ddd-6d2d70b2ed14, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-76294426', 'ctest-policy1-01721679'] 2025-11-07 13:30:47,763 - INFO - VN ctest-vn4-87013480 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-07 13:30:47,763 - DEBUG - Verifying the vn in opserver 2025-11-07 13:30:47,763 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480 virtual network link through opserver 10.0.0.38 2025-11-07 13:30:47,764 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-11-07 13:30:48,059 - DEBUG - Requesting: http://10.0.0.38:8081/analytics/uves/virtual-networks 2025-11-07 13:30:48,123 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480', 'href': 'http://10.0.0.38:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480?flat'} 2025-11-07 13:30:48,123 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-76294426:ctest-vn4-87013480 is found in opserver 2025-11-07 13:30:48,132 - DEBUG - Do not have enough data to verify VN in agent 2025-11-07 13:30:48,137 - DEBUG - VRF ids for VN ctest-vn4-87013480: {} 2025-11-07 13:30:48,137 - DEBUG - ====Verifying data for ctest-policy1-01721679 in API_Server ====== 2025-11-07 13:30:48,137 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-11-07 13:30:48,143 - DEBUG - Requesting: http://10.0.0.38:8082/domain/056d5a6e-916c-4124-858a-8b323dc4a83d 2025-11-07 13:30:48,154 - DEBUG - Requesting: http://10.0.0.38:8082/project/10fc9f2a-dd9a-4257-90e1-0a1c4494bd06 2025-11-07 13:30:48,233 - DEBUG - Requesting: http://10.0.0.38:8082/network-policy/33674bd0-afd3-4d7a-8ddd-6d2d70b2ed14 2025-11-07 13:30:48,248 - INFO - Verified policy ctest-policy1-01721679 in API Server, Result: True 2025-11-07 13:30:48,248 - INFO - Done with setup and verification, moving onto test .. 2025-11-07 13:30:48,257 - INFO - Deleting VN ctest-vn4-87013480 2025-11-07 13:30:48,390 - DEBUG - Response for deleting network () 2025-11-07 13:30:48,390 - DEBUG - Requesting: http://10.0.0.38:8082/routing-instance/d0be3348-f0b8-4417-83be-991ff64dcce9 2025-11-07 13:30:48,396 - DEBUG - Response Code: 404 2025-11-07 13:30:48,396 - DEBUG - Requesting: http://10.0.0.38:8082/domains 2025-11-07 13:30:48,403 - DEBUG - Requesting: http://10.0.0.38:8082/domain/056d5a6e-916c-4124-858a-8b323dc4a83d 2025-11-07 13:30:48,456 - DEBUG - Requesting: http://10.0.0.38:8082/project/10fc9f2a-dd9a-4257-90e1-0a1c4494bd06 2025-11-07 13:30:48,524 - INFO - Validated that VN ctest-vn4-87013480 is not found in API Server 2025-11-07 13:30:48,535 - DEBUG - VN ctest-vn4-87013480 is not present in Agent 10.0.0.38 2025-11-07 13:30:48,535 - INFO - Validated that VN ctest-vn4-87013480 is not in any agent 2025-11-07 13:30:48,554 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-87013480 info 2025-11-07 13:30:48,579 - INFO - Deleted policy ctest-policy1-01721679 2025-11-07 13:30:48,750 - DEBUG - policy ctest-policy1-01721679 is not found in API Server 2025-11-07 13:30:49,004 - DEBUG - No XMPP flaps were noticed during the test 2025-11-07 13:30:49,005 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-11-07 13:30:49,005 - INFO - -------------------------------------------------------------------------------- 2025-11-07 13:30:49,296 - DEBUG - No XMPP flaps were noticed during the test 2025-11-07 13:30:49,296 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-11-07 13:30:49,296 - INFO - -------------------------------------------------------------------------------- 2025-11-07 13:30:49,996 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-76294426, ID : 10fc9f2a-dd9a-4257-90e1-0a1c4494bd06