-
Notifications
You must be signed in to change notification settings - Fork 4
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
Use sio2jail on WSL #265
Use sio2jail on WSL #265
Conversation
WSL2 (released 2019) is based on a Linux VM. In general its behavior is consistent with any other Linux system running in a VM, so there should be no reason to discriminate WSL under `util.is_linux()`. In the future, we might want to check for specific features such as perf counters being supported, but that is an orthogonal concern. I have tested with several people using WSL across relatively modern laptops (Intel 8th gen and up) and in all cases the Intel PMU driver passed through enough perf counters for sio2jail to work. If we wanted to test support for sio2jail more thoroughly, I suspect the best method might be to actually try running sio2jail or the perf tool.
There is a test if perf counters are enabled, isn't there? I don't remember exactly how it works, so I may be wrong:
|
Ah, that's right, that's perfect. |
My only issue with From my testing, setting This sio2jail check could also fail with some other issue, such as lack lacking intel PMU driver entirely, or it not supporting enough perf counters. In which case changing |
This reverts commit 5bebd72.
This reverts commit 5bebd72.
WSL2 (released 2019) is based on a Linux VM. In general its behavior is consistent with any other Linux system running in a VM, so there should be no reason to discriminate WSL under
util.is_linux()
.In the future, we might want to check for specific features such as perf counters being supported, but that is an orthogonal concern.
I have tested with several people using WSL across relatively modern laptops (Intel 8th gen and up) and in all cases the Intel PMU driver passed through enough perf counters for sio2jail to work.
If we wanted to test support for sio2jail more thoroughly, I suspect the best method might be to actually try running sio2jail or the perf tool.