The last time when I used Kali Linux, I was logging with the root user. Now it has been changed, I log in with a normal user. I don't know the root password. How will I get a root password
In order to run a command with root privileges in Kali Linux preface that command with sudo
and authenticate by entering your user password. Your user password in Kali Linux is the same as the password that you use to login to your normal user account with.
If that doesn't work and you have forgotten your user password, then you need to reset your lost administrative password. You need to authenticate with your administrative password in order to add your normal Kali Linux user to the sudo
group as a sudo
user.
Immediately after the BIOS/UEFI splash screen during boot, with BIOS, quickly press and hold the Shift key, which will bring up a GNU GRUB menu screen. With UEFI press (perhaps several times) the Esc key to get to the GNU GRUB menu screen. Sometimes the manufacturer's splash screen is a part of the Windows bootloader, so when you power up the machine it goes straight to the GNU GRUB menu screen, and then pressing Shift is unnecessary.
The timing when to press the Shift or Esc key can be tricky, so sometimes if you miss it you need to try it again. If that doesn't work try the answers to I can't get the GRUB menu to show up during boot.
You will see a GNU GRUB menu screen that looks like this. Select Advanced options for Kali GNU/Linux and press Enter.
A new blue screen will appear showing a list of kernels, which includes options of booting the kernels normally or in recovery mode.
Press the down arrow key until you select the 2nd entry from the top (the one with the recovery mode in the description) and then press Enter twice.
Now you should see this recovery menu. From the Recovery Menu screen, use the arrow keys scroll down to root Drop to root shell prompt and then press Enter.
You'll see a root prompt, something like this: root@kali:~#
. Remount it with write permissions:
mount -rw -o remount /
To reset the password, type passwd username
where you replace username
with the username you use to login with.
You'll be prompted to type a new password. When you type the password you will get no visual response acknowledging your typing to prevent other people from seeing your password as you type it. Type your new password and press Enter.
You'll be prompted to type your new password again as a check to make sure that you have typed it correctly. Type your new password again and press Enter.
You will see a message that says: passwd: password updated successfully
showing that your password has been successfully reset. If Kali Linux is installed on an SSD, type sync
to force changed blocks to disk and update the super block.
Type exit
to return to the recovery menu.
From the Recovery Menu select resume Resume normal boot
to resume booting normally.
이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.
침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제
몇 마디 만하겠습니다