问题
I have used the Remote SSH extension by Microsoft in Visual Studio Code to connect from my Windows 10 machine to my Raspberry Pi 4. It worked fine until one day. After three times entering the correct password, it outputs "This process tried to write to a nonexistent pipe". I can still connect via the terminal and Putty. I am using the host's password to log in.
I have tried to uninstall the extension, tried an earlier version and tested the extension on another Windows 10 computer without any luck. I have also added the exact path to the ssh config file in the vscode settings.
What can I do?
回答1:
I solved this issue by creating a public and private key for my ssh connection. I added the public key to a .ssh folder on my Raspberry Pi. In vscode I added the path to the private key in the config file for the ssh connection.
I used this video https://www.youtube.com/watch?v=vpk_1gldOAE to learn how to generate the keys.
来源:https://stackoverflow.com/questions/61138664/remote-ssh-in-visual-studio-code-does-not-work