2025-07-22 17:42:28,377 - INFO - Domain Default found not creating 2025-07-22 17:42:28,518 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-82615195 not found, creating it 2025-07-22 17:42:28,947 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-82615195, ID : 75252acd-2c41-47e9-932b-bc533ede20aa 2025-07-22 17:42:30,336 - INFO - ================================================================================ 2025-07-22 17:42:30,336 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-07-22 17:42:30,591 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.129': '0'}} with 2025-07-22 17:42:30,591 - INFO - Initial checks done. Running the testcase now 2025-07-22 17:42:30,591 - INFO - 2025-07-22 17:42:30,591 - INFO - ================================================================================ 2025-07-22 17:42:30,591 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-07-22 17:42:30,591 - 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-07-22 17:42:30,891 - DEBUG - Nothing to compare xmpp stats {'10.0.0.48': {'10.20.0.129': '0'}} with 2025-07-22 17:42:30,891 - INFO - Initial checks done. Running the testcase now 2025-07-22 17:42:30,891 - INFO - 2025-07-22 17:42:31,237 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594, 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-82615195:ctest-vn4-85807594, 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-82615195:ctest-vn4-85807594, 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-82615195:ctest-vn4-85807594, 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-07-22 17:42:31,771 - DEBUG - Response for create_network : {'network': {'id': '223f8706-3e5c-414b-828e-83b9e2b7169f', 'name': 'ctest-vn4-85807594', 'tenant_id': '75252acd2c4147e9932bbc533ede20aa', 'project_id': '75252acd2c4147e9932bbc533ede20aa', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-82615195', 'ctest-vn4-85807594'], 'port_security_enabled': True, 'description': ''}} 2025-07-22 17:42:31,947 - DEBUG - Response for create_subnet : {'subnet': {'id': '15e8c078-4405-46f7-855b-76fe2489b819', 'name': '', 'tenant_id': '75252acd2c4147e9932bbc533ede20aa', 'network_id': '223f8706-3e5c-414b-828e-83b9e2b7169f', 'ip_version': 4, 'cidr': '164.253.242.128/26', 'allocation_pools': [{'start': '164.253.242.130', 'end': '164.253.242.190'}], 'gateway_ip': '164.253.242.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '164.253.242.130', 'tags': [], 'project_id': '75252acd2c4147e9932bbc533ede20aa'}} 2025-07-22 17:42:32,111 - DEBUG - Response for create_subnet : {'subnet': {'id': 'cc2d9173-31d8-4655-9b81-e1c5c34a1711', 'name': '', 'tenant_id': '75252acd2c4147e9932bbc533ede20aa', 'network_id': '223f8706-3e5c-414b-828e-83b9e2b7169f', 'ip_version': 6, 'cidr': '22a1:7704:386:e030:fe3c:b5b2::/96', 'allocation_pools': [{'start': '22a1:7704:386:e030:fe3c:b5b2:0:2', 'end': '22a1:7704:386:e030:fe3c:b5b2:ffff:fffe'}], 'gateway_ip': '22a1:7704:386:e030:fe3c:b5b2:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '22a1:7704:386:e030:fe3c:b5b2:0:2', 'tags': [], 'project_id': '75252acd2c4147e9932bbc533ede20aa'}} 2025-07-22 17:42:32,130 - INFO - Created VN ctest-vn4-85807594 2025-07-22 17:42:32,181 - DEBUG - VN ctest-vn4-85807594 UUID is 223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:32,374 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '223f8706-3e5c-414b-828e-83b9e2b7169f', 'name': 'ctest-vn4-85807594', 'tenant_id': '75252acd2c4147e9932bbc533ede20aa', 'project_id': '75252acd2c4147e9932bbc533ede20aa', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['15e8c078-4405-46f7-855b-76fe2489b819', 'cc2d9173-31d8-4655-9b81-e1c5c34a1711'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-82615195', 'ctest-vn4-85807594'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-82615195', 'ctest-policy1-90606902']], 'subnet_ipam': [{'subnet_cidr': '164.253.242.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '22a1:7704:386:e030:fe3c:b5b2::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-07-22 17:42:32,529 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-07-22 17:42:32,819 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-07-22 17:42:32,848 - DEBUG - Requesting: http://10.0.0.48:8082/domain/dca9e7f9-668a-4c12-a926-5a40e1c29885 2025-07-22 17:42:32,865 - DEBUG - Requesting: http://10.0.0.48:8082/project/75252acd-2c41-47e9-932b-bc533ede20aa 2025-07-22 17:42:32,935 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:32,948 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:32,960 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:32,968 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:32,976 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/9a72cc63-2614-429a-a223-04c2940528f0 2025-07-22 17:42:32,983 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-07-22 17:42:32,983 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:32,994 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:33,010 - INFO - Verified VN network id 12 for VN 223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:33,010 - INFO - Verifications in API Server for VN ctest-vn4-85807594 passed 2025-07-22 17:42:33,010 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:33,023 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:33,031 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:33,038 - DEBUG - Requesting: http://10.0.0.48:8082/route-target/9a72cc63-2614-429a-a223-04c2940528f0 2025-07-22 17:42:33,050 - DEBUG - Control-node 10.0.0.48 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-82615195', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '2467839581708108107', 'uuid-lslong': '9407601506019382943'}, 'enable': 'true', 'created': '2025-07-22T17:42:31', 'last-modified': '2025-07-22T17:42:32', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.702343'} 2025-07-22 17:42:33,056 - DEBUG - Route Targets: ['target:64512:8000005'] 2025-07-22 17:42:33,056 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-85807594 passed 2025-07-22 17:42:33,056 - DEBUG - ====Verifying policy data for ctest-vn4-85807594 in API_Server ====== 2025-07-22 17:42:33,056 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-07-22 17:42:33,062 - DEBUG - Requesting: http://10.0.0.48:8082/domain/dca9e7f9-668a-4c12-a926-5a40e1c29885 2025-07-22 17:42:33,074 - DEBUG - Requesting: http://10.0.0.48:8082/project/75252acd-2c41-47e9-932b-bc533ede20aa 2025-07-22 17:42:33,148 - DEBUG - Requesting: http://10.0.0.48:8082/virtual-network/223f8706-3e5c-414b-828e-83b9e2b7169f 2025-07-22 17:42:33,160 - DEBUG - ==>Verifying data for policy with id: 96c10a01-f6f1-420e-9dbf-e95e66c91bfc, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-82615195', 'ctest-policy1-90606902'] 2025-07-22 17:42:33,160 - INFO - VN ctest-vn4-85807594 Policy verification: verify_vn_policy_in_api_server, status: True 2025-07-22 17:42:33,160 - DEBUG - Verifying the vn in opserver 2025-07-22 17:42:33,160 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594 virtual network link through opserver 10.0.0.48 2025-07-22 17:42:33,160 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-07-22 17:42:33,450 - DEBUG - Requesting: http://10.0.0.48:8081/analytics/uves/virtual-networks 2025-07-22 17:42:33,501 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594', 'href': 'http://10.0.0.48:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594?flat'} 2025-07-22 17:42:33,501 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-82615195:ctest-vn4-85807594 is found in opserver 2025-07-22 17:42:33,512 - DEBUG - Do not have enough data to verify VN in agent 2025-07-22 17:42:33,517 - DEBUG - VRF ids for VN ctest-vn4-85807594: {} 2025-07-22 17:42:33,517 - DEBUG - ====Verifying data for ctest-policy1-90606902 in API_Server ====== 2025-07-22 17:42:33,517 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-07-22 17:42:33,523 - DEBUG - Requesting: http://10.0.0.48:8082/domain/dca9e7f9-668a-4c12-a926-5a40e1c29885 2025-07-22 17:42:33,534 - DEBUG - Requesting: http://10.0.0.48:8082/project/75252acd-2c41-47e9-932b-bc533ede20aa 2025-07-22 17:42:33,606 - DEBUG - Requesting: http://10.0.0.48:8082/network-policy/96c10a01-f6f1-420e-9dbf-e95e66c91bfc 2025-07-22 17:42:33,616 - INFO - Verified policy ctest-policy1-90606902 in API Server, Result: True 2025-07-22 17:42:33,616 - INFO - Done with setup and verification, moving onto test .. 2025-07-22 17:42:33,623 - INFO - Deleting VN ctest-vn4-85807594 2025-07-22 17:42:33,739 - DEBUG - Response for deleting network () 2025-07-22 17:42:33,739 - DEBUG - Requesting: http://10.0.0.48:8082/routing-instance/075bfa7e-c471-45e5-9e39-1aa3531af4f8 2025-07-22 17:42:33,744 - DEBUG - Response Code: 404 2025-07-22 17:42:33,744 - DEBUG - Requesting: http://10.0.0.48:8082/domains 2025-07-22 17:42:33,749 - DEBUG - Requesting: http://10.0.0.48:8082/domain/dca9e7f9-668a-4c12-a926-5a40e1c29885 2025-07-22 17:42:33,802 - DEBUG - Requesting: http://10.0.0.48:8082/project/75252acd-2c41-47e9-932b-bc533ede20aa 2025-07-22 17:42:33,873 - INFO - Validated that VN ctest-vn4-85807594 is not found in API Server 2025-07-22 17:42:33,884 - DEBUG - VN ctest-vn4-85807594 is not present in Agent 10.0.0.48 2025-07-22 17:42:33,884 - INFO - Validated that VN ctest-vn4-85807594 is not in any agent 2025-07-22 17:42:33,897 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-85807594 info 2025-07-22 17:42:33,929 - INFO - Deleted policy ctest-policy1-90606902 2025-07-22 17:42:34,093 - DEBUG - policy ctest-policy1-90606902 is not found in API Server 2025-07-22 17:42:34,350 - DEBUG - No XMPP flaps were noticed during the test 2025-07-22 17:42:34,350 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-07-22 17:42:34,351 - INFO - -------------------------------------------------------------------------------- 2025-07-22 17:42:34,642 - DEBUG - No XMPP flaps were noticed during the test 2025-07-22 17:42:34,642 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-07-22 17:42:34,642 - INFO - -------------------------------------------------------------------------------- 2025-07-22 17:42:35,299 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-82615195, ID : 75252acd-2c41-47e9-932b-bc533ede20aa