New account requires root account or sudo permissions, sudo configuration saved in/etc/sudoers file.
Create an account using the/usr/sbin/useradd command, it is best to use absolute path, because different creation account command parameter format slightly different.
/usr/sbin/useradd-c koala-d/opt/code/home/koala 9013
-d:home Directory
-G: Main owning Group
-G: Other owning Group
-M: Create home Directory
-u:userid
The last koala on behalf of the user name, after creation and then set a password for the account:
/USR/BIN/PASSWD Koala
Once created, the Koala account information can be found in the/etc/passwd file. However, the new account cannot be accessed by SSH by default, then SSH login is required for external access.
Insert Configuration statement:
Allowusers:koala
If you want all users to have access, direct:
Allowusers *
After these steps, you can login to the Koala account directly via SSH.
SSH [email protected]
However, each login need to enter a password, more cumbersome, a login password-free tips:
Under the created Koala account, enter the ~/.ssh directory (if one is not created),
Create a new Authorized_keys file to write the public key information for the remote account that needs to log in to koala. That is, join is to log in to the Koala account from the test account of another machine (IP assumed to be 192.168.66.60),
The test account under the ~/.ssh directory has two files Id_rsa and id_rsa.pub, respectively, represents the private key and the public key, the contents of the id_rsa.pub copied into the koala account under the ~/.ssh/authorized_keys file.
In this way, every time you log into the Koala account from the test account, you do not need to enter a password.
Linux new account, and open SSH login