Hi!

Watch in the log for this message:

|[notice] Delaying directory fetches: We are hibernating or shutting down.|

|
|

Regards,
excurso


forest-relay-contact--- wrote via tor-relays:
Hello.

What is the authoritative way to determine if a relay is hibernating? I
would have thought that using the control socket would be best, but Tor
seems to unlink it when it enters hibernation, so Stem does not work.

There's a possible heuristic by checking if /run/tor/tor.pid exists when
/run/tor/control does not, but that's fragile because it assumes that
the control socket is even enabled. Parsing the logs is doable, but also
quite fragile. And I could certainly parse /var/lib/tor/state, but its
format is surely subject to change at any time.

How do I correctly determine whether a Tor process is in hibernation?

Regards,
forest
_______________________________________________ > tor-relays mailing list -- [email protected] > To
unsubscribe send an email to [email protected]
_______________________________________________
tor-relays mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to