Skip to content

Commit 1252055

Browse files
authored
Merge pull request #8454 from MicrosoftDocs/main637983758578695864sync_temp
Repo sync for protected CLA branch
2 parents fa43641 + e96a3f5 commit 1252055

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

docs/debugger/debug-dotnet-core-in-wsl-2.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Debug .NET apps in Linux using WSL"
33
description: Learn to run and debug your .NET apps in WSL without leaving Visual Studio.
4-
ms.date: "09/17/2021"
4+
ms.date: "09/09/2022"
55
ms.topic: "conceptual"
66
helpviewer_keywords:
77
- "debugging, linux"
@@ -165,6 +165,18 @@ With these launch profiles, you can easily switch back and forth between your ta
165165

166166
![Multiple WSL launch profiles in the launch profile list](media/linux-wsl2-debugging-switch-target-distribution.png)
167167

168+
## Attach to a running WSL process
169+
170+
In addition to debugging from app startup using F5, you can debug by attaching to a running WSL process using the attach to process feature.
171+
172+
1. With the app running, choose **Debug** > **Attach to Process**.
173+
174+
1. For the **Connection type**, choose **Windows Subsystem for Linux (WSL)**, and then choose the Linux distribution for the **Connection target**.
175+
176+
1. Choose **Attach**.
177+
178+
![Screenshot of WSL process in the attach to process dialog box](media/linux-wsl2-debugging-attach-to-process.png)
179+
168180
## WSL settings in the launch profile
169181

170182
The following table shows the settings that are supported in the launch profile.
Loading

0 commit comments

Comments
 (0)