How to create new user account in Windows bash

To create a user account in bash for Windows, follow the below steps:

  1. Open Bash application on your Windows: Go to Run, type bash
  2. Type the following command: # sudo adduser userName

    you would see the below output on the console,

    Adding user `c2c20' ...
    Adding new group `c2c20' (1002) ...
    Adding new user `c2c20' (1002) with group `c2c20' ...
    Creating home directory `/home/c2c20' ...
    Copying files from `/etc/skel' ...
    New password:   
  3. Set a New password
  4. You will be asked to RE-Enter the Password.
  5. You will be prompted to add,
    • Full Name []
    • Room Number []
    • Work Phone []
    • Home Phone []
    • Other[]
  6. You will be prompted to validate the details: Is the information correct? [Y/n]
  7. You will be taken back to the # prompt.

How to login to new user created?

# su userName

Copyright © Code2care 2024 | Privacy Policy | About Us | Contact Us | Sitemap