2025-09-18 16:21:18,847 - INFO - Domain Default found not creating 2025-09-18 16:21:18,978 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-85315532 not found, creating it 2025-09-18 16:21:19,415 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-85315532, ID : dbdda675-9af4-4767-a51b-df390616d99d 2025-09-18 16:21:20,791 - INFO - ================================================================================ 2025-09-18 16:21:20,791 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-18 16:21:21,051 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.17': '0'}} with 2025-09-18 16:21:21,051 - INFO - Initial checks done. Running the testcase now 2025-09-18 16:21:21,051 - INFO - 2025-09-18 16:21:21,051 - INFO - ================================================================================ 2025-09-18 16:21:21,051 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-18 16:21:21,051 - 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-18 16:21:21,339 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.17': '0'}} with 2025-09-18 16:21:21,339 - INFO - Initial checks done. Running the testcase now 2025-09-18 16:21:21,339 - INFO - 2025-09-18 16:21:21,680 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685, 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-85315532:ctest-vn4-04884685, 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-85315532:ctest-vn4-04884685, 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-85315532:ctest-vn4-04884685, 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-18 16:21:22,165 - DEBUG - Response for create_network : {'network': {'id': '5f2be991-62fb-4927-811e-d7a422f6a016', 'name': 'ctest-vn4-04884685', 'tenant_id': 'dbdda6759af44767a51bdf390616d99d', 'project_id': 'dbdda6759af44767a51bdf390616d99d', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85315532', 'ctest-vn4-04884685'], 'port_security_enabled': True, 'description': ''}} 2025-09-18 16:21:22,333 - DEBUG - Response for create_subnet : {'subnet': {'id': 'd657cc46-74e3-47c9-bac2-11cc0d7076fb', 'name': '', 'tenant_id': 'dbdda6759af44767a51bdf390616d99d', 'network_id': '5f2be991-62fb-4927-811e-d7a422f6a016', 'ip_version': 4, 'cidr': '150.18.249.0/26', 'allocation_pools': [{'start': '150.18.249.2', 'end': '150.18.249.62'}], 'gateway_ip': '150.18.249.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '150.18.249.2', 'tags': [], 'project_id': 'dbdda6759af44767a51bdf390616d99d'}} 2025-09-18 16:21:22,479 - DEBUG - Response for create_subnet : {'subnet': {'id': '7ca86c54-c58f-4ea9-b277-16c5e90f676a', 'name': '', 'tenant_id': 'dbdda6759af44767a51bdf390616d99d', 'network_id': '5f2be991-62fb-4927-811e-d7a422f6a016', 'ip_version': 6, 'cidr': '3b37:bb03:b454:8b8:5fa7:8dec::/96', 'allocation_pools': [{'start': '3b37:bb03:b454:8b8:5fa7:8dec:0:2', 'end': '3b37:bb03:b454:8b8:5fa7:8dec:ffff:fffe'}], 'gateway_ip': '3b37:bb03:b454:8b8:5fa7:8dec:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3b37:bb03:b454:8b8:5fa7:8dec:0:2', 'tags': [], 'project_id': 'dbdda6759af44767a51bdf390616d99d'}} 2025-09-18 16:21:22,501 - INFO - Created VN ctest-vn4-04884685 2025-09-18 16:21:22,554 - DEBUG - VN ctest-vn4-04884685 UUID is 5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:22,735 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5f2be991-62fb-4927-811e-d7a422f6a016', 'name': 'ctest-vn4-04884685', 'tenant_id': 'dbdda6759af44767a51bdf390616d99d', 'project_id': 'dbdda6759af44767a51bdf390616d99d', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['d657cc46-74e3-47c9-bac2-11cc0d7076fb', '7ca86c54-c58f-4ea9-b277-16c5e90f676a'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85315532', 'ctest-vn4-04884685'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85315532', 'ctest-policy1-93170796']], 'subnet_ipam': [{'subnet_cidr': '150.18.249.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3b37:bb03:b454:8b8:5fa7:8dec::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-18 16:21:22,950 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-09-18 16:21:23,245 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-09-18 16:21:23,275 - DEBUG - Requesting: http://10.0.0.254:8082/domain/351a95ff-19e9-4a83-9fe6-28cecda65472 2025-09-18 16:21:23,286 - DEBUG - Requesting: http://10.0.0.254:8082/project/dbdda675-9af4-4767-a51b-df390616d99d 2025-09-18 16:21:23,356 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,367 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,377 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:23,384 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:23,390 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/7a30256e-1150-4fc4-9ade-7336aa5b3de8 2025-09-18 16:21:23,396 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-18 16:21:23,396 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,405 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:23,419 - INFO - Verified VN network id 12 for VN 5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,420 - INFO - Verifications in API Server for VN ctest-vn4-04884685 passed 2025-09-18 16:21:23,420 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,430 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:23,437 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:23,444 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/7a30256e-1150-4fc4-9ade-7336aa5b3de8 2025-09-18 16:21:23,456 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-85315532', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '6857831668241877287', 'uuid-lslong': '9304110980155219990'}, 'enable': 'true', 'created': '2025-09-18T16:21:22', 'last-modified': '2025-09-18T16:21:22', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.745264'} 2025-09-18 16:21:23,462 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-18 16:21:23,462 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-04884685 passed 2025-09-18 16:21:23,462 - DEBUG - ====Verifying policy data for ctest-vn4-04884685 in API_Server ====== 2025-09-18 16:21:23,462 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-09-18 16:21:23,467 - DEBUG - Requesting: http://10.0.0.254:8082/domain/351a95ff-19e9-4a83-9fe6-28cecda65472 2025-09-18 16:21:23,478 - DEBUG - Requesting: http://10.0.0.254:8082/project/dbdda675-9af4-4767-a51b-df390616d99d 2025-09-18 16:21:23,546 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/5f2be991-62fb-4927-811e-d7a422f6a016 2025-09-18 16:21:23,555 - DEBUG - ==>Verifying data for policy with id: 56591538-afac-4c73-8edb-acbfdc0f6bd8, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-85315532', 'ctest-policy1-93170796'] 2025-09-18 16:21:23,555 - INFO - VN ctest-vn4-04884685 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-18 16:21:23,555 - DEBUG - Verifying the vn in opserver 2025-09-18 16:21:23,555 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685 virtual network link through opserver 10.0.0.254 2025-09-18 16:21:23,555 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-09-18 16:21:23,843 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-09-18 16:21:23,892 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685?flat'} 2025-09-18 16:21:23,892 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-85315532:ctest-vn4-04884685 is found in opserver 2025-09-18 16:21:23,902 - DEBUG - Do not have enough data to verify VN in agent 2025-09-18 16:21:23,906 - DEBUG - VRF ids for VN ctest-vn4-04884685: {} 2025-09-18 16:21:23,906 - DEBUG - ====Verifying data for ctest-policy1-93170796 in API_Server ====== 2025-09-18 16:21:23,906 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-09-18 16:21:23,911 - DEBUG - Requesting: http://10.0.0.254:8082/domain/351a95ff-19e9-4a83-9fe6-28cecda65472 2025-09-18 16:21:23,921 - DEBUG - Requesting: http://10.0.0.254:8082/project/dbdda675-9af4-4767-a51b-df390616d99d 2025-09-18 16:21:23,988 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/56591538-afac-4c73-8edb-acbfdc0f6bd8 2025-09-18 16:21:23,996 - INFO - Verified policy ctest-policy1-93170796 in API Server, Result: True 2025-09-18 16:21:23,997 - INFO - Done with setup and verification, moving onto test .. 2025-09-18 16:21:24,005 - INFO - Deleting VN ctest-vn4-04884685 2025-09-18 16:21:24,107 - DEBUG - Response for deleting network () 2025-09-18 16:21:24,107 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/c4352fbe-e974-4db3-83c8-5d5725a0cbcb 2025-09-18 16:21:24,112 - DEBUG - Response Code: 404 2025-09-18 16:21:24,112 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-09-18 16:21:24,116 - DEBUG - Requesting: http://10.0.0.254:8082/domain/351a95ff-19e9-4a83-9fe6-28cecda65472 2025-09-18 16:21:24,167 - DEBUG - Requesting: http://10.0.0.254:8082/project/dbdda675-9af4-4767-a51b-df390616d99d 2025-09-18 16:21:24,233 - INFO - Validated that VN ctest-vn4-04884685 is not found in API Server 2025-09-18 16:21:24,243 - DEBUG - VN ctest-vn4-04884685 is not present in Agent 10.0.0.254 2025-09-18 16:21:24,243 - INFO - Validated that VN ctest-vn4-04884685 is not in any agent 2025-09-18 16:21:24,255 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-04884685 info 2025-09-18 16:21:24,277 - INFO - Deleted policy ctest-policy1-93170796 2025-09-18 16:21:24,450 - DEBUG - policy ctest-policy1-93170796 is not found in API Server 2025-09-18 16:21:24,703 - DEBUG - No XMPP flaps were noticed during the test 2025-09-18 16:21:24,703 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03] 2025-09-18 16:21:24,703 - INFO - -------------------------------------------------------------------------------- 2025-09-18 16:21:24,995 - DEBUG - No XMPP flaps were noticed during the test 2025-09-18 16:21:24,995 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-09-18 16:21:24,996 - INFO - -------------------------------------------------------------------------------- 2025-09-18 16:21:25,656 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-85315532, ID : dbdda675-9af4-4767-a51b-df390616d99d