2025-11-15 20:29:43,858 - INFO - Domain Default found not creating 2025-11-15 20:29:44,010 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-55867658 not found, creating it 2025-11-15 20:29:44,457 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-55867658, ID : 769e0870-39bb-4e6a-9db3-027d9d8dd86f 2025-11-15 20:29:45,894 - INFO - ================================================================================ 2025-11-15 20:29:45,894 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-15 20:29:46,146 - DEBUG - Nothing to compare xmpp stats {'10.0.0.33': {'10.20.0.17': '0'}} with 2025-11-15 20:29:46,146 - INFO - Initial checks done. Running the testcase now 2025-11-15 20:29:46,146 - INFO - 2025-11-15 20:29:46,146 - INFO - ================================================================================ 2025-11-15 20:29:46,146 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-11-15 20:29:46,146 - 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-15 20:29:46,437 - DEBUG - Nothing to compare xmpp stats {'10.0.0.33': {'10.20.0.17': '0'}} with 2025-11-15 20:29:46,437 - INFO - Initial checks done. Running the testcase now 2025-11-15 20:29:46,437 - INFO - 2025-11-15 20:29:46,782 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985, 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-55867658:ctest-vn4-05787985, 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-55867658:ctest-vn4-05787985, 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-55867658:ctest-vn4-05787985, 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-15 20:29:47,279 - DEBUG - Response for create_network : {'network': {'id': 'c83cb232-7725-46c9-b9f3-c731872ddaee', 'name': 'ctest-vn4-05787985', 'tenant_id': '769e087039bb4e6a9db3027d9d8dd86f', 'project_id': '769e087039bb4e6a9db3027d9d8dd86f', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-55867658', 'ctest-vn4-05787985'], 'port_security_enabled': True, 'description': ''}} 2025-11-15 20:29:47,425 - DEBUG - Response for create_subnet : {'subnet': {'id': 'fd18b7b8-cf01-4dde-b90a-b4f74149eeb9', 'name': '', 'tenant_id': '769e087039bb4e6a9db3027d9d8dd86f', 'network_id': 'c83cb232-7725-46c9-b9f3-c731872ddaee', 'ip_version': 4, 'cidr': '131.208.126.0/26', 'allocation_pools': [{'start': '131.208.126.2', 'end': '131.208.126.62'}], 'gateway_ip': '131.208.126.1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '131.208.126.2', 'tags': [], 'project_id': '769e087039bb4e6a9db3027d9d8dd86f'}} 2025-11-15 20:29:47,595 - DEBUG - Response for create_subnet : {'subnet': {'id': 'd7e98af9-d92a-4c51-bb6f-e96f8dd942a1', 'name': '', 'tenant_id': '769e087039bb4e6a9db3027d9d8dd86f', 'network_id': 'c83cb232-7725-46c9-b9f3-c731872ddaee', 'ip_version': 6, 'cidr': '389a:89a:daf:c66f:bb2d:c1ac::/96', 'allocation_pools': [{'start': '389a:89a:daf:c66f:bb2d:c1ac:0:2', 'end': '389a:89a:daf:c66f:bb2d:c1ac:ffff:fffe'}], 'gateway_ip': '389a:89a:daf:c66f:bb2d:c1ac:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '389a:89a:daf:c66f:bb2d:c1ac:0:2', 'tags': [], 'project_id': '769e087039bb4e6a9db3027d9d8dd86f'}} 2025-11-15 20:29:47,612 - INFO - Created VN ctest-vn4-05787985 2025-11-15 20:29:47,665 - DEBUG - VN ctest-vn4-05787985 UUID is c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:47,862 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'c83cb232-7725-46c9-b9f3-c731872ddaee', 'name': 'ctest-vn4-05787985', 'tenant_id': '769e087039bb4e6a9db3027d9d8dd86f', 'project_id': '769e087039bb4e6a9db3027d9d8dd86f', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['fd18b7b8-cf01-4dde-b90a-b4f74149eeb9', 'd7e98af9-d92a-4c51-bb6f-e96f8dd942a1'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-55867658', 'ctest-vn4-05787985'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-55867658', 'ctest-policy1-34066266']], 'subnet_ipam': [{'subnet_cidr': '131.208.126.0/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '389a:89a:daf:c66f:bb2d:c1ac::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-11-15 20:29:48,037 - DEBUG - Requesting: http://10.0.0.33:8082/domains 2025-11-15 20:29:48,330 - DEBUG - Requesting: http://10.0.0.33:8082/domains 2025-11-15 20:29:48,361 - DEBUG - Requesting: http://10.0.0.33:8082/domain/c41869b6-8444-4061-a790-0bb702330aad 2025-11-15 20:29:48,374 - DEBUG - Requesting: http://10.0.0.33:8082/project/769e0870-39bb-4e6a-9db3-027d9d8dd86f 2025-11-15 20:29:48,442 - DEBUG - Requesting: http://10.0.0.33:8082/virtual-network/c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,453 - DEBUG - Requesting: http://10.0.0.33:8082/virtual-network/c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,462 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:48,468 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:48,474 - DEBUG - Requesting: http://10.0.0.33:8082/route-target/1a1c380a-3bea-4a51-9643-84929d612449 2025-11-15 20:29:48,479 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-15 20:29:48,479 - DEBUG - Requesting: http://10.0.0.33:8082/virtual-network/c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,487 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:48,552 - INFO - Verified VN network id 12 for VN c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,552 - INFO - Verifications in API Server for VN ctest-vn4-05787985 passed 2025-11-15 20:29:48,552 - DEBUG - Requesting: http://10.0.0.33:8082/virtual-network/c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,561 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:48,567 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:48,572 - DEBUG - Requesting: http://10.0.0.33:8082/route-target/1a1c380a-3bea-4a51-9643-84929d612449 2025-11-15 20:29:48,583 - DEBUG - Control-node 10.0.0.33 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-55867658', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '14428603236005267145', 'uuid-lslong': '13399272331892611822'}, 'enable': 'true', 'created': '2025-11-15T20:29:47', 'last-modified': '2025-11-15T20:29:47', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.747163'} 2025-11-15 20:29:48,589 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-11-15 20:29:48,589 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-05787985 passed 2025-11-15 20:29:48,589 - DEBUG - ====Verifying policy data for ctest-vn4-05787985 in API_Server ====== 2025-11-15 20:29:48,589 - DEBUG - Requesting: http://10.0.0.33:8082/domains 2025-11-15 20:29:48,593 - DEBUG - Requesting: http://10.0.0.33:8082/domain/c41869b6-8444-4061-a790-0bb702330aad 2025-11-15 20:29:48,602 - DEBUG - Requesting: http://10.0.0.33:8082/project/769e0870-39bb-4e6a-9db3-027d9d8dd86f 2025-11-15 20:29:48,675 - DEBUG - Requesting: http://10.0.0.33:8082/virtual-network/c83cb232-7725-46c9-b9f3-c731872ddaee 2025-11-15 20:29:48,683 - DEBUG - ==>Verifying data for policy with id: c9b4bb2f-52da-4286-999e-1b95b4de409f, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-55867658', 'ctest-policy1-34066266'] 2025-11-15 20:29:48,683 - INFO - VN ctest-vn4-05787985 Policy verification: verify_vn_policy_in_api_server, status: True 2025-11-15 20:29:48,683 - DEBUG - Verifying the vn in opserver 2025-11-15 20:29:48,683 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985 virtual network link through opserver 10.0.0.33 2025-11-15 20:29:48,684 - DEBUG - Requesting: http://10.0.0.33:8081/analytics/uves/virtual-networks 2025-11-15 20:29:48,973 - DEBUG - Requesting: http://10.0.0.33:8081/analytics/uves/virtual-networks 2025-11-15 20:29:49,029 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985', 'href': 'http://10.0.0.33:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985?flat'} 2025-11-15 20:29:49,029 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-55867658:ctest-vn4-05787985 is found in opserver 2025-11-15 20:29:49,037 - DEBUG - Do not have enough data to verify VN in agent 2025-11-15 20:29:49,041 - DEBUG - VRF ids for VN ctest-vn4-05787985: {} 2025-11-15 20:29:49,041 - DEBUG - ====Verifying data for ctest-policy1-34066266 in API_Server ====== 2025-11-15 20:29:49,041 - DEBUG - Requesting: http://10.0.0.33:8082/domains 2025-11-15 20:29:49,047 - DEBUG - Requesting: http://10.0.0.33:8082/domain/c41869b6-8444-4061-a790-0bb702330aad 2025-11-15 20:29:49,056 - DEBUG - Requesting: http://10.0.0.33:8082/project/769e0870-39bb-4e6a-9db3-027d9d8dd86f 2025-11-15 20:29:49,122 - DEBUG - Requesting: http://10.0.0.33:8082/network-policy/c9b4bb2f-52da-4286-999e-1b95b4de409f 2025-11-15 20:29:49,133 - INFO - Verified policy ctest-policy1-34066266 in API Server, Result: True 2025-11-15 20:29:49,133 - INFO - Done with setup and verification, moving onto test .. 2025-11-15 20:29:49,139 - INFO - Deleting VN ctest-vn4-05787985 2025-11-15 20:29:49,237 - DEBUG - Response for deleting network () 2025-11-15 20:29:49,237 - DEBUG - Requesting: http://10.0.0.33:8082/routing-instance/ac2b9692-57a4-4876-bf07-d7105eb2badb 2025-11-15 20:29:49,241 - DEBUG - Response Code: 404 2025-11-15 20:29:49,241 - DEBUG - Requesting: http://10.0.0.33:8082/domains 2025-11-15 20:29:49,246 - DEBUG - Requesting: http://10.0.0.33:8082/domain/c41869b6-8444-4061-a790-0bb702330aad 2025-11-15 20:29:49,297 - DEBUG - Requesting: http://10.0.0.33:8082/project/769e0870-39bb-4e6a-9db3-027d9d8dd86f 2025-11-15 20:29:49,367 - INFO - Validated that VN ctest-vn4-05787985 is not found in API Server 2025-11-15 20:29:49,376 - DEBUG - VN ctest-vn4-05787985 is not present in Agent 10.0.0.33 2025-11-15 20:29:49,376 - INFO - Validated that VN ctest-vn4-05787985 is not in any agent 2025-11-15 20:29:49,389 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-05787985 info 2025-11-15 20:29:49,415 - INFO - Deleted policy ctest-policy1-34066266 2025-11-15 20:29:49,577 - DEBUG - policy ctest-policy1-34066266 is not found in API Server 2025-11-15 20:29:49,829 - DEBUG - No XMPP flaps were noticed during the test