2025-11-02 16:25:55,668 - INFO - Domain Default found not creating 2025-11-02 16:25:55,821 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-16270421 not found, creating it 2025-11-02 16:25:56,337 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-16270421, ID : a70025e7-c1f1-4b6e-b3e3-e890f5b733f4 2025-11-02 16:25:57,936 - INFO - ================================================================================ 2025-11-02 16:25:57,936 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-02 16:25:58,194 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.17': '0'}} with 2025-11-02 16:25:58,194 - INFO - Initial checks done. Running the testcase now 2025-11-02 16:25:58,194 - INFO - 2025-11-02 16:25:58,194 - INFO - ================================================================================ 2025-11-02 16:25:58,194 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-02 16:25:58,194 - 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-02 16:25:58,485 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.17': '0'}} with 2025-11-02 16:25:58,485 - INFO - Initial checks done. Running the testcase now 2025-11-02 16:25:58,485 - INFO - 2025-11-02 16:25:58,877 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573, 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-16270421:ctest-vn4-15444573, 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-16270421:ctest-vn4-15444573, 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-16270421:ctest-vn4-15444573, 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-02 16:25:59,408 - DEBUG - Response for create_network : {'network': {'id': '883993e8-9f68-45be-bf8c-c19f6ea19fad', 'name': 'ctest-vn4-15444573', 'tenant_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'project_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-16270421', 'ctest-vn4-15444573'], 'port_security_enabled': True, 'description': ''}} 2025-11-02 16:25:59,592 - DEBUG - Response for create_subnet : {'subnet': {'id': '33fc5bca-3160-4cb8-bf44-31c45267cc86', 'name': '', 'tenant_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'network_id': '883993e8-9f68-45be-bf8c-c19f6ea19fad', 'ip_version': 4, 'cidr': '165.227.155.0/26', 'allocation_pools': [{'start': '165.227.155.2', 'end': '165.227.155.62'}], 'gateway_ip': '165.227.155.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '165.227.155.2', 'tags': [], 'project_id': 'a70025e7c1f14b6eb3e3e890f5b733f4'}} 2025-11-02 16:25:59,753 - DEBUG - Response for create_subnet : {'subnet': {'id': '8eed161d-84ba-4ba6-8773-3ad14f2dd331', 'name': '', 'tenant_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'network_id': '883993e8-9f68-45be-bf8c-c19f6ea19fad', 'ip_version': 6, 'cidr': '2ddb:f721:b501:3e8a:acac:982f::/96', 'allocation_pools': [{'start': '2ddb:f721:b501:3e8a:acac:982f:0:2', 'end': '2ddb:f721:b501:3e8a:acac:982f:ffff:fffe'}], 'gateway_ip': '2ddb:f721:b501:3e8a:acac:982f:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2ddb:f721:b501:3e8a:acac:982f:0:2', 'tags': [], 'project_id': 'a70025e7c1f14b6eb3e3e890f5b733f4'}} 2025-11-02 16:25:59,774 - INFO - Created VN ctest-vn4-15444573 2025-11-02 16:25:59,824 - DEBUG - VN ctest-vn4-15444573 UUID is 883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,030 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '883993e8-9f68-45be-bf8c-c19f6ea19fad', 'name': 'ctest-vn4-15444573', 'tenant_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'project_id': 'a70025e7c1f14b6eb3e3e890f5b733f4', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['33fc5bca-3160-4cb8-bf44-31c45267cc86', '8eed161d-84ba-4ba6-8773-3ad14f2dd331'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-16270421', 'ctest-vn4-15444573'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-16270421', 'ctest-policy1-38845819']], 'subnet_ipam': [{'subnet_cidr': '165.227.155.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2ddb:f721:b501:3e8a:acac:982f::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-02 16:26:00,200 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-11-02 16:26:00,532 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-11-02 16:26:00,562 - DEBUG - Requesting: http://10.0.0.48:8082/domain/b1118436-1b87-42aa-8ee9-d27497dd1d27 2025-11-02 16:26:00,575 - DEBUG - Requesting: http://10.0.0.48:8082/project/a70025e7-c1f1-4b6e-b3e3-e890f5b733f4 2025-11-02 16:26:00,733 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,746 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,756 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:00,763 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:00,772 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/eca0cfcd-1e46-4ea9-9c78-ca6d50ea6696 2025-11-02 16:26:00,779 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-02 16:26:00,779 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,788 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:00,802 - INFO - Verified VN network id 11 for VN 883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,802 - INFO - Verifications in API Server for VN ctest-vn4-15444573 passed 2025-11-02 16:26:00,802 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,811 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:00,817 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:00,823 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/eca0cfcd-1e46-4ea9-9c78-ca6d50ea6696 2025-11-02 16:26:00,834 - DEBUG - Control-node 10.0.0.48 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-16270421', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '9816039490146813374', 'uuid-lslong': '13802619848483774381'}, 'enable': 'true', 'created': '2025-11-02T16:25:59', 'last-modified': '2025-11-02T16:25:59', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.831252'} 2025-11-02 16:26:00,839 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-02 16:26:00,839 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-15444573 passed 2025-11-02 16:26:00,840 - DEBUG - ====Verifying policy data for ctest-vn4-15444573 in API_Server ====== 2025-11-02 16:26:00,840 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-11-02 16:26:00,846 - DEBUG - Requesting: http://10.0.0.48:8082/domain/b1118436-1b87-42aa-8ee9-d27497dd1d27 2025-11-02 16:26:00,857 - DEBUG - Requesting: http://10.0.0.48:8082/project/a70025e7-c1f1-4b6e-b3e3-e890f5b733f4 2025-11-02 16:26:00,926 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/883993e8-9f68-45be-bf8c-c19f6ea19fad 2025-11-02 16:26:00,935 - DEBUG - ==>Verifying data for policy with id: ec38180d-ba1f-4e8e-b728-21d0a76b230a, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-16270421', 'ctest-policy1-38845819'] 2025-11-02 16:26:00,936 - INFO - VN ctest-vn4-15444573 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-02 16:26:00,936 - DEBUG - Verifying the vn in opserver 2025-11-02 16:26:00,936 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573 virtual network link through opserver 10.0.0.48 2025-11-02 16:26:00,936 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-11-02 16:26:01,269 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-11-02 16:26:01,334 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573', 'href': 'http://10.0.0.48:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573?flat'} 2025-11-02 16:26:01,334 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-16270421:ctest-vn4-15444573 is found in opserver 2025-11-02 16:26:01,346 - DEBUG - Do not have enough data to verify VN in agent 2025-11-02 16:26:01,351 - DEBUG - VRF ids for VN ctest-vn4-15444573: {} 2025-11-02 16:26:01,352 - DEBUG - ====Verifying data for ctest-policy1-38845819 in API_Server ====== 2025-11-02 16:26:01,352 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-11-02 16:26:01,358 - DEBUG - Requesting: http://10.0.0.48:8082/domain/b1118436-1b87-42aa-8ee9-d27497dd1d27 2025-11-02 16:26:01,371 - DEBUG - Requesting: http://10.0.0.48:8082/project/a70025e7-c1f1-4b6e-b3e3-e890f5b733f4 2025-11-02 16:26:01,448 - DEBUG - Requesting: http://10.0.0.48:8082/network-policy/ec38180d-ba1f-4e8e-b728-21d0a76b230a 2025-11-02 16:26:01,459 - INFO - Verified policy ctest-policy1-38845819 in API Server, Result: True 2025-11-02 16:26:01,459 - INFO - Done with setup and verification, moving onto test .. 2025-11-02 16:26:01,467 - INFO - Deleting VN ctest-vn4-15444573 2025-11-02 16:26:01,582 - DEBUG - Response for deleting network () 2025-11-02 16:26:01,582 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/8a059f26-a76b-490c-91f8-0e1e538adbc4 2025-11-02 16:26:01,587 - DEBUG - Response Code: 404 2025-11-02 16:26:01,588 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-11-02 16:26:01,592 - DEBUG - Requesting: http://10.0.0.48:8082/domain/b1118436-1b87-42aa-8ee9-d27497dd1d27 2025-11-02 16:26:01,645 - DEBUG - Requesting: http://10.0.0.48:8082/project/a70025e7-c1f1-4b6e-b3e3-e890f5b733f4 2025-11-02 16:26:01,716 - INFO - Validated that VN ctest-vn4-15444573 is not found in API Server 2025-11-02 16:26:01,725 - DEBUG - VN ctest-vn4-15444573 is not present in Agent 10.0.0.48 2025-11-02 16:26:01,726 - INFO - Validated that VN ctest-vn4-15444573 is not in any agent 2025-11-02 16:26:01,739 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-15444573 info 2025-11-02 16:26:01,765 - INFO - Deleted policy ctest-policy1-38845819 2025-11-02 16:26:01,932 - DEBUG - policy ctest-policy1-38845819 is not found in API Server 2025-11-02 16:26:02,185 - DEBUG - No XMPP flaps were noticed during the test 2025-11-02 16:26:02,185 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-11-02 16:26:02,185 - INFO - -------------------------------------------------------------------------------- 2025-11-02 16:26:02,473 - DEBUG - No XMPP flaps were noticed during the test 2025-11-02 16:26:02,473 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05] 2025-11-02 16:26:02,473 - INFO - -------------------------------------------------------------------------------- 2025-11-02 16:26:03,225 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-16270421, ID : a70025e7-c1f1-4b6e-b3e3-e890f5b733f4