client: add -d option to print debug messages
This commit is contained in:
parent
28b0a23949
commit
22345c5ddf
4 changed files with 11 additions and 3 deletions
|
@ -3265,6 +3265,9 @@ This defaults to the compiled-in default; there would rarely be a need
|
||||||
to change this.
|
to change this.
|
||||||
@item -n
|
@item -n
|
||||||
This option disables resolving IP addresses to hostnames.
|
This option disables resolving IP addresses to hostnames.
|
||||||
|
@item -d
|
||||||
|
This option enables printing of debugging messages (if compiled with debugging
|
||||||
|
support).
|
||||||
@item -4
|
@item -4
|
||||||
With this option hostnames will be resolved only to IPv4 addresses.
|
With this option hostnames will be resolved only to IPv4 addresses.
|
||||||
@item -6
|
@item -6
|
||||||
|
|
|
@ -32,6 +32,9 @@ specify port-number
|
||||||
\fB\-n\fR
|
\fB\-n\fR
|
||||||
display raw IP addresses (don't attempt to look up hostnames)
|
display raw IP addresses (don't attempt to look up hostnames)
|
||||||
.TP
|
.TP
|
||||||
|
\fB\-d\fR
|
||||||
|
print debugging messages (if compiled with debugging support)
|
||||||
|
.TP
|
||||||
\fB\-4\fR
|
\fB\-4\fR
|
||||||
resolve hostnames only to IPv4 addresses
|
resolve hostnames only to IPv4 addresses
|
||||||
.TP
|
.TP
|
||||||
|
|
4
client.c
4
client.c
|
@ -2797,6 +2797,8 @@ main(int argc, char **argv)
|
||||||
}
|
}
|
||||||
} else if (!strcmp(*argv, "-a")) {
|
} else if (!strcmp(*argv, "-a")) {
|
||||||
auto_auth = 1;
|
auto_auth = 1;
|
||||||
|
} else if (!strcmp(*argv, "-d")) {
|
||||||
|
log_debug_enabled = 1;
|
||||||
} else if (!strcmp(*argv, "-m")) {
|
} else if (!strcmp(*argv, "-m")) {
|
||||||
multi = 1;
|
multi = 1;
|
||||||
} else if (!strcmp(*argv, "-n")) {
|
} else if (!strcmp(*argv, "-n")) {
|
||||||
|
@ -2810,7 +2812,7 @@ main(int argc, char **argv)
|
||||||
return 0;
|
return 0;
|
||||||
} else if (!strncmp(*argv, "-", 1)) {
|
} else if (!strncmp(*argv, "-", 1)) {
|
||||||
LOG(LOGS_ERR, LOGF_Client,
|
LOG(LOGS_ERR, LOGF_Client,
|
||||||
"Usage: %s [-h HOST] [-p PORT] [-n] [-4|-6] [-a] [-f FILE] [-m] [COMMAND]",
|
"Usage: %s [-h HOST] [-p PORT] [-n] [-d] [-4|-6] [-a] [-f FILE] [-m] [COMMAND]",
|
||||||
progname);
|
progname);
|
||||||
return 1;
|
return 1;
|
||||||
} else {
|
} else {
|
||||||
|
|
4
configure
vendored
4
configure
vendored
|
@ -768,9 +768,9 @@ add_def DEFAULT_CONF_FILE "\"$SYSCONFDIR/chrony.conf\""
|
||||||
add_def DEFAULT_USER "\"$default_user\""
|
add_def DEFAULT_USER "\"$default_user\""
|
||||||
add_def MAIL_PROGRAM "\"$mail_program\""
|
add_def MAIL_PROGRAM "\"$mail_program\""
|
||||||
|
|
||||||
common_features="`get_features ASYNCDNS IPV6 SECHASH`"
|
common_features="`get_features ASYNCDNS IPV6 SECHASH DEBUG`"
|
||||||
chronyc_features="`get_features READLINE`"
|
chronyc_features="`get_features READLINE`"
|
||||||
chronyd_features="`get_features CMDMON NTP REFCLOCK RTC PRIVDROP DEBUG`"
|
chronyd_features="`get_features CMDMON NTP REFCLOCK RTC PRIVDROP`"
|
||||||
add_def CHRONYC_FEATURES "\"$chronyc_features $common_features\""
|
add_def CHRONYC_FEATURES "\"$chronyc_features $common_features\""
|
||||||
add_def CHRONYD_FEATURES "\"$chronyd_features $common_features\""
|
add_def CHRONYD_FEATURES "\"$chronyd_features $common_features\""
|
||||||
echo "Features : $chronyd_features $chronyc_features $common_features"
|
echo "Features : $chronyd_features $chronyc_features $common_features"
|
||||||
|
|
Loading…
Reference in a new issue