client: reconnect with multiple addresses

Allow multiple hostnames/addresses separated by comma to be specified
with the -h option. Hostnames are resolved to up to 16 addresses. When
connecting to an address fails or no reply is received, try the next
address in the list.

Set the default value for the -h option to 127.0.0.1,::1.
This commit is contained in:
Miroslav Lichvar
2015-08-19 10:19:13 +02:00
parent 7079ca2718
commit 0cc8f68754
4 changed files with 140 additions and 44 deletions

View File

@@ -3252,9 +3252,9 @@ Chronyc supports the following command line options.
@item -v
Displays the version number of chronyc on the terminal, and exists.
@item -h <host>
This option allows the user to specify which host running the
@code{chronyd} program is to be contacted. This allows for remote
configuration, without having to ssh to the other host first.
This option allows the user to specify which host (or comma-separated list of
addresses) running the @code{chronyd} program is to be contacted. This allows
for remote configuration, without having to ssh to the other host first.
The default is to contact @code{chronyd} running on the same host as
that where chronyc is being run.