Configuring a User Account
This section describes how to log in with a root account and configure a new user account. You can configure an account for your own use or create a test account.
To configure a user account on the router:
The prompt in brackets (
[edit]), also known as a banner, shows that you are in configuration edit mode, at the top of the hierarchy.
- Change to the
[edit system login]section of the configuration:[edit]root@host#edit system login[edit system login]root@host#The prompt in brackets changes to
[edit system login]to show you are at a new level in the hierarchy.This example adds an account
nchen(for Nathan Chen), but you can use any account name.
- Configure a full name for the account. If the name includes spaces, enclose the entire name in quotation marks (" "):
[edit system login user nchen]root@host#set full-name "Nathan Chen"- Configure an account class. The account class sets the user access privileges for the account.
[edit system login user nchen]root@host#set class super-user- Configure an authentication method and password for the account:
[edit system login user nchenroot@host#set authentication plain-text-passwordNew password:Retype new password:When the new password prompt appears, enter a clear-text password that the system will encrypt, and then confirm the new password.
Configuration changes are not activated until you commit the configuration. If the commit is successful, a
commit completemessage appears.
- Return to the top level of the configuration, and then exit:
[edit system login user nchen]root@host#top[edit]root@host#exitExiting configuration mode- Log out of the router:
root@host>exit% logout Connection closed.- To test your changes, log back in with the user account and password you just configured:
>login:nchenPassword:<password>--- JUNOS 8.2-R1.1 built 2005-12-15 22:42:19 UTCnchen@host>When you log in, you should see the new username at the command prompt.
Congratulations! You have successfully used the CLI to view router status and perform a simple configuration change. Now you are ready to learn more about the CLI. See the remaining chapters of this book for details.
Alternatively, you can follow the instructions in Configuring a Routing Protocol to create a more extensive configuration.
NOTE: For complete information about the commands to issue to configure your router, including examples, see the JUNOS software configuration guides.