sampasswd command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
sampasswd: command not found
or when using sudo you get the following error message
sudo: sampasswd: command not found
Solutions to sampasswd: command not found
How To Fix sampasswd: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu sampasswd is provided by chntpw package.
chntpw is:
This little program provides a way to view information and change user passwords in a Windows NT/2000 user database file. Old passwords need not be known since they are overwritten. In addition it also contains a simple registry editor (same size data writes) and an hex-editor which enables you to fiddle around with bits and bytes in the file as you wish.
If you want GNU/Linux bootdisks for offline password recovery you can add this utility to custom image disks or use those provided at the tools homepage.
To fix this problem, we can install more using the command below.
sudo apt-get -y install chntpw
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install chntpw.
sudo apt -y install chntpw
Or if you have aptitude installed you can use the following command.
sudo aptitude install chntpw
Summary
In this tutorial we learn how to fix sampasswd command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.