OpenBSD: Change Password

by on December 6, 2009 · 1 comment· LAST UPDATED December 6, 2010


How do I change root user or any other user account password under OpenBSD operating systems?

You need to use the passwd command. It can changes the user's local password stored in /etc/master.passwd file, Kerberos, or YP password. A root user can change any users password. Normal user can only change their own password.

Task: OpenBSD Change root User Password

Login as root user and enter:
# passwd

Task: OpenBSD Change Other User Account Password

Login as root user and enter:
# passwd {userName}
To change the password for tom user account, enter:
# passwd tom

Task: OpenBSD Change Your Own Password

Simply type the passwd command:
$ passwd
First, the user is prompted for their current password. If the current password is correctly typed, a new password is requested. The new password must be entered twice to avoid typing errors.

Tweet itFacebook itG+ itDownload PDF versionFound an error/typo on this page?

{ 1 comment… read it below or add one }

1 Brett January 27, 2015 at 8:06 pm

What about changing the user to root? How do you change to the root user without logging out?


Leave a Comment

Tagged as: , ,

Previous Faq:

Next Faq: