ray.util.state.list_logs#

ray.util.state.list_logs(address: str | None = None, node_id: str | None = None, node_ip: str | None = None, glob_filter: str | None = None, timeout: int = 30) Dict[str, List[str]][source]#

Listing log files available.

Parameters:
  • address – Ray bootstrap address, could be auto, localhost:6379. If not specified, it will be retrieved from the initialized ray cluster.

  • node_id – Id of the node containing the logs.

  • node_ip – Ip of the node containing the logs.

  • glob_filter – Name of the file (relative to the ray log directory) to be retrieved. E.g. glob_filter="*worker*" for all worker logs.

  • actor_id – Id of the actor if getting logs from an actor.

  • timeout – Max timeout for requests made when getting the logs.

  • _interval – The interval in secs to print new logs when follow=True.

Returns:

A dictionary where the keys are log groups (e.g. gcs, raylet, worker), and values are list of log filenames.

Raises:

ExceptionsRayStateApiException if the CLI failed to query the data, or ConnectionError if failed to resolve the ray address.

DeveloperAPI: This API may change across minor Ray releases.