passwd

change user password 

Command


SYNOPSIS

passwd [-S hostname | -D domain-name] [user-name]


DESCRIPTION

The passwd utility changes the password belonging to user-name. Normally, passwd prompts you for the new password and then asks you to confirm it by entering it again.

When you do not specify user-name, passwd assumes that you are attempting to change your own password and first prompts you for your current password before requesting the new one. You are also prompted for your current password if user-name is the name under which you are currently logged in.

When you do specify a user-name other than your current login name, passwd requires that you have administrator privileges for the appropriate system (that is, hostname if you specify -S, the primary domain controller of domain-name if you specify -D, or the local system if you specify neither -D nor -S). In this case, passwd does not prompt you for the current password before requesting the new one. This allows an administrator to assign a user a new password without needing to know the current one.

If the rshd service or the mksauth service is currently running on your system, the password in the LSA database is also updated.

Options

-D domain-name 

locates the primary domain controller for the specified domain-name and changes the specified user's password on that system. Omitting user-name or specifying your current user name lets you change your password on the primary domain controller. This works only when your user name on that system is the same as your current user name on the local system.

-p new_password 

specifies the new password. When this option is specified, you are not prompted to enter the new password.

-S hostname 

specifies the remote system on which to change the specified user's password. Omitting user-name or specifying your current user name lets you change your password on a remote system. This works only when your user name on that system is the same as your current user name on the local system.


DIAGNOSTICS

Possible exit status values are:

0 

Successful completion.

>0 

An error occurred.


PORTABILITY

All UNIX systems. Windows 10. Windows Server 2016. Windows Server 2019. Windows 11. Windows Server 2022. Windows Server 2025.


AVAILABILITY

PTC MKS Toolkit for Power Users
PTC MKS Toolkit for System Administrators
PTC MKS Toolkit for Developers
PTC MKS Toolkit for Interoperability
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


PTC MKS Toolkit 10.5 Documentation Build 40.