Default user for WSL OS on Windows 10
1. Open a command prompt or PowerShell. (You shouldn’t run as admin since this is based for the specific user).
2. Copy and paste the command below into the command prompt or PowerShell for the .exe file of the WSL distro name (ex: “Debian”) you want to set the default user for, and press Enter. (You can replace root with any user you’d like)
[Ubuntu] > ubuntu config --default-user root
[Ubuntu 18.04 LTS] > ubuntu1804 config --default-user root
[Ubuntu 16.04 LTS] > ubuntu1604 config --default-user root
[openSUSE Leap 42] > openSUSE-42 config --default-user root
[USE Linux] > SLES-12 config --default-user root
[Debian] (My personal favorite) > debian config --default-user root
[Kali Linux] > kali config --default-user root
<- OTHERS ->