microsoft / microsoft/WSL

Any plan to implement memfd_create in wsl1?

Open
#10,230 1 comment 1 reaction 0 assignees View on GitHub
feature
Dominant language
C++
Stars
33.7k
Forks
1.8k
Avg merge
3d 17h
Merged PRs (30d)
116

Description

**Is your feature request related to a problem? Please describe.**
buildah chroot doesn't work due to missing memfd_create and potentially more.

**Describe the solution you'd like**
Support memfd_create first .

**Describe alternatives you've considered**
Use wsl2, but wsl1 fits my workflow due to real localhost support and faster startup.

**Additional context**
I sometimes need to run some commands in a chrooted environment from a container image like the following.
I expected it to work on wsl1 because there is not much kernel dependencies in case of chroot, but it gave me memfd_create(): Function not implemented.

```
sudo buildah from --isolation=chroot --storage-driver=vfs alpine:edge
sudo buildah run --isolation=chroot --storage-driver=vfs --pid=host --net=host --no-pivot --ipc=host --cgroupns=host alpine-working-container /bin/sh
```

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the failure with the provided buildah chroot commands and confirm that memfd_create reports “Function not implemented” under WSL1. Investigate the WSL1 implementation area responsible for this missing functionality; done means the command sequence works on WSL1 with memfd_create supported.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux
Domain
operating-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.