2025-11-04 17:09:01,207 - INFO - Domain Default found not creating 2025-11-04 17:09:01,360 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-34906445 not found, creating it 2025-11-04 17:09:01,837 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-34906445, ID : 78a5f606-09e0-47ca-9186-40245e8eb266 2025-11-04 17:09:03,318 - INFO - ================================================================================ 2025-11-04 17:09:03,318 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-04 17:09:03,571 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.254': '0'}} with 2025-11-04 17:09:03,571 - INFO - Initial checks done. Running the testcase now 2025-11-04 17:09:03,571 - INFO - 2025-11-04 17:09:03,571 - INFO - ================================================================================ 2025-11-04 17:09:03,571 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-04 17:09:03,571 - 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-04 17:09:03,866 - DEBUG - Nothing to compare xmpp stats {'10.0.0.22': {'10.20.0.254': '0'}} with 2025-11-04 17:09:03,866 - INFO - Initial checks done. Running the testcase now 2025-11-04 17:09:03,866 - INFO - 2025-11-04 17:09:04,231 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147, 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-34906445:ctest-vn4-12624147, 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-34906445:ctest-vn4-12624147, 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-34906445:ctest-vn4-12624147, 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-04 17:09:04,721 - DEBUG - Response for create_network : {'network': {'id': '2b0f83aa-7550-45cb-8ce5-98ddb81b2c20', 'name': 'ctest-vn4-12624147', 'tenant_id': '78a5f60609e047ca918640245e8eb266', 'project_id': '78a5f60609e047ca918640245e8eb266', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-34906445', 'ctest-vn4-12624147'], 'port_security_enabled': True, 'description': ''}} 2025-11-04 17:09:04,926 - DEBUG - Response for create_subnet : {'subnet': {'id': '2fa53794-91fc-41df-9ef4-ba46b4eba8e9', 'name': '', 'tenant_id': '78a5f60609e047ca918640245e8eb266', 'network_id': '2b0f83aa-7550-45cb-8ce5-98ddb81b2c20', 'ip_version': 4, 'cidr': '42.62.206.64/26', 'allocation_pools': [{'start': '42.62.206.66', 'end': '42.62.206.126'}], 'gateway_ip': '42.62.206.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '42.62.206.66', 'tags': [], 'project_id': '78a5f60609e047ca918640245e8eb266'}} 2025-11-04 17:09:05,123 - DEBUG - Response for create_subnet : {'subnet': {'id': '74544347-91bf-4bcd-aded-35c8a3699a57', 'name': '', 'tenant_id': '78a5f60609e047ca918640245e8eb266', 'network_id': '2b0f83aa-7550-45cb-8ce5-98ddb81b2c20', 'ip_version': 6, 'cidr': '3225:91ea:beab:feee:5e00:1976::/96', 'allocation_pools': [{'start': '3225:91ea:beab:feee:5e00:1976:0:2', 'end': '3225:91ea:beab:feee:5e00:1976:ffff:fffe'}], 'gateway_ip': '3225:91ea:beab:feee:5e00:1976:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3225:91ea:beab:feee:5e00:1976:0:2', 'tags': [], 'project_id': '78a5f60609e047ca918640245e8eb266'}} 2025-11-04 17:09:05,139 - INFO - Created VN ctest-vn4-12624147 2025-11-04 17:09:05,189 - DEBUG - VN ctest-vn4-12624147 UUID is 2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:05,380 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '2b0f83aa-7550-45cb-8ce5-98ddb81b2c20', 'name': 'ctest-vn4-12624147', 'tenant_id': '78a5f60609e047ca918640245e8eb266', 'project_id': '78a5f60609e047ca918640245e8eb266', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['2fa53794-91fc-41df-9ef4-ba46b4eba8e9', '74544347-91bf-4bcd-aded-35c8a3699a57'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-34906445', 'ctest-vn4-12624147'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-34906445', 'ctest-policy1-16353730']], 'subnet_ipam': [{'subnet_cidr': '42.62.206.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3225:91ea:beab:feee:5e00:1976::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-04 17:09:05,541 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-04 17:09:05,857 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-04 17:09:05,880 - DEBUG - Requesting: http://10.0.0.22:8082/domain/7bd482da-67f0-4209-9057-9d2ffb000f9b 2025-11-04 17:09:05,890 - DEBUG - Requesting: http://10.0.0.22:8082/project/78a5f606-09e0-47ca-9186-40245e8eb266 2025-11-04 17:09:05,957 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:05,967 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:05,976 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:05,983 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:05,989 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/0d748a5c-bd89-436c-a7b4-0d70117fe05b 2025-11-04 17:09:05,995 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-04 17:09:05,995 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:06,004 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:06,018 - INFO - Verified VN network id 11 for VN 2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:06,018 - INFO - Verifications in API Server for VN ctest-vn4-12624147 passed 2025-11-04 17:09:06,018 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:06,028 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:06,035 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:06,040 - DEBUG - Requesting: http://10.0.0.22:8082/route-target/0d748a5c-bd89-436c-a7b4-0d70117fe05b 2025-11-04 17:09:06,050 - DEBUG - Control-node 10.0.0.22 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-34906445', 'owner-access': '7', 'group': 'manager', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '3102843436417435083', 'uuid-lslong': '10152689013020634144'}, 'enable': 'true', 'created': '2025-11-04T17:09:04', 'last-modified': '2025-11-04T17:09:05', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.705779'} 2025-11-04 17:09:06,054 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-04 17:09:06,055 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-12624147 passed 2025-11-04 17:09:06,055 - DEBUG - ====Verifying policy data for ctest-vn4-12624147 in API_Server ====== 2025-11-04 17:09:06,055 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-04 17:09:06,059 - DEBUG - Requesting: http://10.0.0.22:8082/domain/7bd482da-67f0-4209-9057-9d2ffb000f9b 2025-11-04 17:09:06,068 - DEBUG - Requesting: http://10.0.0.22:8082/project/78a5f606-09e0-47ca-9186-40245e8eb266 2025-11-04 17:09:06,136 - DEBUG - Requesting: http://10.0.0.22:8082/virtual-network/2b0f83aa-7550-45cb-8ce5-98ddb81b2c20 2025-11-04 17:09:06,154 - DEBUG - ==>Verifying data for policy with id: 6c97f4dc-666d-4ec9-98a0-850226c64011, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-34906445', 'ctest-policy1-16353730'] 2025-11-04 17:09:06,154 - INFO - VN ctest-vn4-12624147 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-04 17:09:06,154 - DEBUG - Verifying the vn in opserver 2025-11-04 17:09:06,154 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147 virtual network link through opserver 10.0.0.22 2025-11-04 17:09:06,154 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-11-04 17:09:06,468 - DEBUG - Requesting: http://10.0.0.22:8081/analytics/uves/virtual-networks 2025-11-04 17:09:06,517 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147', 'href': 'http://10.0.0.22:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147?flat'} 2025-11-04 17:09:06,517 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-34906445:ctest-vn4-12624147 is found in opserver 2025-11-04 17:09:06,526 - DEBUG - Do not have enough data to verify VN in agent 2025-11-04 17:09:06,530 - DEBUG - VRF ids for VN ctest-vn4-12624147: {} 2025-11-04 17:09:06,530 - DEBUG - ====Verifying data for ctest-policy1-16353730 in API_Server ====== 2025-11-04 17:09:06,530 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-04 17:09:06,535 - DEBUG - Requesting: http://10.0.0.22:8082/domain/7bd482da-67f0-4209-9057-9d2ffb000f9b 2025-11-04 17:09:06,544 - DEBUG - Requesting: http://10.0.0.22:8082/project/78a5f606-09e0-47ca-9186-40245e8eb266 2025-11-04 17:09:06,612 - DEBUG - Requesting: http://10.0.0.22:8082/network-policy/6c97f4dc-666d-4ec9-98a0-850226c64011 2025-11-04 17:09:06,621 - INFO - Verified policy ctest-policy1-16353730 in API Server, Result: True 2025-11-04 17:09:06,621 - INFO - Done with setup and verification, moving onto test .. 2025-11-04 17:09:06,629 - INFO - Deleting VN ctest-vn4-12624147 2025-11-04 17:09:06,809 - DEBUG - Response for deleting network () 2025-11-04 17:09:06,809 - DEBUG - Requesting: http://10.0.0.22:8082/routing-instance/1e8e2d87-b5ba-4340-8009-ad194310de63 2025-11-04 17:09:06,815 - DEBUG - Response Code: 404 2025-11-04 17:09:06,815 - DEBUG - Requesting: http://10.0.0.22:8082/domains 2025-11-04 17:09:06,820 - DEBUG - Requesting: http://10.0.0.22:8082/domain/7bd482da-67f0-4209-9057-9d2ffb000f9b 2025-11-04 17:09:06,874 - DEBUG - Requesting: http://10.0.0.22:8082/project/78a5f606-09e0-47ca-9186-40245e8eb266 2025-11-04 17:09:06,942 - INFO - Validated that VN ctest-vn4-12624147 is not found in API Server 2025-11-04 17:09:06,950 - DEBUG - VN ctest-vn4-12624147 is not present in Agent 10.0.0.22 2025-11-04 17:09:06,950 - INFO - Validated that VN ctest-vn4-12624147 is not in any agent 2025-11-04 17:09:06,963 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-12624147 info 2025-11-04 17:09:06,986 - INFO - Deleted policy ctest-policy1-16353730 2025-11-04 17:09:07,153 - DEBUG - policy ctest-policy1-16353730 is not found in API Server 2025-11-04 17:09:07,406 - DEBUG - No XMPP flaps were noticed during the test
2025-11-04 17:09:07,406 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-11-04 17:09:07,407 - INFO - -------------------------------------------------------------------------------- 2025-11-04 17:09:07,698 - DEBUG - No XMPP flaps were noticed during the test
2025-11-04 17:09:07,698 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2025-11-04 17:09:07,698 - INFO - -------------------------------------------------------------------------------- 2025-11-04 17:09:08,371 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-34906445, ID : 78a5f606-09e0-47ca-9186-40245e8eb266