2025-10-27 20:57:19,210 - INFO - Domain Default found not creating 2025-10-27 20:57:19,357 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-36161840 not found, creating it 2025-10-27 20:57:19,809 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-36161840, ID : 6f77754c-f891-4fe8-bdfd-cfcdd2de2139 2025-10-27 20:57:21,309 - INFO - ================================================================================ 2025-10-27 20:57:21,309 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-27 20:57:21,561 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.17': '0'}} with 2025-10-27 20:57:21,561 - INFO - Initial checks done. Running the testcase now 2025-10-27 20:57:21,561 - INFO - 2025-10-27 20:57:21,561 - INFO - ================================================================================ 2025-10-27 20:57:21,561 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-27 20:57:21,561 - 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-10-27 20:57:21,854 - DEBUG - Nothing to compare xmpp stats {'10.0.0.242': {'10.20.0.17': '0'}} with 2025-10-27 20:57:21,854 - INFO - Initial checks done. Running the testcase now 2025-10-27 20:57:21,854 - INFO - 2025-10-27 20:57:22,242 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582, 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-36161840:ctest-vn4-73158582, 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-36161840:ctest-vn4-73158582, 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-36161840:ctest-vn4-73158582, 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-10-27 20:57:22,724 - DEBUG - Response for create_network : {'network': {'id': '21704d41-10c6-46e5-9136-0b2dbdcb9b5b', 'name': 'ctest-vn4-73158582', 'tenant_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'project_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-36161840', 'ctest-vn4-73158582'], 'port_security_enabled': True, 'description': ''}} 2025-10-27 20:57:22,875 - DEBUG - Response for create_subnet : {'subnet': {'id': '87f6a8be-d7a6-4911-9e5e-bd77cf22b511', 'name': '', 'tenant_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'network_id': '21704d41-10c6-46e5-9136-0b2dbdcb9b5b', 'ip_version': 4, 'cidr': '39.115.129.0/26', 'allocation_pools': [{'start': '39.115.129.2', 'end': '39.115.129.62'}], 'gateway_ip': '39.115.129.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '39.115.129.2', 'tags': [], 'project_id': '6f77754cf8914fe8bdfdcfcdd2de2139'}} 2025-10-27 20:57:23,076 - DEBUG - Response for create_subnet : {'subnet': {'id': '90fc3678-4cf8-4a4d-98a1-31af6d08b04e', 'name': '', 'tenant_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'network_id': '21704d41-10c6-46e5-9136-0b2dbdcb9b5b', 'ip_version': 6, 'cidr': '2af7:97b0:3719:d818:1422:30e6::/96', 'allocation_pools': [{'start': '2af7:97b0:3719:d818:1422:30e6:0:2', 'end': '2af7:97b0:3719:d818:1422:30e6:ffff:fffe'}], 'gateway_ip': '2af7:97b0:3719:d818:1422:30e6:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2af7:97b0:3719:d818:1422:30e6:0:2', 'tags': [], 'project_id': '6f77754cf8914fe8bdfdcfcdd2de2139'}} 2025-10-27 20:57:23,095 - INFO - Created VN ctest-vn4-73158582 2025-10-27 20:57:23,150 - DEBUG - VN ctest-vn4-73158582 UUID is 21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:23,336 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '21704d41-10c6-46e5-9136-0b2dbdcb9b5b', 'name': 'ctest-vn4-73158582', 'tenant_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'project_id': '6f77754cf8914fe8bdfdcfcdd2de2139', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['87f6a8be-d7a6-4911-9e5e-bd77cf22b511', '90fc3678-4cf8-4a4d-98a1-31af6d08b04e'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-36161840', 'ctest-vn4-73158582'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-36161840', 'ctest-policy1-74645000']], 'subnet_ipam': [{'subnet_cidr': '39.115.129.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2af7:97b0:3719:d818:1422:30e6::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-10-27 20:57:23,492 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-10-27 20:57:23,822 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-10-27 20:57:23,850 - DEBUG - Requesting: http://10.0.0.242:8082/domain/8e06770b-6f40-410a-9492-db45fd454d4c 2025-10-27 20:57:23,862 - DEBUG - Requesting: http://10.0.0.242:8082/project/6f77754c-f891-4fe8-bdfd-cfcdd2de2139 2025-10-27 20:57:23,937 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:23,948 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:23,957 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:23,963 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:23,970 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/646627c8-c653-4458-880b-9e78f09b25f3 2025-10-27 20:57:23,975 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-27 20:57:23,975 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:23,984 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:23,996 - INFO - Verified VN network id 11 for VN 21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:23,996 - INFO - Verifications in API Server for VN ctest-vn4-73158582 passed 2025-10-27 20:57:23,996 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:24,007 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:24,013 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:24,019 - DEBUG - Requesting: http://10.0.0.242:8082/route-target/646627c8-c653-4458-880b-9e78f09b25f3 2025-10-27 20:57:24,030 - DEBUG - Control-node 10.0.0.242 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-36161840', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '2409510742492858085', 'uuid-lslong': '10463563075327597403'}, 'enable': 'true', 'created': '2025-10-27T20:57:22', 'last-modified': '2025-10-27T20:57:23', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.720223'} 2025-10-27 20:57:24,038 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-27 20:57:24,038 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-73158582 passed 2025-10-27 20:57:24,038 - DEBUG - ====Verifying policy data for ctest-vn4-73158582 in API_Server ====== 2025-10-27 20:57:24,038 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-10-27 20:57:24,043 - DEBUG - Requesting: http://10.0.0.242:8082/domain/8e06770b-6f40-410a-9492-db45fd454d4c 2025-10-27 20:57:24,053 - DEBUG - Requesting: http://10.0.0.242:8082/project/6f77754c-f891-4fe8-bdfd-cfcdd2de2139 2025-10-27 20:57:24,122 - DEBUG - Requesting: http://10.0.0.242:8082/virtual-network/21704d41-10c6-46e5-9136-0b2dbdcb9b5b 2025-10-27 20:57:24,132 - DEBUG - ==>Verifying data for policy with id: a9fb9896-d3f7-4d6f-b5a1-ebdf61196894, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-36161840', 'ctest-policy1-74645000'] 2025-10-27 20:57:24,133 - INFO - VN ctest-vn4-73158582 Policy verification: verify_vn_policy_in_api_server, status: True 2025-10-27 20:57:24,133 - DEBUG - Verifying the vn in opserver 2025-10-27 20:57:24,133 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582 virtual network link through opserver 10.0.0.242 2025-10-27 20:57:24,133 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-10-27 20:57:24,464 - DEBUG - Requesting: http://10.0.0.242:8081/analytics/uves/virtual-networks 2025-10-27 20:57:24,519 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582', 'href': 'http://10.0.0.242:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582?flat'} 2025-10-27 20:57:24,519 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-36161840:ctest-vn4-73158582 is found in opserver 2025-10-27 20:57:24,529 - DEBUG - Do not have enough data to verify VN in agent 2025-10-27 20:57:24,533 - DEBUG - VRF ids for VN ctest-vn4-73158582: {} 2025-10-27 20:57:24,533 - DEBUG - ====Verifying data for ctest-policy1-74645000 in API_Server ====== 2025-10-27 20:57:24,533 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-10-27 20:57:24,538 - DEBUG - Requesting: http://10.0.0.242:8082/domain/8e06770b-6f40-410a-9492-db45fd454d4c 2025-10-27 20:57:24,548 - DEBUG - Requesting: http://10.0.0.242:8082/project/6f77754c-f891-4fe8-bdfd-cfcdd2de2139 2025-10-27 20:57:24,620 - DEBUG - Requesting: http://10.0.0.242:8082/network-policy/a9fb9896-d3f7-4d6f-b5a1-ebdf61196894 2025-10-27 20:57:24,629 - INFO - Verified policy ctest-policy1-74645000 in API Server, Result: True 2025-10-27 20:57:24,629 - INFO - Done with setup and verification, moving onto test .. 2025-10-27 20:57:24,637 - INFO - Deleting VN ctest-vn4-73158582 2025-10-27 20:57:24,766 - DEBUG - Response for deleting network () 2025-10-27 20:57:24,766 - DEBUG - Requesting: http://10.0.0.242:8082/routing-instance/1c9ab7f3-fa7a-4734-a0e7-aa265420d076 2025-10-27 20:57:24,771 - DEBUG - Response Code: 404 2025-10-27 20:57:24,771 - DEBUG - Requesting: http://10.0.0.242:8082/domains 2025-10-27 20:57:24,776 - DEBUG - Requesting: http://10.0.0.242:8082/domain/8e06770b-6f40-410a-9492-db45fd454d4c 2025-10-27 20:57:24,829 - DEBUG - Requesting: http://10.0.0.242:8082/project/6f77754c-f891-4fe8-bdfd-cfcdd2de2139 2025-10-27 20:57:24,893 - INFO - Validated that VN ctest-vn4-73158582 is not found in API Server 2025-10-27 20:57:24,902 - DEBUG - VN ctest-vn4-73158582 is not present in Agent 10.0.0.242 2025-10-27 20:57:24,903 - INFO - Validated that VN ctest-vn4-73158582 is not in any agent 2025-10-27 20:57:24,916 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-73158582 info 2025-10-27 20:57:24,941 - INFO - Deleted policy ctest-policy1-74645000 2025-10-27 20:57:25,116 - DEBUG - policy ctest-policy1-74645000 is not found in API Server 2025-10-27 20:57:25,377 - DEBUG - No XMPP flaps were noticed during the test
2025-10-27 20:57:25,377 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-10-27 20:57:25,377 - INFO - -------------------------------------------------------------------------------- 2025-10-27 20:57:25,673 - DEBUG - No XMPP flaps were noticed during the test
2025-10-27 20:57:25,673 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-10-27 20:57:25,673 - INFO - -------------------------------------------------------------------------------- 2025-10-27 20:57:26,382 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-36161840, ID : 6f77754c-f891-4fe8-bdfd-cfcdd2de2139