2025-08-19 13:16:43,306 - INFO - Domain Default found not creating 2025-08-19 13:16:43,442 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-75107996 not found, creating it 2025-08-19 13:16:43,875 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-75107996, ID : 5b54f5b8-8ce5-4c3a-839b-8b65d32f9646 2025-08-19 13:16:45,367 - INFO - ================================================================================ 2025-08-19 13:16:45,368 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-19 13:16:45,624 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.17': '0'}} with 2025-08-19 13:16:45,624 - INFO - Initial checks done. Running the testcase now 2025-08-19 13:16:45,624 - INFO - 2025-08-19 13:16:45,624 - INFO - ================================================================================ 2025-08-19 13:16:45,624 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-19 13:16:45,624 - 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-08-19 13:16:45,915 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.17': '0'}} with 2025-08-19 13:16:45,915 - INFO - Initial checks done. Running the testcase now 2025-08-19 13:16:45,915 - INFO - 2025-08-19 13:16:46,301 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664, 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-75107996:ctest-vn4-20993664, 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-75107996:ctest-vn4-20993664, 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-75107996:ctest-vn4-20993664, 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-08-19 13:16:46,820 - DEBUG - Response for create_network : {'network': {'id': 'f6fc31ac-2fa4-4524-95e5-62151d6ffb7f', 'name': 'ctest-vn4-20993664', 'tenant_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'project_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75107996', 'ctest-vn4-20993664'], 'port_security_enabled': True, 'description': ''}} 2025-08-19 13:16:46,994 - DEBUG - Response for create_subnet : {'subnet': {'id': '8ddb5857-3630-40f6-ab33-1f13f537f008', 'name': '', 'tenant_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'network_id': 'f6fc31ac-2fa4-4524-95e5-62151d6ffb7f', 'ip_version': 4, 'cidr': '220.58.28.128/26', 'allocation_pools': [{'start': '220.58.28.130', 'end': '220.58.28.190'}], 'gateway_ip': '220.58.28.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '220.58.28.130', 'tags': [], 'project_id': '5b54f5b88ce54c3a839b8b65d32f9646'}} 2025-08-19 13:16:47,177 - DEBUG - Response for create_subnet : {'subnet': {'id': '1da156d5-aa9d-444d-b026-d5afc46a2ee7', 'name': '', 'tenant_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'network_id': 'f6fc31ac-2fa4-4524-95e5-62151d6ffb7f', 'ip_version': 6, 'cidr': '30bb:615a:d98c:fa21:7f0c:1bfa::/96', 'allocation_pools': [{'start': '30bb:615a:d98c:fa21:7f0c:1bfa:0:2', 'end': '30bb:615a:d98c:fa21:7f0c:1bfa:ffff:fffe'}], 'gateway_ip': '30bb:615a:d98c:fa21:7f0c:1bfa:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '30bb:615a:d98c:fa21:7f0c:1bfa:0:2', 'tags': [], 'project_id': '5b54f5b88ce54c3a839b8b65d32f9646'}} 2025-08-19 13:16:47,197 - INFO - Created VN ctest-vn4-20993664 2025-08-19 13:16:47,249 - DEBUG - VN ctest-vn4-20993664 UUID is f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:47,454 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'f6fc31ac-2fa4-4524-95e5-62151d6ffb7f', 'name': 'ctest-vn4-20993664', 'tenant_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'project_id': '5b54f5b88ce54c3a839b8b65d32f9646', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['8ddb5857-3630-40f6-ab33-1f13f537f008', '1da156d5-aa9d-444d-b026-d5afc46a2ee7'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75107996', 'ctest-vn4-20993664'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75107996', 'ctest-policy1-15789007']], 'subnet_ipam': [{'subnet_cidr': '220.58.28.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '30bb:615a:d98c:fa21:7f0c:1bfa::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-19 13:16:47,613 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-19 13:16:47,944 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-19 13:16:47,973 - DEBUG - Requesting: http://10.0.0.254:8082/domain/793617c3-e58a-496d-8e56-9d2c8a96cae8 2025-08-19 13:16:47,986 - DEBUG - Requesting: http://10.0.0.254:8082/project/5b54f5b8-8ce5-4c3a-839b-8b65d32f9646 2025-08-19 13:16:48,060 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,073 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,084 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,091 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,099 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/bc4a719e-9eb9-45b2-ab32-6f9288ca3757 2025-08-19 13:16:48,105 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-19 13:16:48,105 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,115 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,129 - INFO - Verified VN network id 11 for VN f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,129 - INFO - Verifications in API Server for VN ctest-vn4-20993664 passed 2025-08-19 13:16:48,129 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,139 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,145 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,152 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/bc4a719e-9eb9-45b2-ab32-6f9288ca3757 2025-08-19 13:16:48,165 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-75107996', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '17797154443064788260', 'uuid-lslong': '10801147124145716095'}, 'enable': 'true', 'created': '2025-08-19T13:16:46', 'last-modified': '2025-08-19T13:16:47', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.745629'} 2025-08-19 13:16:48,172 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-19 13:16:48,172 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-20993664 passed 2025-08-19 13:16:48,172 - DEBUG - ====Verifying policy data for ctest-vn4-20993664 in API_Server ====== 2025-08-19 13:16:48,172 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-19 13:16:48,177 - DEBUG - Requesting: http://10.0.0.254:8082/domain/793617c3-e58a-496d-8e56-9d2c8a96cae8 2025-08-19 13:16:48,188 - DEBUG - Requesting: http://10.0.0.254:8082/project/5b54f5b8-8ce5-4c3a-839b-8b65d32f9646 2025-08-19 13:16:48,260 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/f6fc31ac-2fa4-4524-95e5-62151d6ffb7f 2025-08-19 13:16:48,271 - DEBUG - ==>Verifying data for policy with id: 666c9e61-b906-4114-af33-0a7f4b1d96af, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75107996', 'ctest-policy1-15789007'] 2025-08-19 13:16:48,271 - INFO - VN ctest-vn4-20993664 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-19 13:16:48,271 - DEBUG - Verifying the vn in opserver 2025-08-19 13:16:48,271 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664 virtual network link through opserver 10.0.0.254 2025-08-19 13:16:48,271 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-19 13:16:48,602 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-19 13:16:48,655 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664?flat'} 2025-08-19 13:16:48,655 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75107996:ctest-vn4-20993664 is found in opserver 2025-08-19 13:16:48,666 - DEBUG - Do not have enough data to verify VN in agent 2025-08-19 13:16:48,671 - DEBUG - VRF ids for VN ctest-vn4-20993664: {} 2025-08-19 13:16:48,672 - DEBUG - ====Verifying data for ctest-policy1-15789007 in API_Server ====== 2025-08-19 13:16:48,672 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-19 13:16:48,677 - DEBUG - Requesting: http://10.0.0.254:8082/domain/793617c3-e58a-496d-8e56-9d2c8a96cae8 2025-08-19 13:16:48,688 - DEBUG - Requesting: http://10.0.0.254:8082/project/5b54f5b8-8ce5-4c3a-839b-8b65d32f9646 2025-08-19 13:16:48,759 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/666c9e61-b906-4114-af33-0a7f4b1d96af 2025-08-19 13:16:48,770 - INFO - Verified policy ctest-policy1-15789007 in API Server, Result: True 2025-08-19 13:16:48,770 - INFO - Done with setup and verification, moving onto test .. 2025-08-19 13:16:48,778 - INFO - Deleting VN ctest-vn4-20993664 2025-08-19 13:16:48,913 - DEBUG - Response for deleting network () 2025-08-19 13:16:48,913 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/75cdd056-308f-47ab-bf89-731e700e7fd6 2025-08-19 13:16:48,919 - DEBUG - Response Code: 404 2025-08-19 13:16:48,919 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-19 13:16:48,925 - DEBUG - Requesting: http://10.0.0.254:8082/domain/793617c3-e58a-496d-8e56-9d2c8a96cae8 2025-08-19 13:16:48,982 - DEBUG - Requesting: http://10.0.0.254:8082/project/5b54f5b8-8ce5-4c3a-839b-8b65d32f9646 2025-08-19 13:16:49,058 - INFO - Validated that VN ctest-vn4-20993664 is not found in API Server 2025-08-19 13:16:49,069 - DEBUG - VN ctest-vn4-20993664 is not present in Agent 10.0.0.254 2025-08-19 13:16:49,069 - INFO - Validated that VN ctest-vn4-20993664 is not in any agent 2025-08-19 13:16:49,085 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-20993664 info 2025-08-19 13:16:49,111 - INFO - Deleted policy ctest-policy1-15789007 2025-08-19 13:16:49,273 - DEBUG - policy ctest-policy1-15789007 is not found in API Server 2025-08-19 13:16:49,526 - DEBUG - No XMPP flaps were noticed during the test 2025-08-19 13:16:49,526 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-19 13:16:49,527 - INFO - -------------------------------------------------------------------------------- 2025-08-19 13:16:49,816 - DEBUG - No XMPP flaps were noticed during the test 2025-08-19 13:16:49,816 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-19 13:16:49,816 - INFO - -------------------------------------------------------------------------------- 2025-08-19 13:16:50,521 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-75107996, ID : 5b54f5b8-8ce5-4c3a-839b-8b65d32f9646