<p>You cannot reconnect, but everything that is printed with <code>-printtoconsole</code> will also be written to the <code>debug.log</code> file. So you can just do <code>tail -f debug.log</code> to get the same output.</p>

<p>If you wanted to monitor for errors in this way, I would suggest that you always do <code>tail -f debug.log</code> instead of using <code>-printtoconsole</code>. The debug.log will always be written to so you can look at previous logs while you are offline/away. And it is still written to when Bitcoin Core is daemonized (with <code>-daemon</code>) or otherwise running disconnected from your shell (as in your case).</p>

CC BY-SA 4.0
2020-02-19T19:45:46.763Z
2020-02-19T19:45:46.763Z
Ava Chow
<p>I don't think you can reconnect to it easily, but for next time, you could create a <code>screen</code> session and start bitcoind inside of it. That way you could reconnect to it with <code>screen -r</code></p>

CC BY-SA 4.0
2019-09-22T17:43:14.880Z
2019-09-22T17:43:14.880Z
SylTi
<p>I started <code>bitcoind</code> with the option <code>-printtoconsole</code> to check for errors and my terminal ssh connection was timed out during the night - probably because my computer was in hibernation. </p>

<p>I see that the process is still running under <code>top</code>. </p>

<p>Is there an option to reconnect so that it will print the output to a new ssh connected shell?</p>

<bitcoin-core><bitcoind>
How to re-connect to `bitcoind -printtoconsole` after socket timeout?
bomben
# How to re-connect to `bitcoind -printtoconsole` after socket timeout?

(Asked by: username_0 on 2019-08-29)

I started `bitcoind` with the option `-printtoconsole` to check for errors and my terminal ssh connection was timed out during the night - probably because my computer was in hibernation.

I see that the process is still running under `top`.

Is there an option to reconnect so that it will print the output to a new ssh connected shell?

**Tags:** bitcoin-core, bitcoind


---

## 2 answers

### Answer by username_1 on 2020-02-19. Score: 0

You cannot reconnect, but everything that is printed with `-printtoconsole` will also be written to the `debug.log` file. So you can just do `tail -f debug.log` to get the same output.

If you wanted to monitor for errors in this way, I would suggest that you always do `tail -f debug.log` instead of using `-printtoconsole`. The debug.log will always be written to so you can look at previous logs while you are offline/away. And it is still written to when Bitcoin Core is daemonized (with `-daemon`) or otherwise running disconnected from your shell (as in your case).


---

### Answer by username_2 on 2019-09-22. Score: 0

I don't think you can reconnect to it easily, but for next time, you could create a `screen` session and start bitcoind inside of it. That way you could reconnect to it with `screen -r`


---

