Skip to content

Commit 41904f2

Browse files
Expand on remote SSH troubleshooting (#387)
1 parent d73ab49 commit 41904f2

1 file changed

Lines changed: 19 additions & 5 deletions

File tree

remote-ssh.qmd

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,13 @@ The long-running sessions are associated with the workspace in which you use the
8888

8989
Because the supervisor runs your R and Python sessions without any UI attached, it can't tell when you're done with them. In order to prevent sessions from running indefinitely and consuming resources on your remote host, the supervisor will shut them down after a certain period of inactivity. This period is controlled by the [`kernelSupervisor.shutdownTimeout`](positron://settings/kernelSupervisor.shutdownTimeout) setting.
9090

91-
The shutdown timeout will never interrupt a kernel that's busy running code; it doesn't start counting down until the kernel is idle _and_ it's not connected to any Positron windows.
91+
The shutdown timeout will never interrupt a kernel that's busy running code; it doesn't start counting down until the kernel is idle _and_ it's not connected to any Positron windows.
9292

9393
If you just want to allow your kernels to finish any running computations when you exit Positron, use the _when idle_ setting.
9494

9595
There's also an option to allow the kernels to run forever; if you use this option, your R and Python kernels will never exit unless you manually kill the processes or shut them down from Positron. We don't generally recommend using this option unless you are familiar with process management on your remote host, since it can lead to resource exhaustion.
9696

97-
## How it works & troubleshooting
97+
## How it works
9898

9999
When Positron connects to a new host for the first time, it does the following:
100100

@@ -108,13 +108,27 @@ When Positron connects to a new host for the first time, it does the following:
108108
The client and server must be using **exactly** the same Positron version. We make Positron Server builds available for both regular monthly releases as well as [daily builds](updating.qmd#daily-builds), so you can use either for remote SSH sessions. If you connect to a remote host with a new client version of Positron (for example, because a new monthly release is available), the new matching version of Positron Server will be downloaded and unpacked.
109109
:::
110110

111+
If you need to use a different URL to download Positron Server (for example to use a local copy due to network constraints, or to force the use of a particular version even if it's not autodetected), you can edit the [`remoteSSH.serverDownloadUrlTemplate`](positron://settings/remoteSSH.serverDownloadUrlTemplate) setting:
112+
113+
![Remote SSH: Server Download Url Template Setting](./images/remote-ssh-server-template.png){width=650 fig-alt="Positron settings panel showing the Remote SSH Server Download URL Template field with a text input for a custom URL."}
114+
115+
If you need to install the server data in a different location than `~/.positron-server`, edit the [`remoteSSH.serverInstallPath`](positron://settings/remoteSSH.serverInstallPath) setting.
116+
117+
## Troubleshooting
118+
111119
The two most common problems are:
112120

113121
- Encountering a 404 when downloading the Positron Server binary. This happens when you attempt to use Remote SSH against a host type that's not supported, for example, connecting to a macOS host.
114122
- Encountering an error when starting the Positron Server binary. This happens when you attempt to use Remote SSH against a version of Linux that's not supported by Positron.
115123

116-
Occasionally, the installation on the remote server can be corrupted, for example, if the download was interrupted. If you encounter errors installing Positron on the remote server, you can try deleting the `~/.positron-server` directory on the remote host and then connecting again.
124+
Occasionally, the installation on the remote server can be corrupted, for example, if the download was interrupted. If you encounter errors installing Positron on the remote server, you can try deleting the server directory on the remote host, killing any running server processes, and then connecting again.
117125

118-
If you need to use a different URL to download Positron Server (for example to use a local copy due to network constraints, or to force the use of a particular version even if it's not autodetected), you can edit the [`remoteSSH.serverDownloadUrlTemplate`](positron://settings/remoteSSH.serverDownloadUrlTemplate) setting:
126+
```sh
127+
# On the remote host, kill any existing positron-server processes
128+
pkill -f positron-server
119129

120-
![Remote SSH: Server Download Url Template Setting](./images/remote-ssh-server-template.png){width=650 fig-alt="Positron settings panel showing the Remote SSH Server Download URL Template field with a text input for a custom URL."}
130+
# On the remote host, remove all server state
131+
rm -rf ~/.positron-server
132+
133+
# Reconnect from Positron Desktop!
134+
```

0 commit comments

Comments
 (0)