Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default output to stdout/stderr when the -e option is used #123

Open
mej opened this issue Feb 6, 2023 · 0 comments
Open

Default output to stdout/stderr when the -e option is used #123

mej opened this issue Feb 6, 2023 · 0 comments
Assignees
Labels
bug enhancement usability Confusing, strange, misleading, or otherwise problematic UX
Milestone

Comments

@mej
Copy link
Owner

mej commented Feb 6, 2023

(Background) Because it was originally written to interface with resource managers like Slurm and TORQUE, NHC's output is always directed to a log file. (In fact, TORQUE relies on the first few characters of output from the health check command to determine success or failure, so any extraneous output could cause NHC's results to be misinterpreted or mishandled.) The configuration variable LOGFILE controls what specific target should receive the output from NHC. It's typically set to a path+filename somewhere under /var/log (which also means that the default only works for root).

NHC recently acquired the ability to "test drive" a check line by supplying it to nhc via the -e option. I expect, and I think most users would expect, the output of something that's inherently interactive to default to the same terminal/pty device in which I ran nhc -e ... in the first place. At present, though, no special handling is performed, so the default output destination when directly running a check at the shell prompt is identical to that of a run from slurmd, cron, etc. The current behavior is counterintuitive, at least to me.

Moreover, I've seen more than 1 user run nhc -e ... and get hopelessly confused by what they saw (or didn't). Confused customers are cranky customers.

So let's change the default for -l/LOGFILE to stdout/stderr when the -e argument is used, essentially making nhc -l - the "interactive default" behavior.

@mej mej added bug enhancement usability Confusing, strange, misleading, or otherwise problematic UX labels Feb 6, 2023
@mej mej added this to the 1.5 Release milestone Feb 6, 2023
@mej mej self-assigned this Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug enhancement usability Confusing, strange, misleading, or otherwise problematic UX
Projects
None yet
Development

No branches or pull requests

1 participant