2025-10-11 16:51:30,507 - INFO - Domain Default found not creating 2025-10-11 16:51:30,648 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-40596495 not found, creating it 2025-10-11 16:51:31,085 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-40596495, ID : f70ad4c0-660a-4328-a23b-a6bd803ddc00 2025-10-11 16:51:32,502 - INFO - ================================================================================ 2025-10-11 16:51:32,503 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-11 16:51:32,628 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-10-11 16:51:32,628 - INFO - Initial checks done. Running the testcase now 2025-10-11 16:51:32,628 - INFO - 2025-10-11 16:51:32,628 - INFO - ================================================================================ 2025-10-11 16:51:32,628 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-10-11 16:51:32,628 - 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-11 16:51:32,795 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-10-11 16:51:32,795 - INFO - Initial checks done. Running the testcase now 2025-10-11 16:51:32,795 - INFO - 2025-10-11 16:51:33,137 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871, 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-40596495:ctest-vn4-36812871, 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-40596495:ctest-vn4-36812871, 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-40596495:ctest-vn4-36812871, 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-11 16:51:33,633 - DEBUG - Response for create_network : {'network': {'id': '51178bfc-98e1-4f3c-a656-0457eb8abc8e', 'name': 'ctest-vn4-36812871', 'tenant_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'project_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-40596495', 'ctest-vn4-36812871'], 'port_security_enabled': True, 'description': ''}} 2025-10-11 16:51:33,785 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a02315da-7d07-4ba4-b2e2-6ed59fb715a6', 'name': '', 'tenant_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'network_id': '51178bfc-98e1-4f3c-a656-0457eb8abc8e', 'ip_version': 4, 'cidr': '51.165.16.128/26', 'allocation_pools': [{'start': '51.165.16.130', 'end': '51.165.16.190'}], 'gateway_ip': '51.165.16.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '51.165.16.130', 'tags': [], 'project_id': 'f70ad4c0660a4328a23ba6bd803ddc00'}} 2025-10-11 16:51:33,933 - DEBUG - Response for create_subnet : {'subnet': {'id': '57984e58-d3b1-4cfb-a665-bfa06a33c137', 'name': '', 'tenant_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'network_id': '51178bfc-98e1-4f3c-a656-0457eb8abc8e', 'ip_version': 6, 'cidr': '31e6:eabe:fb59:8b74:ff77:c785::/96', 'allocation_pools': [{'start': '31e6:eabe:fb59:8b74:ff77:c785:0:2', 'end': '31e6:eabe:fb59:8b74:ff77:c785:ffff:fffe'}], 'gateway_ip': '31e6:eabe:fb59:8b74:ff77:c785:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '31e6:eabe:fb59:8b74:ff77:c785:0:2', 'tags': [], 'project_id': 'f70ad4c0660a4328a23ba6bd803ddc00'}} 2025-10-11 16:51:33,952 - INFO - Created VN ctest-vn4-36812871 2025-10-11 16:51:34,006 - DEBUG - VN ctest-vn4-36812871 UUID is 51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,194 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '51178bfc-98e1-4f3c-a656-0457eb8abc8e', 'name': 'ctest-vn4-36812871', 'tenant_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'project_id': 'f70ad4c0660a4328a23ba6bd803ddc00', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['a02315da-7d07-4ba4-b2e2-6ed59fb715a6', '57984e58-d3b1-4cfb-a665-bfa06a33c137'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-40596495', 'ctest-vn4-36812871'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-40596495', 'ctest-policy1-62440840']], 'subnet_ipam': [{'subnet_cidr': '51.165.16.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '31e6:eabe:fb59:8b74:ff77:c785::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-10-11 16:51:34,442 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-11 16:51:34,732 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-11 16:51:34,761 - DEBUG - Requesting: http://10.0.0.254:8082/domain/1c888893-7c1f-46a1-80b1-cf2038627f3c 2025-10-11 16:51:34,773 - DEBUG - Requesting: http://10.0.0.254:8082/project/f70ad4c0-660a-4328-a23b-a6bd803ddc00 2025-10-11 16:51:34,858 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,886 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,895 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:34,902 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:34,909 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/8dfad670-d51f-4f1d-8eb8-9609b39d8ce2 2025-10-11 16:51:34,916 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-11 16:51:34,916 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,926 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:34,940 - INFO - Verified VN network id 12 for VN 51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,941 - INFO - Verifications in API Server for VN ctest-vn4-36812871 passed 2025-10-11 16:51:34,941 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:34,951 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:34,957 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:34,964 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/8dfad670-d51f-4f1d-8eb8-9609b39d8ce2 2025-10-11 16:51:34,976 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-40596495', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '5843292958549430076', 'uuid-lslong': '11985772233953557646'}, 'enable': 'true', 'created': '2025-10-11T16:51:33', 'last-modified': '2025-10-11T16:51:34', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.807796'} 2025-10-11 16:51:34,982 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-10-11 16:51:34,982 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-36812871 passed 2025-10-11 16:51:34,982 - DEBUG - ====Verifying policy data for ctest-vn4-36812871 in API_Server ====== 2025-10-11 16:51:34,982 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-11 16:51:34,987 - DEBUG - Requesting: http://10.0.0.254:8082/domain/1c888893-7c1f-46a1-80b1-cf2038627f3c 2025-10-11 16:51:34,998 - DEBUG - Requesting: http://10.0.0.254:8082/project/f70ad4c0-660a-4328-a23b-a6bd803ddc00 2025-10-11 16:51:35,076 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/51178bfc-98e1-4f3c-a656-0457eb8abc8e 2025-10-11 16:51:35,089 - DEBUG - ==>Verifying data for policy with id: b43b938d-b189-4244-b4ec-61e09567e396, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-40596495', 'ctest-policy1-62440840'] 2025-10-11 16:51:35,089 - INFO - VN ctest-vn4-36812871 Policy verification: verify_vn_policy_in_api_server, status: True 2025-10-11 16:51:35,089 - DEBUG - Verifying the vn in opserver 2025-10-11 16:51:35,089 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871 virtual network link through opserver 10.0.0.254 2025-10-11 16:51:35,089 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-10-11 16:51:35,382 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-10-11 16:51:35,438 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871?flat'} 2025-10-11 16:51:35,438 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-40596495:ctest-vn4-36812871 is found in opserver 2025-10-11 16:51:35,449 - DEBUG - Do not have enough data to verify VN in agent 2025-10-11 16:51:35,454 - DEBUG - VRF ids for VN ctest-vn4-36812871: {} 2025-10-11 16:51:35,454 - DEBUG - ====Verifying data for ctest-policy1-62440840 in API_Server ====== 2025-10-11 16:51:35,454 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-11 16:51:35,460 - DEBUG - Requesting: http://10.0.0.254:8082/domain/1c888893-7c1f-46a1-80b1-cf2038627f3c 2025-10-11 16:51:35,470 - DEBUG - Requesting: http://10.0.0.254:8082/project/f70ad4c0-660a-4328-a23b-a6bd803ddc00 2025-10-11 16:51:35,540 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/b43b938d-b189-4244-b4ec-61e09567e396 2025-10-11 16:51:35,550 - INFO - Verified policy ctest-policy1-62440840 in API Server, Result: True 2025-10-11 16:51:35,550 - INFO - Done with setup and verification, moving onto test .. 2025-10-11 16:51:35,558 - INFO - Deleting VN ctest-vn4-36812871 2025-10-11 16:51:35,680 - DEBUG - Response for deleting network () 2025-10-11 16:51:35,680 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/94e0a02d-29e8-4a2d-ad2d-4f3dd8988357 2025-10-11 16:51:35,685 - DEBUG - Response Code: 404 2025-10-11 16:51:35,685 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-10-11 16:51:35,691 - DEBUG - Requesting: http://10.0.0.254:8082/domain/1c888893-7c1f-46a1-80b1-cf2038627f3c 2025-10-11 16:51:35,747 - DEBUG - Requesting: http://10.0.0.254:8082/project/f70ad4c0-660a-4328-a23b-a6bd803ddc00 2025-10-11 16:51:35,817 - INFO - Validated that VN ctest-vn4-36812871 is not found in API Server 2025-10-11 16:51:35,828 - DEBUG - VN ctest-vn4-36812871 is not present in Agent 10.0.0.254 2025-10-11 16:51:35,828 - INFO - Validated that VN ctest-vn4-36812871 is not in any agent 2025-10-11 16:51:35,844 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-36812871 info 2025-10-11 16:51:35,873 - INFO - Deleted policy ctest-policy1-62440840 2025-10-11 16:51:36,045 - DEBUG - policy ctest-policy1-62440840 is not found in API Server 2025-10-11 16:51:36,172 - DEBUG - No XMPP flaps were noticed during the test
2025-10-11 16:51:36,173 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-10-11 16:51:36,173 - INFO - -------------------------------------------------------------------------------- 2025-10-11 16:51:36,333 - DEBUG - No XMPP flaps were noticed during the test
2025-10-11 16:51:36,333 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-10-11 16:51:36,333 - INFO - -------------------------------------------------------------------------------- 2025-10-11 16:51:36,999 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-40596495, ID : f70ad4c0-660a-4328-a23b-a6bd803ddc00