Ray dashboard won't start

Ray dashboard won’t start

ray start --head --port=6379 --include-dashboard=true --dashboard-host=0.0.0.0 --dashboard-port=8265

Usage stats collection is enabled. To disable this, add --disable-usage-stats to the command that starts the cluster, or run the following command: ray disable-usage-stats before starting the cluster. See Usage Stats Collection — Ray 3.0.0.dev0 for more details.

Local node IP: 192.168.22.151
Traceback (most recent call last):
File “/usr/local/bin/ray”, line 8, in
sys.exit(main())
File “/usr/local/lib/python3.8/dist-packages/ray/scripts/scripts.py”, line 2610, in main
return cli()
File “/usr/lib/python3/dist-packages/click/core.py”, line 764, in call
return self.main(*args, **kwargs)
File “/usr/lib/python3/dist-packages/click/core.py”, line 717, in main
rv = self.invoke(ctx)
File “/usr/lib/python3/dist-packages/click/core.py”, line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/lib/python3/dist-packages/click/core.py”, line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/usr/lib/python3/dist-packages/click/core.py”, line 555, in invoke
return callback(*args, **kwargs)
File “/usr/local/lib/python3.8/dist-packages/ray/autoscaler/_private/cli_logger.py”, line 856, in wrapper
return f(*args, **kwargs)
File “/usr/local/lib/python3.8/dist-packages/ray/scripts/scripts.py”, line 790, in start
node = ray._private.node.Node(
File “/usr/local/lib/python3.8/dist-packages/ray/_private/node.py”, line 312, in init
self.start_head_processes()
File “/usr/local/lib/python3.8/dist-packages/ray/_private/node.py”, line 1325, in start_head_processes
self._write_cluster_info_to_kv()
File “/usr/local/lib/python3.8/dist-packages/ray/_private/node.py”, line 1280, in _write_cluster_info_to_kv
assert curr_val == self._session_name.encode(“utf-8”), (
AssertionError: Session name session_2025-02-19_00-01-46_887197_46214 does not match persisted value b’session_2025-02-18_23-50-54_897299_42794’. Perhaps there was an error connecting to Redis.

Hello! Welcome to the Ray community :slight_smile: It seems like this is the main error here:

Session name session_2025-02-19_00-01-46_887197_46214 does not match persisted value b’session_2025-02-18_23-50-54_897299_42794’. Perhaps there was an error connecting to Redis

Seems like there’s an issue connecting to the Redis server, or there’s some leftover old files that might be causing some mismatch.

  • Are you sure the Redis server is running without error?
  • Sometimes, old session data can cause conflicts (esp with the session names like listed above). You can try stopping Ray and cleaning up any temporary files or directories related to Ray sessions. These are usually located in /tmp/ray but yours might be in a different place.
  • Make sure the ports that Ray and Redis are running on aren’t being used by any other processes.
  • Are there any other error messages that are showing up? There’s some logs that you can also check in the temp folder I mentioned above, but they’re most likely in /tmp/ray/session_latest/logs

Here’s some docs that might be helpful too: