Hardened installations which prevent interacting with GRUB, the bootloader, are not included, especially, as that can be used maliciously to access systems illicitly.
Since I have been away from Debian for several years, I did mix some things up. This is why I am re-writing the how-to for the benefit of all.
Method A (Using GRUB):
- Turn on the computer.
- While GRUB displays its screen, press 'e'.
- Edit the kernel line to include at the end: "init=/bin/dash" or your shell of preference but make sure it exists in the installation to be booted.
- Press F10 to boot.
- You will be presented a dreaded terminal. In that terminal you have root preveleges.
- Since you have root privileges, you should be able to use passwd to change the root password.
- Run the command and follow the prompts.
Method B (Using chroot):
- Boot a Live CD on the computer you need to work on.
- Open a terminal and become root.
- Mount the root file system of the target installation.
- Use chroot to become root on the target installation. If the mounted file system is mounted on /mnt/sda1, the command will be "chroot /mnt/sda1 /bin/bash". You may need to use another shell emulator. Make sure you use one that exists on the the target installation.
- Use passwd to change the root password on the target installation.
- Exit the chroot with "exit" and unmount the target installation's root file system.
- Exit the Live Linux CD.