Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can we specify which NUMA WSL will run on? #12319

Open
muratyurdakul75 opened this issue Nov 26, 2024 · 10 comments
Open

Can we specify which NUMA WSL will run on? #12319

muratyurdakul75 opened this issue Nov 26, 2024 · 10 comments

Comments

@muratyurdakul75
Copy link

There are 2 NUMAs in my system. Numa 0 and 1. WSL always uses numa 1. Is there any way to make it use numa 0?
When the computer starts, wsl starts automatically and I want it to work on NUMA 0. Is there a solution for this?

I don't want to use external applications. Can we do this feature directly with Windows or WSL settings?

Thanks

Copy link

Logs are required for review from WSL team

If this a feature request, please reply with '/feature'. If this is a question, reply with '/question'.
Otherwise please attach logs by following the instructions below, your issue will not be reviewed unless they are added. These logs will help us understand what is going on in your machine.

How to collect WSL logs

Download and execute collect-wsl-logs.ps1 in an administrative powershell prompt:

Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/microsoft/WSL/master/diagnostics/collect-wsl-logs.ps1" -OutFile collect-wsl-logs.ps1
Set-ExecutionPolicy Bypass -Scope Process -Force
.\collect-wsl-logs.ps1

The script will output the path of the log file once done.

If this is a networking issue, please use collect-networking-logs.ps1, following the instructions here

Once completed please upload the output files to this Github issue.

Click here for more info on logging
If you choose to email these logs instead of attaching to the bug, please send them to [email protected] with the number of the github issue in the subject, and in the message a link to your comment in the github issue and reply with '/emailed-logs'.

View similar issues

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it!

Open similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

@muratyurdakul75 muratyurdakul75 changed the title Determine which NUMA a multi-NUMA system will operate on. Can we specify which NUMA WSL will run on? Nov 26, 2024
Copy link

Logs are required for review from WSL team

If this a feature request, please reply with '/feature'. If this is a question, reply with '/question'.
Otherwise please attach logs by following the instructions below, your issue will not be reviewed unless they are added. These logs will help us understand what is going on in your machine.

How to collect WSL logs

Download and execute collect-wsl-logs.ps1 in an administrative powershell prompt:

Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/microsoft/WSL/master/diagnostics/collect-wsl-logs.ps1" -OutFile collect-wsl-logs.ps1
Set-ExecutionPolicy Bypass -Scope Process -Force
.\collect-wsl-logs.ps1

The script will output the path of the log file once done.

If this is a networking issue, please use collect-networking-logs.ps1, following the instructions here

Once completed please upload the output files to this Github issue.

Click here for more info on logging
If you choose to email these logs instead of attaching to the bug, please send them to [email protected] with the number of the github issue in the subject, and in the message a link to your comment in the github issue and reply with '/emailed-logs'.

View similar issues

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it!

Open similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

@muratyurdakul75
Copy link
Author

/question

/question

Copy link

Diagnostic information
Found '/question', adding tag 'question'

@muratyurdakul75
Copy link
Author

Copy link

Diagnostic information
.wslconfig found
Detected appx version: 2.3.26.0

@zcobol
Copy link

zcobol commented Nov 26, 2024

@muratyurdakul75 in Task Manager try seting process affinity for wslservice.exe to use the CPU associated with NUMA 0 only.

@muratyurdakul75
Copy link
Author

muratyurdakul75 commented Nov 27, 2024

@muratyurdakul75 in Task Manager try seting process affinity for wslservice.exe to use the CPU associated with NUMA 0 only.

Thanks for your answer. But setting it from task manager is not a solution. There is a situation like this; I have 2x40 processors. I want WSL to use more processors. With the "node interleaving" setting I made from BIOS, I was able to arrange the numbers as 64+16. Numa:0 has 64 processors, Numa:1 has 16 processors. When wsl first runs, it uses Numa:1. That is, 16 processors. Even if I set it as numa:0 from Task Manager, when I look with the "Docker info" command, I see that it uses 16 processors. Therefore, when wsl first runs, it needs to run directly with numa:0.

@muratyurdakul75
Copy link
Author

It would be great if we could adjust this with a setting in the .wslconfig file.

Copy link

Diagnostic information
Found '/feature', adding tag 'feature'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants