1

I must unmount drvfs and remount it with the ‘metadata’ flag to use a new file system features to WSL that allows making changes in permissions in WSL. But when I do this:

sudo umount /mnt/c

It returns

umount: /mnt/c: target is busy

How can I force the process to stop without lose data? Which process could be running that should not?

KPC
  • 19
  • 5
  • How about mounting the drives with metadata automatically without doing a umount/mount cycle? See this [blog post](https://devblogs.microsoft.com/commandline/automatically-configuring-wsl/). Mounting option can be added in `/etc/wsl.conf` file. – Biswapriyo Apr 24 '20 at 20:37

1 Answers1

3

Try umount -l /mnt/c. According to the man page it does the following

   -l, --lazy
          Lazy unmount.  Detach the filesystem from the file hierarchy now, and clean up all references to this filesystem as soon as it is not busy anymore.
vkozyrev
  • 725
  • 5
  • 10