Table of Contents
ToC

ToC5. Account management

These are administrative commands which affect your account, status, or rights.

Up to start of section5.1. Changing password

Passwords should be changed at irregular (unguessable) intervals. Never use short or guessable passwords: the best advice is here.

Type the  passwd  command. It will ask for your existing password first, to make sure it really is you and not someone borrowing your account; and it will then ask for a new password, and then ask you to repeat the new password:

$ passwd
Changing password for ontology
(current) UNIX password:         
New UNIX password:         
Repeat new UNIX password:         
$

The password is not shown as you type, not even with asterisks or bullets, so take care (that underlining is just to show in this example you where you type: the underlining does not actually appear when you type the password). If you get the repeat wrong, it will ask for the new password again. You can abort the process and leave the password unchanged by typing a Ctrl+D twice.

Up to start of section5.2. Finding out how long before your password expires

Passwords usually have a fixed lifetime, determined by your systems administrator. You can find out how long your password has left before it expires with the  chage  command:

Type the  chage  command with the -l option (a lowercase ell) and your account name:

$ chage -l ontology
Last password change					: Nov 10, 2011
Password expires					: Mar 22, 2012
Password inactive					: Dec 31, 2012
Account expires						: Dec 31, 2099
Minimum number of days between password change		: 10
Maximum number of days between password change		: 90
Number of days of warning before password expires	: 10, 5/4/3/2/1
$

Changing your password at unpredictable intervals is a good contribution to account security.

Table of Contents
ToC
RSS newsfeedKeep up to date with our RSS newsfeed