useradd creates an account. What appears besides the line in /etc/passwd depends on the options: without them this machine gives you neither a home directory nor the usual shell.
-m creates the home directory /home/name, -U creates a group with the same name, and -s sets the login shell. Without -s the shell becomes /bin/sh, and without -m there is no directory at all.
useradd sets no password. sudo passwd -S name prints the password state: a second field of P means there is a password, L means it is locked. A new account without a password shows L: password login is impossible until sudo passwd name sets one.
Create the intern's account
Create the labuser account: home directory /home/labuser, its own labuser group, and the /bin/bash login shell. Do not set a password.
Goals · 0 of 2
- Create labuser with its own group and the /bin/bash shell not done yet
- Create the home directory /home/labuser not done yet