2025-09-21 12:49:14,834 - INFO - Domain Default found not creating 2025-09-21 12:49:14,966 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-11305679 not found, creating it 2025-09-21 12:49:15,395 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-11305679, ID : 7804ee9b-644a-4ea5-b5e0-6bd753d7fae6 2025-09-21 12:49:16,677 - INFO - ================================================================================ 2025-09-21 12:49:16,677 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-21 12:49:16,940 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2025-09-21 12:49:16,940 - INFO - Initial checks done. Running the testcase now 2025-09-21 12:49:16,940 - INFO - 2025-09-21 12:49:16,940 - INFO - ================================================================================ 2025-09-21 12:49:16,940 - INFO - STARTING TEST : test_remove_policy_with_ref 2025-09-21 12:49:16,940 - 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-09-21 12:49:17,241 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2025-09-21 12:49:17,241 - INFO - Initial checks done. Running the testcase now 2025-09-21 12:49:17,241 - INFO - 2025-09-21 12:49:17,579 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758, 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-11305679:ctest-vn4-34958758, 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-11305679:ctest-vn4-34958758, 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-11305679:ctest-vn4-34958758, 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-09-21 12:49:18,081 - DEBUG - Response for create_network : {'network': {'id': '95e6e1e9-d9da-41ea-bf14-c8643e1725f2', 'name': 'ctest-vn4-34958758', 'tenant_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'project_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-11305679', 'ctest-vn4-34958758'], 'port_security_enabled': True, 'description': ''}} 2025-09-21 12:49:18,254 - DEBUG - Response for create_subnet : {'subnet': {'id': '7ad80506-34dd-412d-84f2-88d9a359231e', 'name': '', 'tenant_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'network_id': '95e6e1e9-d9da-41ea-bf14-c8643e1725f2', 'ip_version': 4, 'cidr': '179.119.156.64/26', 'allocation_pools': [{'start': '179.119.156.66', 'end': '179.119.156.126'}], 'gateway_ip': '179.119.156.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '179.119.156.66', 'tags': [], 'project_id': '7804ee9b644a4ea5b5e06bd753d7fae6'}} 2025-09-21 12:49:18,440 - DEBUG - Response for create_subnet : {'subnet': {'id': 'e9bf872d-28cb-4590-8f20-dd751b5ac4e7', 'name': '', 'tenant_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'network_id': '95e6e1e9-d9da-41ea-bf14-c8643e1725f2', 'ip_version': 6, 'cidr': '2674:7b6d:4914:a07e:c8d4:572c::/96', 'allocation_pools': [{'start': '2674:7b6d:4914:a07e:c8d4:572c:0:2', 'end': '2674:7b6d:4914:a07e:c8d4:572c:ffff:fffe'}], 'gateway_ip': '2674:7b6d:4914:a07e:c8d4:572c:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '2674:7b6d:4914:a07e:c8d4:572c:0:2', 'tags': [], 'project_id': '7804ee9b644a4ea5b5e06bd753d7fae6'}} 2025-09-21 12:49:18,459 - INFO - Created VN ctest-vn4-34958758 2025-09-21 12:49:18,516 - DEBUG - VN ctest-vn4-34958758 UUID is 95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:18,718 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '95e6e1e9-d9da-41ea-bf14-c8643e1725f2', 'name': 'ctest-vn4-34958758', 'tenant_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'project_id': '7804ee9b644a4ea5b5e06bd753d7fae6', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['7ad80506-34dd-412d-84f2-88d9a359231e', 'e9bf872d-28cb-4590-8f20-dd751b5ac4e7'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-11305679', 'ctest-vn4-34958758'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-11305679', 'ctest-policy1-33306484']], 'subnet_ipam': [{'subnet_cidr': '179.119.156.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '2674:7b6d:4914:a07e:c8d4:572c::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2025-09-21 12:49:18,884 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-21 12:49:19,171 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-21 12:49:19,196 - DEBUG - Requesting: http://10.0.0.50:8082/domain/21b24c52-6d01-4772-aa3f-91d64eb69ab1 2025-09-21 12:49:19,207 - DEBUG - Requesting: http://10.0.0.50:8082/project/7804ee9b-644a-4ea5-b5e0-6bd753d7fae6 2025-09-21 12:49:19,271 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,281 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,289 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:19,294 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:19,298 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/a6a9eb02-912c-41b7-b902-5c026afcd1af 2025-09-21 12:49:19,303 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-21 12:49:19,303 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,311 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:19,324 - INFO - Verified VN network id 11 for VN 95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,324 - INFO - Verifications in API Server for VN ctest-vn4-34958758 passed 2025-09-21 12:49:19,324 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,332 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:19,337 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:19,342 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/a6a9eb02-912c-41b7-b902-5c026afcd1af 2025-09-21 12:49:19,351 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-11305679', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '10801569150793302506', 'uuid-lslong': '13768850293642438130'}, 'enable': 'true', 'created': '2025-09-21T12:49:18', 'last-modified': '2025-09-21T12:49:18', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.659535'} 2025-09-21 12:49:19,357 - DEBUG - Route Targets: ['target:64512:8000004'] 2025-09-21 12:49:19,357 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-34958758 passed 2025-09-21 12:49:19,357 - DEBUG - ====Verifying policy data for ctest-vn4-34958758 in API_Server ====== 2025-09-21 12:49:19,358 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-21 12:49:19,362 - DEBUG - Requesting: http://10.0.0.50:8082/domain/21b24c52-6d01-4772-aa3f-91d64eb69ab1 2025-09-21 12:49:19,371 - DEBUG - Requesting: http://10.0.0.50:8082/project/7804ee9b-644a-4ea5-b5e0-6bd753d7fae6 2025-09-21 12:49:19,440 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/95e6e1e9-d9da-41ea-bf14-c8643e1725f2 2025-09-21 12:49:19,448 - DEBUG - ==>Verifying data for policy with id: 09c02949-91c2-409f-8d6b-bcc5bd18cc0b, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-11305679', 'ctest-policy1-33306484'] 2025-09-21 12:49:19,449 - INFO - VN ctest-vn4-34958758 Policy verification: verify_vn_policy_in_api_server, status: True 2025-09-21 12:49:19,449 - DEBUG - Verifying the vn in opserver 2025-09-21 12:49:19,449 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758 virtual network link through opserver 10.0.0.50 2025-09-21 12:49:19,449 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-09-21 12:49:19,740 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2025-09-21 12:49:19,792 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758?flat'} 2025-09-21 12:49:19,792 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-11305679:ctest-vn4-34958758 is found in opserver 2025-09-21 12:49:19,800 - DEBUG - Do not have enough data to verify VN in agent 2025-09-21 12:49:19,804 - DEBUG - VRF ids for VN ctest-vn4-34958758: {} 2025-09-21 12:49:19,804 - DEBUG - ====Verifying data for ctest-policy1-33306484 in API_Server ====== 2025-09-21 12:49:19,804 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-21 12:49:19,809 - DEBUG - Requesting: http://10.0.0.50:8082/domain/21b24c52-6d01-4772-aa3f-91d64eb69ab1 2025-09-21 12:49:19,818 - DEBUG - Requesting: http://10.0.0.50:8082/project/7804ee9b-644a-4ea5-b5e0-6bd753d7fae6 2025-09-21 12:49:19,885 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/09c02949-91c2-409f-8d6b-bcc5bd18cc0b 2025-09-21 12:49:19,893 - INFO - Verified policy ctest-policy1-33306484 in API Server, Result: True 2025-09-21 12:49:19,893 - INFO - Done with setup and verification, moving onto test .. 2025-09-21 12:49:19,901 - INFO - Deleting VN ctest-vn4-34958758 2025-09-21 12:49:20,006 - DEBUG - Response for deleting network () 2025-09-21 12:49:20,006 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/e8567f55-d458-4211-95cc-2fbfade1a9d8 2025-09-21 12:49:20,011 - DEBUG - Response Code: 404 2025-09-21 12:49:20,011 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2025-09-21 12:49:20,017 - DEBUG - Requesting: http://10.0.0.50:8082/domain/21b24c52-6d01-4772-aa3f-91d64eb69ab1 2025-09-21 12:49:20,068 - DEBUG - Requesting: http://10.0.0.50:8082/project/7804ee9b-644a-4ea5-b5e0-6bd753d7fae6 2025-09-21 12:49:20,187 - INFO - Validated that VN ctest-vn4-34958758 is not found in API Server 2025-09-21 12:49:20,195 - DEBUG - VN ctest-vn4-34958758 is not present in Agent 10.0.0.50 2025-09-21 12:49:20,195 - INFO - Validated that VN ctest-vn4-34958758 is not in any agent 2025-09-21 12:49:20,206 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-34958758 info 2025-09-21 12:49:20,228 - INFO - Deleted policy ctest-policy1-33306484 2025-09-21 12:49:20,388 - DEBUG - policy ctest-policy1-33306484 is not found in API Server 2025-09-21 12:49:20,644 - DEBUG - No XMPP flaps were noticed during the test 2025-09-21 12:49:20,645 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-09-21 12:49:20,645 - INFO - -------------------------------------------------------------------------------- 2025-09-21 12:49:20,940 - DEBUG - No XMPP flaps were noticed during the test 2025-09-21 12:49:20,941 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04] 2025-09-21 12:49:20,941 - INFO - -------------------------------------------------------------------------------- 2025-09-21 12:49:21,590 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-11305679, ID : 7804ee9b-644a-4ea5-b5e0-6bd753d7fae6