+ def verify_vpp(node):
+ """Verify that VPP is installed and started on the specified topology
+ node. Adjust privileges so user can connect without sudo.
+
+ :param node: Topology node.
+ :type node: dict
+ :raises RuntimeError: If VPP service fails to start.
+ """
+ DUTSetup.verify_program_installed(node, 'vpp')
+ try:
+ # Verify responsiveness of vppctl.
+ VPPUtil.verify_vpp_started(node)
+ # Adjust privileges.
+ VPPUtil.adjust_privileges(node)
+ # Verify responsiveness of PAPI.
+ VPPUtil.show_log(node)
+ VPPUtil.vpp_show_version(node)
+ finally:
+ DUTSetup.get_service_logs(node, Constants.VPP_UNIT)
+
+ @staticmethod
+ def verify_vpp_on_all_duts(nodes):
+ """Verify that VPP is installed and started on all DUT nodes.
+
+ :param nodes: Nodes in the topology.
+ :type nodes: dict
+ """
+ for node in nodes.values():
+ if node[u"type"] == NodeType.DUT:
+ VPPUtil.verify_vpp(node)
+
+ @staticmethod
+ def vpp_show_version(
+ node, remote_vpp_socket=Constants.SOCKSVR_PATH, log=True):
+ """Run "show_version" PAPI command.
+
+ Socket is configurable, so VPP inside container can be accessed.
+ The result is exported to JSON UTI output as "dut-version".