To add a new user with username “john” and password “password”: Linux Commands – Overview with Examples and FAQs

Introduction

Welcome to the world of Linux! In this tutorial, we will be discussing how to add a new user with username “john” and password “password” using the Linux command line. Adding a new user is a simple process that requires only a few commands. We will be using the useradd command to create the new user, and the passwd command to set the password. Let’s get started!

Examples

useradd -m -p $(openssl passwd -1 password) john
[ad_1]

[ad_2]

If you want to add a new user with username “john” and password “password” on a Linux system, you can use the following command:

useradd -m -p $(openssl passwd -1 password) john

This command will create a new user with the username “john” and the password “password”. The -m flag will create a home directory for the user, and the -p flag will set the user’s password.

Jaspreet Singh Ghuman

Jaspreet Singh Ghuman

Jassweb.com/

Passionate Professional Blogger, Freelancer, WordPress Enthusiast, Digital Marketer, Web Developer, Server Operator, Networking Expert. Empowering online presence with diverse skills.

jassweb logo

Jassweb always keeps its services up-to-date with the latest trends in the market, providing its customers all over the world with high-end and easily extensible internet, intranet, and extranet products.

GSTIN is 03EGRPS4248R1ZD.

Contact
Jassweb, Rai Chak, Punjab, India. 143518
Item added to cart.
0 items - 0.00