2025-08-07 14:23:41,388 - INFO - Domain Default found not creating 2025-08-07 14:23:41,560 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-75446647 not found, creating it 2025-08-07 14:23:42,012 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-75446647, ID : 334bee42-3350-4fcc-b2e8-bca4fa989e83 2025-08-07 14:23:43,469 - INFO - ================================================================================ 2025-08-07 14:23:43,469 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-07 14:23:43,725 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-08-07 14:23:43,725 - INFO - Initial checks done. Running the testcase now 2025-08-07 14:23:43,725 - INFO - 2025-08-07 14:23:43,725 - INFO - ================================================================================ 2025-08-07 14:23:43,725 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-08-07 14:23:43,725 - 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-07 14:23:44,016 - DEBUG - Nothing to compare xmpp stats {'10.0.0.254': {'10.20.0.254': '0'}} with 2025-08-07 14:23:44,016 - INFO - Initial checks done. Running the testcase now 2025-08-07 14:23:44,016 - INFO - 2025-08-07 14:23:44,361 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350, 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-75446647:ctest-vn4-68522350, 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-75446647:ctest-vn4-68522350, 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-75446647:ctest-vn4-68522350, 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-07 14:23:44,874 - DEBUG - Response for create_network : {'network': {'id': '4fa21248-98c1-44cd-aa93-2409a5c51397', 'name': 'ctest-vn4-68522350', 'tenant_id': '334bee4233504fccb2e8bca4fa989e83', 'project_id': '334bee4233504fccb2e8bca4fa989e83', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75446647', 'ctest-vn4-68522350'], 'port_security_enabled': True, 'description': ''}} 2025-08-07 14:23:45,099 - DEBUG - Response for create_subnet : {'subnet': {'id': '06ffe77e-3127-4eed-823c-4f9f1ca3c432', 'name': '', 'tenant_id': '334bee4233504fccb2e8bca4fa989e83', 'network_id': '4fa21248-98c1-44cd-aa93-2409a5c51397', 'ip_version': 4, 'cidr': '63.148.99.128/26', 'allocation_pools': [{'start': '63.148.99.130', 'end': '63.148.99.190'}], 'gateway_ip': '63.148.99.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '63.148.99.130', 'tags': [], 'project_id': '334bee4233504fccb2e8bca4fa989e83'}} 2025-08-07 14:23:45,320 - DEBUG - Response for create_subnet : {'subnet': {'id': '019cc807-d25c-45df-85d2-6f5876aff649', 'name': '', 'tenant_id': '334bee4233504fccb2e8bca4fa989e83', 'network_id': '4fa21248-98c1-44cd-aa93-2409a5c51397', 'ip_version': 6, 'cidr': '3b24:5aff:54c9:1af5:7022:4fdd::/96', 'allocation_pools': [{'start': '3b24:5aff:54c9:1af5:7022:4fdd:0:2', 'end': '3b24:5aff:54c9:1af5:7022:4fdd:ffff:fffe'}], 'gateway_ip': '3b24:5aff:54c9:1af5:7022:4fdd:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3b24:5aff:54c9:1af5:7022:4fdd:0:2', 'tags': [], 'project_id': '334bee4233504fccb2e8bca4fa989e83'}} 2025-08-07 14:23:45,339 - INFO - Created VN ctest-vn4-68522350 2025-08-07 14:23:45,390 - DEBUG - VN ctest-vn4-68522350 UUID is 4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:45,612 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '4fa21248-98c1-44cd-aa93-2409a5c51397', 'name': 'ctest-vn4-68522350', 'tenant_id': '334bee4233504fccb2e8bca4fa989e83', 'project_id': '334bee4233504fccb2e8bca4fa989e83', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['06ffe77e-3127-4eed-823c-4f9f1ca3c432', '019cc807-d25c-45df-85d2-6f5876aff649'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75446647', 'ctest-vn4-68522350'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75446647', 'ctest-policy1-43566719']], 'subnet_ipam': [{'subnet_cidr': '63.148.99.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3b24:5aff:54c9:1af5:7022:4fdd::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-08-07 14:23:45,786 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-07 14:23:46,082 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-07 14:23:46,112 - DEBUG - Requesting: http://10.0.0.254:8082/domain/135ffd21-72fb-4f0d-9b21-1128999ff790 2025-08-07 14:23:46,127 - DEBUG - Requesting: http://10.0.0.254:8082/project/334bee42-3350-4fcc-b2e8-bca4fa989e83 2025-08-07 14:23:46,203 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,221 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,231 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:46,240 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:46,247 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/a8e1d14c-59fd-44e4-a19d-2ddd3886d3cb 2025-08-07 14:23:46,256 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-07 14:23:46,256 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,267 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:46,283 - INFO - Verified VN network id 9 for VN 4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,283 - INFO - Verifications in API Server for VN ctest-vn4-68522350 passed 2025-08-07 14:23:46,283 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,294 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:46,304 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:46,311 - DEBUG - Requesting: http://10.0.0.254:8082/route-target/a8e1d14c-59fd-44e4-a19d-2ddd3886d3cb 2025-08-07 14:23:46,324 - DEBUG - Control-node 10.0.0.254 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-75446647', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '5738168978233181389', 'uuid-lslong': '12291207431878677399'}, 'enable': 'true', 'created': '2025-08-07T14:23:44', 'last-modified': '2025-08-07T14:23:45', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.738185'} 2025-08-07 14:23:46,331 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-08-07 14:23:46,331 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-68522350 passed 2025-08-07 14:23:46,331 - DEBUG - ====Verifying policy data for ctest-vn4-68522350 in API_Server ====== 2025-08-07 14:23:46,331 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-07 14:23:46,337 - DEBUG - Requesting: http://10.0.0.254:8082/domain/135ffd21-72fb-4f0d-9b21-1128999ff790 2025-08-07 14:23:46,349 - DEBUG - Requesting: http://10.0.0.254:8082/project/334bee42-3350-4fcc-b2e8-bca4fa989e83 2025-08-07 14:23:46,425 - DEBUG - Requesting: http://10.0.0.254:8082/virtual-network/4fa21248-98c1-44cd-aa93-2409a5c51397 2025-08-07 14:23:46,435 - DEBUG - ==>Verifying data for policy with id: b04fee98-1498-416c-bae5-534e153d0f34, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-75446647', 'ctest-policy1-43566719'] 2025-08-07 14:23:46,435 - INFO - VN ctest-vn4-68522350 Policy verification: verify_vn_policy_in_api_server, status: True 2025-08-07 14:23:46,435 - DEBUG - Verifying the vn in opserver 2025-08-07 14:23:46,435 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350 virtual network link through opserver 10.0.0.254 2025-08-07 14:23:46,435 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-07 14:23:46,725 - DEBUG - Requesting: http://10.0.0.254:8081/analytics/uves/virtual-networks 2025-08-07 14:23:46,780 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350', 'href': 'http://10.0.0.254:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350?flat'} 2025-08-07 14:23:46,780 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-75446647:ctest-vn4-68522350 is found in opserver 2025-08-07 14:23:46,791 - DEBUG - Do not have enough data to verify VN in agent 2025-08-07 14:23:46,797 - DEBUG - VRF ids for VN ctest-vn4-68522350: {} 2025-08-07 14:23:46,797 - DEBUG - ====Verifying data for ctest-policy1-43566719 in API_Server ====== 2025-08-07 14:23:46,797 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-07 14:23:46,803 - DEBUG - Requesting: http://10.0.0.254:8082/domain/135ffd21-72fb-4f0d-9b21-1128999ff790 2025-08-07 14:23:46,814 - DEBUG - Requesting: http://10.0.0.254:8082/project/334bee42-3350-4fcc-b2e8-bca4fa989e83 2025-08-07 14:23:46,887 - DEBUG - Requesting: http://10.0.0.254:8082/network-policy/b04fee98-1498-416c-bae5-534e153d0f34 2025-08-07 14:23:46,898 - INFO - Verified policy ctest-policy1-43566719 in API Server, Result: True 2025-08-07 14:23:46,898 - INFO - Done with setup and verification, moving onto test .. 2025-08-07 14:23:46,925 - INFO - Deleting VN ctest-vn4-68522350 2025-08-07 14:23:47,062 - DEBUG - Response for deleting network () 2025-08-07 14:23:47,062 - DEBUG - Requesting: http://10.0.0.254:8082/routing-instance/487c5faf-f18c-41ac-908d-b4b08acd3930 2025-08-07 14:23:47,069 - DEBUG - Response Code: 404 2025-08-07 14:23:47,070 - DEBUG - Requesting: http://10.0.0.254:8082/domains 2025-08-07 14:23:47,075 - DEBUG - Requesting: http://10.0.0.254:8082/domain/135ffd21-72fb-4f0d-9b21-1128999ff790 2025-08-07 14:23:47,135 - DEBUG - Requesting: http://10.0.0.254:8082/project/334bee42-3350-4fcc-b2e8-bca4fa989e83 2025-08-07 14:23:47,208 - INFO - Validated that VN ctest-vn4-68522350 is not found in API Server 2025-08-07 14:23:47,221 - DEBUG - VN ctest-vn4-68522350 is not present in Agent 10.0.0.254 2025-08-07 14:23:47,222 - INFO - Validated that VN ctest-vn4-68522350 is not in any agent 2025-08-07 14:23:47,239 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-68522350 info 2025-08-07 14:23:47,263 - INFO - Deleted policy ctest-policy1-43566719 2025-08-07 14:23:47,438 - DEBUG - policy ctest-policy1-43566719 is not found in API Server 2025-08-07 14:23:47,695 - DEBUG - No XMPP flaps were noticed during the test 2025-08-07 14:23:47,695 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-07 14:23:47,695 - INFO - -------------------------------------------------------------------------------- 2025-08-07 14:23:47,984 - DEBUG - No XMPP flaps were noticed during the test 2025-08-07 14:23:47,984 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-08-07 14:23:47,984 - INFO - -------------------------------------------------------------------------------- 2025-08-07 14:23:48,646 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-75446647, ID : 334bee42-3350-4fcc-b2e8-bca4fa989e83