.nh .TH pki-healthcheck 8 "January 16, 2020" PKI "pki-healthcheck CLI" .SH NAME .PP pki-healthcheck - Command-Line Interface to check health of a PKI installation .SH SYNOPSIS .PP \fBpki-healthcheck\fP [\fICLI-options\fP] .SH DESCRIPTION .PP A PKI installation can be complex, therefore identifying real or potential issues can be difficult and require a lot of analysis. This tool aims to reduce the burden by attempting to identify issues in advance so that they can be corrected, ideally before the issue becomes critical. .SS ORGANIZATION .PP The areas of the system to check are logically grouped together. This grouping is called a source. A source consists of one or more checks. .PP A check is as atomic as possible to limit the scope and complexity. .PP Each check will return a result, either a result of WARNING, ERROR, CRITICAL or SUCCESS. Returning SUCCESS tells you that the check was done and was deemed correct. .PP Upon failure, the output will include name of the source and name of the check that detected the failure along with a message and name/value pairs indicating the problem. If a check can't make a final determination, it throws WARNING so that it can be examined. .SH OPTIONS .SS COMMANDS .PP \fB--list-sources\fP .br Display a list of the available sources and the checks associated with those sources. .SS OPTIONAL ARGUMENTS .PP \fB--source\fP=\fISOURCE\fP .br Execute one or more checks within this given source. .PP \fB--check\fP=\fICHECK\fP .br Execute this particular check within a source. A \fIsource\fP must be supplied as well with this option. .PP \fB--output-type\fP=\fI[json|human]\fP .br Set the output type. Defaults to JSON. .PP \fB--failures-only\fP .br Exclude SUCCESS results on output. .PP \fB--severity\fP=\fISEVERITY\fP .br Only report errors in the requested severity of SUCCESS, WARNING, ERROR or CRITICAL. This can be provided multiple times to search on multiple levels. .PP \fB--debug\fP .br Generate additional debugging output. .SS JSON OUTPUT .PP The output is displayed as a list of result messages for each check executed in JSON format. This could be input for a monitoring system. .PP \fB--output-file\fP=\fIFILENAME\fP .br Write the output to this filename rather than stdout. .PP \fB--indent\fP=\fIINDENT\fP .br Pretty-print the JSON with this indention level. This can make the output more human-readable. .SS HUMAN-READABLE OUTPUT .PP The results are displayed in a more human-readable format. .PP \fB--input-file\fP=\fIFILENAME\fP .br Take as input a JSON results output and convert it to a more human-readable form. .SH EXIT STATUS .PP 0 if all checks were successful .PP 1 if any one check failed or the command failed to execute properly .SH FILES .PP /etc/pki/healthcheck.conf .SH NOTES .SS CHECKS INCLUDED .PP \fBCertificate sync between CS.cfg and NSS database\fP .br Checks whether the system certificates in CS.cfg and NSS database are the same .PP \fBSystem certificate expiry\fP .br Checks the expiry status of the installed system certificates .PP \fBSystem certificate trust flags\fP .br Checks whether the installed system certificates carry the correct Trust flags .PP \fBSubsystem connectivity check\fP .br Checks whether a subsystem is running and able to respond to requests .SH EXAMPLES .PP Execute healthcheck with the default JSON output: .br \fBpki-healthcheck\fP .PP Execute healthcheck with a prettier JSON output: .br \fBpki-healthcheck --indent 2\fP .PP Execute healthcheck and only display errors: .br \fBpki-healthcheck --failures-only\fP .PP Execute healthcheck and display results in human-readable format: .br \fBpki-healthcheck --output-format human\fP .PP Execute healthcheck and write results to a file: .br \fBpki-healthcheck --output-file /var/log/pki/healthcheck/results.json\fP .PP Display in the previous report in a human-readable format: .br \fBpki-healthcheck --output-format human --input-file /var/log/pki/healthcheck/results.json\fP .SH AUTHORS .PP Dinesh Prasanth M K .SH COPYRIGHT .PP Copyright (c) 2020 Red Hat, Inc. This is licensed under the GNU General Public License, version 2 (GPLv2). A copy of this license is available at http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt \[la]http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt\[ra]\&.