Windows 10: Set Default User for Windows Subsystem for Linux Distro in Windows 10

Discus and support Set Default User for Windows Subsystem for Linux Distro in Windows 10 in Windows 10 Tutorials to solve the problem; How to: Set Default User for Windows Subsystem for Linux Distro in Windows 10 How to Set Default User for Windows Subsystem for Linux (WSL) Distro in... Discussion in 'Windows 10 Tutorials' started by Brink, Jun 6, 2018.

  1. Brink Win User

    Set Default User for Windows Subsystem for Linux Distro in Windows 10


    How to: Set Default User for Windows Subsystem for Linux Distro in Windows 10

    How to Set Default User for Windows Subsystem for Linux (WSL) Distro in Windows 10


    The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line tools directly on Windows, alongside your traditional Windows desktop and modern store apps.

    When you have export and import WSL distros.

    The first time a newly installed WSL distro installation to complete.

    Once installation is complete, you will be prompted to create a new user account (and its password).

    Creating your Linux user is the first step in setting up a new Linux distribution on WSL. The first user account you create is automatically configured with a few special attributes:
    1. It is your default user -- it signs-in automatically on launch.
    2. It is Linux administrator (a member of the sudo group) by default.
    Each Linux distribution running on the Windows Subsystem for Linux has its own Linux user accounts and passwords. You will have to configure a Linux user account any time you add a distribution, reinstall, or reset. Linux user accounts are not only independent per distribution, they are also independent from your Windows 10 user account.

    The default user for a WSL distro is the run the WSL distro.

    You can set the default user for a WSL distro to root (aka: built-in Administrator) or any available user for that WSL distro.

    See also: Linux User Account and Permissions | Microsoft Docs

    This tutorial will show you how to set a default user for a Windows Subsystem for Linux (WSL) distro in Windows 10.


    CONTENTS:
    • Option One: Set Default User to Root for a WSL Distro
    • Option Two: Set Default User to Specified User for a WSL Distro

    EXAMPLE: Ubuntu distro with user "brink" set as the default user

    Set Default User for Windows Subsystem for Linux Distro in Windows 10 [​IMG]







    OPTION ONE [/i] Set Default User to Root for a WSL Distro
    1. Open a PowerShell.

    2. Copy and paste the command below into the command prompt or PowerShell for the .exe file of the WSL distro name (ex: "Ubuntu") you want to set the default user for, and press Enter. (see screenshot below)
    (Ubuntu)
    *Arrow ubuntu config --default-user root

    OR

    (Ubuntu 18.04 LTS)
    *Arrow ubuntu1804 config --default-user root

    OR

    (Ubuntu 16.04 LTS)
    *Arrow ubuntu1604 config --default-user root

    OR

    (openSUSE Leap 42)
    *Arrow openSUSE-42 config --default-user root

    OR

    (SUSE Linux)
    *Arrow SLES-12 config --default-user root

    OR

    (Debian)
    *Arrow debian config --default-user root

    OR

    (Kali Linux)
    *Arrow kali config --default-user root

    Set Default User for Windows Subsystem for Linux Distro in Windows 10 [​IMG]






    OPTION TWO [/i] Set Default User to Specified User for a WSL Distro
    1. Open a PowerShell.

    2. Type the command below into the command prompt or PowerShell for the .exe file of the WSL distro name (ex: "Ubuntu") you want to set the default user for, and press Enter. (see screenshot below)
    (Ubuntu)
    *Arrow ubuntu config --default-user <username>

    OR

    (Ubuntu 18.04 LTS)
    *Arrow ubuntu1804 config --default-user <username>

    OR

    (Ubuntu 16.04 LTS)
    *Arrow ubuntu1604 config --default-user <username>

    OR

    (openSUSE Leap 42)
    *Arrow openSUSE-42 config --default-user <username>

    OR

    (SUSE Linux)
    *Arrow SLES-12 config --default-user <username>

    OR

    (Debian)
    *Arrow debian config --default-user <username>

    OR

    (Kali Linux)
    *Arrow kali config --default-user <username>

    *note Substitute <username> in the command above with the actual UNIX user (ex: "brink") you want to be the default user for this WSL distro.

    For example: ubuntu config --default-user brink


    Set Default User for Windows Subsystem for Linux Distro in Windows 10 [​IMG]


    That's it,
    Shawn


    Related Tutorials

    :)
     
    Brink, Jun 6, 2018
    #1

  2. Windows Subsystem Linux

    Hello,

    We would like to know more about the issue you're experiencing with using
    Windows Subsystem for Linux
    . Kindly answer the following questions:

    • Are you developing a program, an app, or a software for Linux?
    • Is your Window 10 PC connected to a domain?
    • Are you managing a Windows Server PC?
    • What troubleshooting steps have you tried so far?
    • Can you tell us the Version and OS build of your Windows 10 device? You can find this information by clicking the
      Start button, type About your PC, and then press
      Enter.

    We need the following information in order to determine if we need to refer your concern to the
    TechNet forums or the Microsoft Developer Network (MSDN) forums.

    For now, we suggest reviewing these support articles to find out if there's an issue with the installation of
    Windows Subsystem for Linux:


    We'll be waiting for your response.
     
    Devlin Sco, Oct 27, 2019
    #2
  3. Brink Win User
    Sideloading Custom Linux Distro to Windows 10 Subsystem for Linux

    Source: Open Sourcing a WSL Sample for Linux Distribution Maintainers and Sideloading Custom Linux Distributions Windows Command Line Tools For Developers
     
    Brink, Oct 27, 2019
    #3
  4. Brink Win User

    Set Default User for Windows Subsystem for Linux Distro in Windows 10

    Sideloading Custom Linux Distro to Windows 10 Subsystem for Linux


    Source: Open Sourcing a WSL Sample for Linux Distribution Maintainers and Sideloading Custom Linux Distributions Windows Command Line Tools For Developers
     
    Brink, Oct 27, 2019
    #4
  5. Amit_Sun Win User
    Error 0x80070003 Windows Subsystem for Linux

    Hi,

    Thank you for writing to Microsoft Community Forums.

    This issue could occur when distros are not stored on your system driver or if your system is in lower build and also if Windows Subsystem for Linux is not enabled, you can follow the instruction from the article
    Windows Subsystem for Linux Installation Guide for Windows 10
    and check if this helps you.

    You can also Manually download Windows Subsystem for Linux distro packages
    and install it.

    If you need any further assistance, I suggest you to post your query on
    TechNet
    forums where you will find support engineers who are well equipped with the knowledge and help you fix the issue.

    Hope it helps,

    Amit Sunar

    Microsoft Community – Moderator
     
    Amit_Sun, Oct 27, 2019
    #5
  6. WINDOWS SUBSYSTEM FOR LINUX

    please help,

    how to clean remove windows subsystem for linux, i have already installed kali linux distro, and have many apps installed on it, which mean also already opening the port on laptop, now i want unistalled them all, included the apps. if i using "lxrun
    /uninstall" did also remove the apps on my linux and closed the port tho?

    need more infomation please.
     
    WAHYU CANDRA PUTRA, Oct 27, 2019
    #6
Thema:

Set Default User for Windows Subsystem for Linux Distro in Windows 10

Loading...
  1. Set Default User for Windows Subsystem for Linux Distro in Windows 10 - Similar Threads - Set Default User

  2. How to add users to WSL Distro (Windows Subsystem for Linux)

    in Windows 10 News
    How to add users to WSL Distro (Windows Subsystem for Linux): [ATTACH] [ATTACH]WSL or Windows Subsystem for Linux for Windows 10 support multiuser capabilities. And when it comes to user management for software, various aspects of software management can be discussed. Adding a user to the Windows Subsystem for Linux on Windows [...]...
  3. Remove User from Windows Subsystem for Linux WSL Distro in Windows 10

    in Windows 10 Tutorials
    Remove User from Windows Subsystem for Linux WSL Distro in Windows 10: How to: Remove User from Windows Subsystem for Linux WSL Distro in Windows 10 How to Remove User from Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux...
  4. Switch User in Windows Subsystem for Linux (WSL) Distro in Windows 10

    in Windows 10 Tutorials
    Switch User in Windows Subsystem for Linux (WSL) Distro in Windows 10: How to: Switch User in Windows Subsystem for Linux (WSL) Distro in Windows 10 How to Switch User in Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line...
  5. List Users in Windows Subsystem for Linux (WSL) Distro in Windows 10

    in Windows 10 Tutorials
    List Users in Windows Subsystem for Linux (WSL) Distro in Windows 10: How to: List Users in Windows Subsystem for Linux (WSL) Distro in Windows 10 How to List Users in Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line...
  6. Add User to Windows Subsystem for Linux (WSL) Distro in Windows 10

    in Windows 10 Tutorials
    Add User to Windows Subsystem for Linux (WSL) Distro in Windows 10: How to: Add User to Windows Subsystem for Linux (WSL) Distro in Windows 10 How to Add User to Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line tools...
  7. Unregister Windows Subsystem for Linux (WSL) Distro in Windows 10

    in Windows 10 Tutorials
    Unregister Windows Subsystem for Linux (WSL) Distro in Windows 10: How to: Unregister Windows Subsystem for Linux (WSL) Distro in Windows 10 How to Unregister and Reset Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux...
  8. Install Windows Subsystem for Linux (WSL) Distros in Windows 10

    in Windows 10 Tutorials
    Install Windows Subsystem for Linux (WSL) Distros in Windows 10: How to: Install Windows Subsystem for Linux (WSL) Distros in Windows 10 How to Install Windows Subsystem for Linux (WSL) Distros in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line tools...
  9. Set Default Windows Subsystem for Linux (WSL) Distro in Windows 10

    in Windows 10 Tutorials
    Set Default Windows Subsystem for Linux (WSL) Distro in Windows 10: How to: Set Default Windows Subsystem for Linux (WSL) Distro in Windows 10 How to Set Default Windows Subsystem for Linux (WSL) Distro in Windows 10 The Windows Subsystem for Linux (WSL) is a new Windows 10 feature that enables you to run native Linux command-line tools...
  10. Sideloading Custom Linux Distro to Windows 10 Subsystem for Linux

    in Windows 10 News
    Sideloading Custom Linux Distro to Windows 10 Subsystem for Linux: We are happy to announce that we have open sourced a WSL (Windows Subsystem for Linux) sample for Linux distribution maintainers. This sample allows distro maintainers to build WSL distro packages for the Microsoft Store and developers to create custom Linux distro packages...