Skip to content

Fix SSH attach on a clean machine#1444

Merged
andrewcrawley merged 1 commit intomicrosoft:mainfrom
andrewcrawley:users/andrewcr/fix-ssh-attach
Mar 1, 2024
Merged

Fix SSH attach on a clean machine#1444
andrewcrawley merged 1 commit intomicrosoft:mainfrom
andrewcrawley:users/andrewcr/fix-ssh-attach

Conversation

@andrewcrawley
Copy link
Contributor

@andrewcrawley andrewcrawley commented Mar 1, 2024

Attaching to a C# process running on a brand-new Linux VM was failing with an error about being unable to create or access the .vs-debugger folder on the remote host. After investigating, this is due to a behavior change in liblinux - previously, the call to IRemoteFileSystem.Stat() would fail if the file didn't exist, but it now returns a valid object that you can query to determine that the file doesn't exist. I updated the logic accordingly.

Workaround: manually create the .vs-debugger folder on the remote host. Once it exists, the remote debugger will deploy successfully.

Attaching to a C# process running on a brand-new Linux VM was failing with an error about being unable to create or access the `.vs-debugger` folder on the remote host.  After investigating, this is due to a behavior change in liblinux - previously, the call to `IRemoteFileSystem.Stat()` would fail if the file didn't exist, but it now returns a valid object that you can query to determine that the file doesn't exist.

Workaround: manually create the `.vs-debugger` folder on the remote host.  Once it exists, debugging works.
@andrewcrawley andrewcrawley merged commit 87fff3f into microsoft:main Mar 1, 2024
@andrewcrawley andrewcrawley deleted the users/andrewcr/fix-ssh-attach branch March 1, 2024 02:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants