donadona
Posts: 3
Joined: Tue Mar 19, 2019 12:07 am

SSH fails at a certain Windows PC

Tue Mar 19, 2019 12:18 am

I have successfully SSHed from a Windows 10 PC (PC name "A") to headless Raspberry pi zero W with Raspbian installed.
However, when I tried to SSH from another Windows 10 PC (PC name "B"), I've got "Host does not exist" error message.
I'm afraid this is the setting problem on PC "B", however, I've got stuck.

Here's conditions:
  • SSH is enabled through Raspberry setting through GUI, and it worked anyway with PC "A"
  • RasPI 0 W, PC A and B is connected under the same wifi network, confirmed by the router setting and IP addresses.
  • MobaXterm is used as a terminal software. When I copied the session configuration file from PC A into PC B, it failed neither.
  • RasPI 0 is powered by independent power source, not from USB connection from either PC
  • PC A is mainly used for my job, and PC B is for my private. Maybe PC A has configured for more engineering oriented features, but I don't know the difference. Both PCs are up-to-dated by Windows/Driver updates.

Andyroo

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 2:04 am

How are you addressing the Pi? Is it by IP address or name?

If it is by name and it’s a ‘.local’ name, then the chance is the working one has iTunes or Bonjour loaded and the other does not.

You could try by IP address on both.

Other thought is that the working machine has had its HOST file changed :o

User avatar
HawaiianPi
Posts: 4857
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 2:19 am

As Andyroo said, if you are using ssh [email protected] ([email protected]) you need to have mDNS/Zeroconf on the Windows machine. The simplest way to achieve this is to install Apple's iTunes or Bonjour Printer services.

For a cleaner install you can extract the Bonjour network service and just install that. I use WinRAR or 7-Zip to extract the BonjourPSSetup.exe installer to a folder, then only install Bonjour64.msi to get the mDNS/Zeroconf service without extra Apple stuff I don't need.

If you are using the Pi0's IP, then it's probably a Windows Firewall or security software issue.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

donadona
Posts: 3
Joined: Tue Mar 19, 2019 12:07 am

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 3:06 am

Thanks for the suggestions, Andyroo and HawaiianPi, here are some additional conditions. I believe investigating successful condition on PC A would be as important as investigating the failure condition on PC B.

  • The host name was specified by name without ".local" attached, like simply "Raspbian" when I successfully connected from PC "A". The IP addressing has not been tried yet.
  • Bonjour or any other Apple software has not been installed in the PC A, the successful one. Host name has not been changed neither. I'll have a look at conditions on PC B when I back home.
  • Security software has not been installed in the both PCs except for the default windows defender or some like windows default software.
  • When I PINGed the hostname of PI from command prompt, PC A has found PI while PC B failed.

mattmiller
Posts: 2131
Joined: Thu Feb 05, 2015 11:25 pm

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 7:24 am

JFI Alternative info for Win 10 machines
The need to install Bonjour is no longer required.

Win 10 has mDNS built-in.

( I "proved" this when our school computers were replaced with Win 10 machines - they connected to my raspberry pi without Bonjour being installed)

Having said that, for most of 2018, Win 10 mDNS wasn't working properly (the Spring 2018 update borked it) but is again now (at least on my machine it is)

Maybe not useful info to help fix the problem but I thought I'd offer it out anyway!

User avatar
thagrol
Posts: 1980
Joined: Fri Jan 13, 2012 4:41 pm
Location: Darkest Somerset, UK
Contact: Website

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 12:39 pm

Are all three computers on the same network?

Do they all have IP addresses in the same subnet?

If you're accessing the zeroW over USB via gadget mode have you setup its host PC to brdige or forward that link to your LAN?

Does the zero W have a static IP address or does it get an address via dhcp?
Attempts to contact me outside of thes forums will be ignored unless signed in triplicate, sent in, sent back, queried, lost, found, subjected to public enquiry, lost again, and finally buried in soft peat for three months and recycled as firelighters

Heater
Posts: 13868
Joined: Tue Jul 17, 2012 3:02 pm

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 1:03 pm

Can you ping from everywhere to everywhere? In both directions?

A -> B
A --> Pi
B -> A
B --> Pi
Pi -> A
Pi -> B

Ping by IP address first then host names.
Memory in C++ is a leaky abstraction .

pfletch101
Posts: 543
Joined: Sat Feb 24, 2018 4:09 am
Location: Illinois, USA

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 3:24 pm

mattmiller wrote:
Tue Mar 19, 2019 7:24 am
JFI Alternative info for Win 10 machines
The need to install Bonjour is no longer required.

Win 10 has mDNS built-in.

( I "proved" this when our school computers were replaced with Win 10 machines - they connected to my raspberry pi without Bonjour being installed)

Having said that, for most of 2018, Win 10 mDNS wasn't working properly (the Spring 2018 update borked it) but is again now (at least on my machine it is)

Maybe not useful info to help fix the problem but I thought I'd offer it out anyway!
My experience is that Win 10 networking is still not working consistently between Windows machines, so I would not be optimistic about diagnosing and fixing inconsistencies between Windows machines and Pis. All the Windows machines on my local network can, in fact, now communicate with my Pis by name or IP address, but one of my Windows machines cannot always see or communicate with the other Windows machines, even though I have done everything recommended to fix the known issues and have the router assigning all the Windows systems constant IP addresses (like the Pis). The most frustrating aspect of this is that on one day everything may work 'according to the book', but on the next, despite no changes having been made to any of the systems or to the network, the one system can only see shares on my NAS - not the ones on the other systems. I have a suspicion that it may have something to do with the order in which the systems are started up in the morning, but I don't feel like doing systematic investigations of this before breakfast! :)

mattmiller
Posts: 2131
Joined: Thu Feb 05, 2015 11:25 pm

Re: SSH fails at a certain Windows PC

Tue Mar 19, 2019 9:27 pm

My experience is that Win 10 networking is still not working consistently between Windows machines, so I would not be optimistic about diagnosing and fixing inconsistencies between Windows machines and Pis.
:(

I only have one Win machine on my house net so I'm probably just lucky that its working (at moment)

User avatar
HawaiianPi
Posts: 4857
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: SSH fails at a certain Windows PC

Thu Mar 21, 2019 2:02 am

donadona wrote:
Tue Mar 19, 2019 3:06 am
Thanks for the suggestions, Andyroo and HawaiianPi, here are some additional conditions. I believe investigating successful condition on PC A would be as important as investigating the failure condition on PC B.
Not necessarily, if your goal is just to get the B system working as desired.

The host name was specified by name without ".local" attached
Sounds like Windows 10 mDNS. Bonjour isn't the only way to get mDNS/Zeroconf on Windows 10, it's just easier sometimes (see below...).

Bonjour or any other Apple software has not been installed in the PC A, the successful one. Host name has not been changed neither. I'll have a look at conditions on PC B when I back home.
So Windows 10 mDNS is functioning on the work PC-A, but not on your personal PC-B.

When I PINGed the hostname of PI from command prompt, PC A has found PI while PC B failed.
Not surprising, since mDNS is not working on your system (but it is on PC-A).

mattmiller wrote:
Tue Mar 19, 2019 7:24 am
JFI Alternative info for Win 10 machines. The need to install Bonjour is no longer required.
...
Having said that, for most of 2018, Win 10 mDNS wasn't working properly (the Spring 2018 update borked it) but is again now.
The October/Fall 2018 update supposedly fixed it. In my case it threw my Win10 gaming laptop into a boot-loop, so I had to roll back and use Bonjour. At least until this past weekend, when I tried the recent 19h1 insider slow ring preview (working well so far, including mDNS).

So you can check if your personal PC-B has the Fall 2018 update applied, and if not you could try that (and hope you have better luck than I did). Or you could get on the Windows Insider slow ring and try the 19h1 preview.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

donadona
Posts: 3
Joined: Tue Mar 19, 2019 12:07 am

Re: SSH fails at a certain Windows PC

Thu Mar 21, 2019 3:01 am

Thanks HawaiianPi, the problem on my PC has solved thanks to your suggestion.
Everything's working properly after the Windows 10 version 1809 update, which had been missing in my PC-B.

User avatar
HawaiianPi
Posts: 4857
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: SSH fails at a certain Windows PC

Thu Mar 21, 2019 4:52 am

Glad we figured it out. Image
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

Return to “General discussion”