bugzilla-daemon at mindrot.org
2013-Jun-24 13:45 UTC
[Bug 2122] New: ssh: Could not resolve hostname nohost: Success
https://bugzilla.mindrot.org/show_bug.cgi?id=2122 Bug ID: 2122 Summary: ssh: Could not resolve hostname nohost: Success Product: Portable OpenSSH Version: 6.2p1 Hardware: Other OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: ssh Assignee: unassigned-bugs at mindrot.org Reporter: plautrba at redhat.com When the resolver is not configured properly, ssh shows a "Success" error message: /etc/nsswitch.conf: hosts: files dns xyz $ ssh nohost ssh: Could not resolve hostname nohost: Success The message "Success" doesn't make sense given that it's in fact a system error. It's an issue of ssh_gai_strerror() which can't handle a situation when getaddrinfo() returns EAI_SYSTEM but errno is not set/is set to 0. A potential fix: --- a/misc.c +++ b/misc.c @@ -127,7 +127,7 @@ unset_nonblock(int fd) const char * ssh_gai_strerror(int gaierr) { - if (gaierr == EAI_SYSTEM) + if (gaierr == EAI_SYSTEM && errno != 0) return strerror(errno); return gai_strerror(gaierr); } -- You are receiving this mail because: You are watching the assignee of the bug.
bugzilla-daemon at mindrot.org
2013-Jun-24 13:52 UTC
[Bug 2122] ssh: Could not resolve hostname nohost: Success
https://bugzilla.mindrot.org/show_bug.cgi?id=2122 --- Comment #1 from Petr Lautrbach <plautrba at redhat.com> --- Using the suggested patch, the message changes to: $ ssh nohost ssh: Could not resolve hostname nohost: System error -- You are receiving this mail because: You are watching the assignee of the bug.
bugzilla-daemon at mindrot.org
2013-Jun-24 14:57 UTC
[Bug 2122] ssh: Could not resolve hostname nohost: Success
https://bugzilla.mindrot.org/show_bug.cgi?id=2122 Darren Tucker <dtucker at zip.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dtucker at zip.com.au Blocks| |2076 --- Comment #2 from Darren Tucker <dtucker at zip.com.au> --- seems reasonable to me. -- You are receiving this mail because: You are watching the assignee of the bug. You are watching someone on the CC list of the bug.
bugzilla-daemon at mindrot.org
2013-Jul-12 00:44 UTC
[Bug 2122] ssh: Could not resolve hostname nohost: Success
https://bugzilla.mindrot.org/show_bug.cgi?id=2122 Damien Miller <djm at mindrot.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |djm at mindrot.org Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #3 from Damien Miller <djm at mindrot.org> --- applied - will be in 6.3. Thanks! -- You are receiving this mail because: You are watching the assignee of the bug. You are watching someone on the CC list of the bug.
bugzilla-daemon at mindrot.org
2021-Apr-23 05:10 UTC
[Bug 2122] ssh: Could not resolve hostname nohost: Success
https://bugzilla.mindrot.org/show_bug.cgi?id=2122 Damien Miller <djm at mindrot.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #4 from Damien Miller <djm at mindrot.org> --- closing resolved bugs as of 8.6p1 release -- You are receiving this mail because: You are watching someone on the CC list of the bug. You are watching the assignee of the bug.
Apparently Analagous Threads
- [PATCH] Build problem in current portable CVS
- PATCH: multiple BindAddress
- remote port forward failed because of failure resolving localhost to IP with error No such file or directory
- [PATCH] Allow binding to a local port (OpenSSH 5.2)
- ssh-keyscan continuity patch --