By Leo Antony Raj, Senior Trainer, Systech Group 20+ years in networking and cybersecurity · Updated October 2026.
6 Min read
In short
To reset a forgotten password in Kali Linux, restart the computer, open the GRUB boot menu, edit the Kali Linux boot entry and add the appropriate temporary-shell parameter, such as init=/bin/bash. Boot into the shell, make the root filesystem writable, run passwd USERNAME to set a new password and restart the system normally.
This method works on many conventional GRUB-based installations, but the exact procedure can vary depending on the boot configuration, filesystem and security settings.
Table of Contents
Introduction
Kali Linux is a Debian-based Linux distribution widely used for penetration testing, digital forensics, security research and cybersecurity training. It includes tools for network analysis, vulnerability assessment, password auditing and security testing.
However, even experienced users can forget their login password. This can happen when using Kali Linux in VirtualBox, VMware, a dual-boot system or a dedicated computer.
If you have forgotten your Kali Linux password, you do not necessarily need to reinstall the operating system. In many cases, you can regain access by using the GRUB boot menu to start a temporary root shell and reset your local account password.
This guide explains how to reset a forgotten Kali Linux password, understand the commands involved, troubleshoot common errors and prevent similar problems in the future.
If you want to understand Linux commands, user permissions and system recovery in greater detail, explore our Linux course in Chennai to build practical Linux administration skills.
Why can't you log in to Kali Linux?
There are several reasons why you may be unable to access your Kali Linux system.
Forgotten user password: You cannot remember the password created during installation.
Incorrect username: You are entering the wrong account name at the login screen.
Root password confusion: You are trying to use a root password when your system uses a regular user account.
Keyboard layout issues: Special characters may be entered differently because the keyboard layout has changed.
Encrypted disk: The system asks for a disk passphrase before it reaches the normal login screen.
Before resetting your password, identify which problem you are facing. The recovery method described below is intended for a local account on a system you own or are authorised to administer.
What should you check before resetting the password?
Before following the recovery procedure, check these points.
Make sure you can access the computer directly or open its virtual machine console.
If you use VirtualBox or VMware, keep the virtual machine window active during startup.
If your virtual machine contains important work, take a snapshot or backup if possible.
If Kali Linux uses full-disk encryption, make sure you have the required encryption passphrase or recovery key.
Confirm that you are resetting the correct local account.
Important: A Kali Linux login password and a disk-encryption passphrase serve different purposes. Resetting the login password will not unlock a disk that requires an encryption passphrase.
Method 1: Reset a forgotten Kali Linux password using GRUB
This method is useful when you cannot log in to your local Kali Linux account but can access the machine’s boot menu.
Step 1: Restart Kali Linux
Restart your computer or virtual machine.
During startup, open the GRUB boot menu. Depending on your system’s firmware and boot configuration, you may need to hold Shift or press Esc at the appropriate time.
Select the Kali Linux boot entry.
If the menu does not appear, check your virtual machine’s boot settings or consult the documentation for your system.
Step 2: Open the GRUB editor
With the Kali Linux entry selected, press: e
This opens the boot-entry editor.
You will see several lines containing startup settings. Find the line that begins with linux. It normally contains the kernel path and other boot parameters.
Do not change unrelated boot settings.
Step 3: Start a temporary root shell
For an authorised local recovery, edit the Linux boot line so the system starts a temporary shell instead of the normal login process.
On a typical GRUB-based Kali installation, the relevant parameters are: rw init=/bin/bash
Replace the existing ro parameter with rw where appropriate, and add init=/bin/bash to the same Linux kernel line. Preserve the other required kernel parameters.
Press Ctrl + X or F10 to boot the edited entry. The available key may depend on the boot environment.
What does this do?
rwrequests read-write access to the root filesystem.init=/bin/bashstarts a Bash shell as the initial process instead of the usual system startup process.
This gives an administrator with local console access a temporary shell for account recovery. The exact behaviour can vary with the Kali installation and its security configuration.
Step 4: Identify your user account
If you do not remember your username, list the home directories: ls /home
These names are examples. Your system may show a different username.
The directory name often matches the local account name. Confirm the correct account before changing its password.
Step 5: Remount the filesystem as writable
Run: mount -o remount,rw /
Why is this command important?
The root filesystem may be mounted as read-only during recovery. The password change needs to update the system’s account database, so the filesystem must allow writes.
The command requests read-write access to the root filesystem mounted at /.
Step 6: Reset the user password
Run the following command, replacing USERNAME with the actual account name: passwd USERNAME
Enter the new password when prompted, then enter it again to confirm.
Linux does not display characters while you type a password. This is normal and does not mean the keyboard is unresponsive.
If the password update succeeds, you should see a confirmation similar to: passwd: password updated successfully
Step 7: Save the changes and restart Kali Linux
Run: sync
exec /sbin/init
The sync command requests that pending filesystem changes be written to storage. The second command attempts to continue normal system startup.
If the system does not restart normally, use the virtual machine’s restart controls or restart the physical computer. Then allow Kali Linux to boot normally.
Step 8: Test the new password
At the normal Kali Linux login screen:
Enter the correct username.
Type the new password.
Confirm that you can access the desktop.
Open a terminal and verify that your account works as expected.
If the login still fails, check the username, keyboard layout and whether you reset the correct account.
Method 2: Change your password when you can still log in
If you can log in to Kali Linux and remember your current password, you do not need GRUB recovery.
Open a terminal and run: passwd
Enter your current password, followed by your new password twice.
If you have access to another administrator account, you may also be able to reset a local user’s password using: sudo passwd USERNAME
Replace USERNAME with the correct local account name.
These commands have different requirements: passwd changes the password of the current account, while sudo passwd USERNAME requires suitable administrative privileges.
For more information about privilege management, refer to the official Kali Linux documentation on sudo
Method 3: Reset the Kali Linux Root Password
The root account is the superuser account in Linux. It has broad administrative privileges, including the ability to modify system configuration and manage other users.
However, your normal Kali Linux login password is not necessarily the root password.
If you can log in to a regular account with suitable administrative privileges and want to set or change the root password, run:
sudo passwd rootFollow the prompts to enter and confirm the new root password.
If you are locked out of your regular account, use an authorised recovery method and make sure you select the account that actually needs its password reset.
For routine administration, using a regular account with sudo is generally preferable to performing every task as root.
Is the Default Kali Linux Password Still kali?
Not for every installation.
Kali Linux has used a non-root user policy by default since version 2020.1. A standard installation prompts the user to create an account, while certain live images and pre-created images may use default credentials.
Some of these images use kali as both the username and password. However, these credentials should not be assumed to work on every installed system.
If you use a pre-created image, check the official Kali Linux documentation on default credentials before attempting recovery.
If you previously changed the default password and forgot it, the default credentials will not normally restore access.
Common Kali Linux password-reset problems and solutions
The following table covers problems that may occur during recovery.
If an error persists, avoid making random changes to system files. Check the exact error message and the filesystem state before attempting another recovery.
How to Fix an Authentication Token Manipulation Error
This error can occur when Linux cannot update the account’s password information.
Possible causes include a read-only filesystem, an account database problem or another system-specific restriction.
Start by checking the mounted filesystems: mount
Determine whether the root filesystem allows writes, then review the full error message.
Avoid deleting or manually replacing etc,passwd or etc,shadow as a first response. Incorrect changes to these files can prevent accounts from working correctly.
What If Kali Linux Boots Into a Black Screen?
A black screen after editing GRUB does not necessarily mean that the operating system has been damaged.
A temporary root shell does not normally start the graphical desktop, so the display may look different from the regular Kali Linux environment.
If you cannot continue, restart the machine and select the normal Kali Linux boot entry. If the problem persists, investigate the boot configuration and any errors displayed during startup.
What If You Cannot Access GRUB?
Some systems hide the boot menu or use a bootloader configuration that makes manual editing unavailable.
Check the documentation for your firmware and installation. In a virtual machine, make sure the console receives keyboard input during startup.
If bootloader access is restricted by a security policy, use the authorised recovery method supported by the system.
Understanding these boot settings is an important part of Linux troubleshooting. Readers who want to develop their practical administration skills can explore our Linux system administration training in Chennai, which is relevant to learning Linux commands, permissions and system management.
How Kali Linux Password Recovery Connects to Cybersecurity
Password recovery is not just about changing a forgotten password. It also demonstrates how Linux handles users, administrative permissions, boot processes and protected system files.
For example, the passwd command updates account credentials, while GRUB controls which boot parameters are passed to the kernel. Understanding these components helps administrators troubleshoot access problems and maintain Linux systems.
Kali Linux is also widely used in authorised cybersecurity labs to practise network scanning, vulnerability assessment and security testing.
Students who want to practise these tools in structured learning environments can explore our cybersecurity course in Chennai, which connects Linux knowledge with networking and cybersecurity fundamentals.
These skills are useful for learners who want to understand not only how to use security tools but also how the operating systems behind those tools work.
Not sure which route fits you?
Tell us your stream and what you are hoping for, and we will tell you honestly which option suits.
Get course detailsHow Can You Prevent Future Kali Linux Password Problems?
Once you regain access, follow these practices to reduce the chance of being locked out again.
Use a password manager: Store your account credentials securely rather than relying on memory alone.
Back up important files: Keep copies of scripts, projects, configuration files and other important work.
Protect virtual machines: Take snapshots or backups before making major configuration changes, where supported.
Keep encryption recovery information safe: Store recovery keys separately from the encrypted device.
Use administrator privileges carefully: A regular user account with sudo is suitable for most routine administrative tasks.
Understand the recovery process: Learn how Linux users, filesystems, permissions and bootloaders work so that you can troubleshoot similar problems in the future.
For broader technical learning, our hardware and networking course in Chennai is another relevant resource for understanding operating systems, network fundamentals and troubleshooting.
Conclusion
Forgetting your Kali Linux password can prevent you from accessing your system, but reinstalling the operating system is not always necessary. By identifying the correct account, understanding the boot process and using an appropriate recovery method, you can often reset the local password and regain access.
The most important steps are to verify the username, ensure the filesystem permits password changes, use the passwd command correctly and distinguish login credentials from disk-encryption passphrases.
Learning Linux administration and cybersecurity fundamentals can also help you understand why these recovery methods work and how to troubleshoot similar problems. Explore the relevant training resources from Systech Group to continue developing your technical knowledge.
Frequently asked questions
Can I reset a forgotten Kali Linux password without reinstalling it?
Yes. If you own or administer the system and can access its boot menu or another authorised recovery method, you can often reset the local account password without reinstalling Kali Linux.
Can I reset a Kali Linux password from the terminal?
Yes. If you can log in, run passwd to change your current account’s password. An administrator can use sudo passwd USERNAME to reset another local account when they have the required permissions.
Does resetting my Kali Linux password delete my files?
A normal local account password reset does not ordinarily delete your personal files. However, mistakes during recovery, disk damage or encryption-related issues can create risks, so back up important data whenever possible.
Why does the terminal not show anything when I type a password?
Linux normally hides password input in the terminal for privacy. Your keystrokes are still being received even though no characters appear on the screen.
Is the root password the same as the Kali Linux user password?
Not necessarily. The root password belongs to the superuser account, while the regular user password belongs to your normal account. Modern Kali Linux installations use a regular user account by default.
Can I reset the password of an encrypted Kali Linux system?
You may be able to reset the local account password after unlocking and accessing the encrypted installation. However, a password reset cannot replace a missing full-disk encryption passphrase or recovery key.
Why does Kali Linux not show the password while I type?
Linux normally hides password input in the terminal for privacy. Your keystrokes are still being received even though no letters, dots or asterisks appear.
What is the difference between the root password and the user password in Kali Linux?
The user password belongs to your normal account. The root password belongs to the system’s superuser account. Modern Kali Linux installations use a regular user with administrative privileges by default, so the two passwords are not necessarily the same.
What should I do if the new password still does not work?
Confirm that you reset the correct account, check the keyboard layout and review any errors reported by passwd. If the problem continues, investigate the account configuration instead of repeatedly changing system files.
Can I reset another user's password in Kali Linux?
Yes, if you have the necessary administrative privileges. Use sudo passwd USERNAME from an authorised administrator account, replacing USERNAME with the correct local account name.
Written by
Leo Antony Raj
Senior Trainer · Networking, Cyber Security and Cloud
Leo Antony Raj has over 20 years of hands-on experience in hardware, networking, server configuration, ethical hacking and cloud computing. He has trained more than 10,000 students, and he teaches networking first, because every security and cloud role is built on it.