Table of Contents
Forgetting your Debian 13 password can be stressful, but the good news is that you can reset it safely using Recovery Mode without reinstalling the operating system. This guide explains the process step by step in a simple and clear way, even for beginners.
STEP 1: Reboot and Open the GRUB Menu
To start the password reset process, you must access the GRUB boot menu, which allows you to enter recovery mode.As the system starts, press and hold Shift (BIOS) or tap Esc (UEFI) until the GRUB menu appears.
reboot
STEP 2: Enter Recovery Mode
In this step, you will boot Debian 13 into Recovery Mode, which allows you to access a root shell and reset the forgotten password safely without reinstalling the system.
# If the root filesystem is mounted as read-only, remount it as writable
mount -o remount,rw /
STEP 3: Drop to Root Shell
This step allows you to access a root shell with full administrative privileges, which is required to reset the forgotten password on Debian 13 safely and effectively without logging into a normal user session.
mount -o remount,rw /
STEP 4: Remount the Filesystem as Read/Write
By default, the system is mounted as read-only in recovery mode, so you must change it before editing passwords.This command allows system changes, including password resets.
mount -o remount,rw /
STEP 5: Reset the User Password
Replace username with your actual Debian username, then enter and confirm the new password when prompted.
Now you can reset the password for any user account.
passwd username
STEP 6: Fix Home Directory Permissions (Recommended)
After resetting the password, fixing ownership permissions helps prevent login or desktop issues.This ensures the user fully owns their home directory.
chown -R username:username /home/username
STEP 7: Reboot the System
Once all changes are applied, reboot your system to ensure that the new password and any permission updates take effect, allowing you to safely log in.
reboot
STEP 8: Log In with the New Password
After rebooting, log in using your newly set password. Your Debian 13 system should now work normally without any data loss.
# Enter your username and the new password at the login prompt
login: your_username
Password: your_new_password
