Тёмный

How To Reset The Root Password On Ubuntu 22.04 LTS If Forgotten (Linux) 

ProgrammingKnowledge
Подписаться 1,8 млн
Просмотров 125 тыс.
50% 1

If you have forgotten the root password on Ubuntu 22.04 and need to reset it, you can follow these steps:
1. Start by rebooting your Ubuntu system. When the GRUB bootloader menu appears, select the default Ubuntu entry, but do not press Enter. Instead, press the 'e' key to edit the boot options.
2. In the boot options, locate the line that starts with `linux`. At the end of this line, append `init=/bin/bash` to specify that you want to start a bash shell as the init process.
3. Press `Ctrl + X` or `F10` to boot into the modified boot options. This will start a bash shell with root privileges.
4. Once the bash shell is loaded, you will be at a root prompt (`#`). Enter the following command to remount the root filesystem in read/write mode:
```
mount -o remount,rw /
```
5. Now, you can reset the root password by entering the following command:
```
passwd root
```
You will be prompted to enter a new password for the root user. Enter the password and confirm it.
6. After successfully resetting the root password, remount the root filesystem in read-only mode using the following command:
```
mount -o remount,ro /
```
7. Finally, reboot your system by entering the following command:
```
reboot
```
Upon reboot, you will be able to log in as the root user using the new password you set.
Please note that resetting the root password should be done with caution and only when necessary. Make sure to keep your root password secure and remember it to avoid any potential security risks.
#Ubuntu #RootPassword #PasswordReset #SystemAdministration #Linux

Опубликовано:

 

2 июл 2023

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 157   
@BrewmasterN8
@BrewmasterN8 10 месяцев назад
I cant believe that actually worked...nothing usually works when I try it...😂 thank you very much
@janeb9986
@janeb9986 10 месяцев назад
Finally!!!! Something that worked!!! Thank you ❤❤❤❤❤ they kept saying press shift but that didn’t work for me. I’m so glad I found your video
@rok.cernetic
@rok.cernetic 2 месяца назад
I i use this method and reset password will everything else stay the same such as files and apps?
@rohitkumarchoudhary
@rohitkumarchoudhary 10 месяцев назад
ASKING FOR ROOT PASSWRD FOR MAINTAINANCE
@mirko1504
@mirko1504 9 месяцев назад
Thank you. It works perfectly. Short and clear instructions ❤
@abhiramsv5694
@abhiramsv5694 4 месяца назад
Thankyou brother,It worked.I did lot of method by watching other youtubers but this one only worked.❤
@southpaw0905
@southpaw0905 10 месяцев назад
Perfect video! It worked. I recommend this method to anyone who is trying to recover the password. Thanks!
@q.u.e.r.t.y
@q.u.e.r.t.y 10 месяцев назад
The title is kinda misleading. It says "how to reset *root* password" but it's Actually how to reset normal user password. Because clicking on the root option requests you to enter a root password if you set one, in your case you did not that's why it just let you in. In my case I lost both user and root password and I need root password to access the root she'll
@robertjkilgore
@robertjkilgore 7 месяцев назад
Same problem here what did you do?
@q.u.e.r.t.y
@q.u.e.r.t.y 7 месяцев назад
​@@robertjkilgore I just gave up and just re-installed. It was near the right time I should do a re-install anyway as it has became tradition for me to reinstall my OS after every year. If you forgot user login (not just root) and therefore you can't log into the computer but you have important files that you want to get before re-installing, I believe you can open a live Ubuntu (can do it while re-installing) and mount the partition where the data is and copy the stuff you want and reinstall. There's definitely a way to get root from a normal user without password, for example I know of some root-escalation projects you could curl but won't give links for ethical reasons but if you're desperate you can look it up.
@bobbo2576
@bobbo2576 7 месяцев назад
I know my root pass but it says user doesn’t exist when I try to change password
@q.u.e.r.t.y
@q.u.e.r.t.y 7 месяцев назад
​@@bobbo2576 I don't think an error message would lie to you, so if it says the user does not exists then it means you wanted to change password but mentioned a user that does not exist 🤷 Seems it's you that used the command wrong. Would have helped if you gave the exact command rather than just what it says but you probably wrote something like this *sudo passwd A_NON_EXISTENT_USER* You can see users that can login by seeing the files in your /home directory
@bobbo2576
@bobbo2576 7 месяцев назад
@@q.u.e.r.t.y well I figured it out. My user name was different than the login name.
@harleylange4451
@harleylange4451 Месяц назад
Your video is the only one that worked for me! Thank you! You are a rockstar!!!! 💪🏻
@uxxnavin234
@uxxnavin234 5 месяцев назад
It is useful for any version of ubuntu thank you your steps have worked.
@harrybrown4815
@harrybrown4815 9 месяцев назад
This does not work as it say give root password for maintenance.
@thesuinonick2179
@thesuinonick2179 5 месяцев назад
same, fuck it im just gonna reinstall it
@Enum_Dev
@Enum_Dev 3 месяца назад
The person making this video doesn't seem to know what root is. The actual easiest way to do this is getting a new USB with any Linux distro installed, opening a terminal, mounting your root partition using 'mount /dev/sdXA /mnt' X being the letter assigned to your drive and A the number of the partition (You can get this info by typing 'lsblk') then enter 'chroot /mnt'. You will now be logged into a terminal with your Ubuntu installation as root. Finally you can type 'passwd root' and set a new password from the chroot shell. Type 'exit' to leave chroot, close the terminal and reboot. There is technically another way to do this without a USB by adding a certain option in your Ubuntu grub entry. If you select the top entry in grub and press 'e' instead of enter you are able to edit the entry. You should be able to add the following 'init=/bin/bash' at the end of the line that starts with Linux and press F10 to boot but I've not personally tried this. There is not really much harm in trying this but do some research on init=/bin/bash first online. It should basically just drop you into a terminal instead of starting the default 'init system' on your machine and you can use the passwd command from there too
@jasongralding3222
@jasongralding3222 4 месяца назад
Hi, I have followed your video because I have forgotten my password. I am running Ubuntu 22.04.3 LTS on VirtualBox and I originally set it to auto-logon so I can get into the OS but many things are now unavailable to me because they ask for my password before proceeding. I did the Grub -> Recovery Mode -> process but in your video it just shows "Press Enter to..." whereas when I do it it askes for my Password to continue!! Can you suggest why my Ubuntu is working differently to yours and is there a way to reset the password without actually knowing what it is? Thanks PhilipJ
@joelekem3480
@joelekem3480 10 месяцев назад
guys please after selecting root, im not able to enter the maintenance mide and type the mount command
@austine_mario
@austine_mario Год назад
Thank you, it really helped
@samuelbhatti878
@samuelbhatti878 6 месяцев назад
Many thanks! It was very helpful.
@mohammedalahi1406
@mohammedalahi1406 2 месяца назад
Many Thanks Your explanation is very clear keep it up
@escanorsama7922
@escanorsama7922 Месяц назад
Hi, I'm using Proxmox and can't access the GRUB menu. I tried pressing Esc and shift and saw the following options: Virtio-scsi drive qemu qemu harddisk + IPXE (PCI 00:12.0) Legacy option ROM When I try to select any option, it just reboots directly. Any ideas? Thanks!
@Ninjaprotect
@Ninjaprotect Год назад
Bro help i cant t enter boot
@xTwisteDx
@xTwisteDx 6 месяцев назад
AMAZING tutorial. Thank you!
@user-hd5tv1ny3i
@user-hd5tv1ny3i 9 месяцев назад
Thank you, worked perfectly.
@pradipdhakal2665
@pradipdhakal2665 День назад
Thank you so much Boss It works 👍🏾
@Ohdatstima
@Ohdatstima Месяц назад
The only person who could explain well and easy ☺️ God bless you
@Way-to-Deen
@Way-to-Deen 8 месяцев назад
Thank you so much. It helped me a lot
@matilda9906
@matilda9906 3 месяца назад
When I try this, after I enter passwd and username, it gives me a whole menu list instead of offering to let me reset my password. What do I do?
@ZoroRorono-pq2iv
@ZoroRorono-pq2iv 9 месяцев назад
Thanks! It working
@rok.cernetic
@rok.cernetic 2 месяца назад
I i use this method and reset password will everything else stay the same such as files and apps?
@chamodkatugampala8530
@chamodkatugampala8530 9 месяцев назад
It worked ❤
@DadaCreative.
@DadaCreative. 4 месяца назад
Did you guys press shift and esc at same time? Mine is not working
@enriquep.zepeda9707
@enriquep.zepeda9707 Месяц назад
Worked excellent, thanks a lot!!!
@g.nehanthreddy5028
@g.nehanthreddy5028 2 месяца назад
Sir I have problem sir 😢😢😢 pls help me I did same process but it not showing password is successfully updated it telling password do not match Authentication token manipulation error
@purbashabanerjee
@purbashabanerjee Месяц назад
Thank you very much it worked!!
@aakashkumarverma1141
@aakashkumarverma1141 5 месяцев назад
when i press enter same cmd appears "press ctrl d to continue" help me
@PuchoWebSolutions
@PuchoWebSolutions 28 дней назад
Hello from New York City! Does your procedure work for LinuxMint also? Thank you.
@ralphmoreno2974
@ralphmoreno2974 4 месяца назад
You Sir are a Rockstar! Thank you!
@mahavirmahajan5035
@mahavirmahajan5035 9 месяцев назад
Not working its asking root password for maintenance its showing "Login Incorrect" any solution on this?
@user-zs3ti3lc4m
@user-zs3ti3lc4m 6 месяцев назад
SAME PROBLEM BUDDY??
@patiladitya7292
@patiladitya7292 5 месяцев назад
if you are using VMbox then "changeme" should work fine
@abduljunaid861
@abduljunaid861 3 месяца назад
​@@patiladitya7292what do you mean???
@abduljunaid861
@abduljunaid861 3 месяца назад
​@@patiladitya7292in detail....
@rajeshwarjadhav559
@rajeshwarjadhav559 5 месяцев назад
sir when i try pressing enter it shows me the incorrect password and the command terminal is not opening its a lab exersise by the way how to solve this sir
@arslanzulfiqar7793
@arslanzulfiqar7793 8 месяцев назад
Thanks dear its working❤
@F_khan1
@F_khan1 4 месяца назад
when i go to recovery mode it says give root password for maintenance . how to solve this .
@bolisettilakshman5710
@bolisettilakshman5710 10 месяцев назад
shift+esc is not working for me, how can i do that or is there any alternatives
@nox7638
@nox7638 10 месяцев назад
turn your computer on and hold shift at the same time it's starting
@Seven.Strike07
@Seven.Strike07 9 месяцев назад
Another way to click Esc button only one time
@Professor.Farnsworth
@Professor.Farnsworth 5 месяцев назад
Except on my server, it won't actually load the recovery mode menu. The terminal just.. hangs and yes, disable recovery mode is turned off in bios.
@faizahmed8015
@faizahmed8015 8 месяцев назад
Thank you ❤ Great 👍🏻
@tlumme
@tlumme Год назад
so this works only *when your physically at the machine* .. not over ssh or etc network boot? .. right? :)
@tlumme
@tlumme Год назад
could be with script but i know nothing of that .. :) others might know how .. :X
@isaacoppong3125
@isaacoppong3125 2 месяца назад
Very helpful. Many thanks
@keyurpurohit2371
@keyurpurohit2371 10 месяцев назад
If you forgot to add your user name after passwd, your password set for root don't worry just follow the same steps.. This time whenever you select root after pressing ENTER you have to enter the password you set just before otherwise it will show Login Incorrect! So now after entering the correct password enter the same commands, don't forget to add your username this time passwd
@remarkme535
@remarkme535 7 месяцев назад
Is it work in case of device having no windows
@justanotherwatcher
@justanotherwatcher 4 месяца назад
Brilliant I'm back in to my computer, many thanks
@azizbekusubaliev9964
@azizbekusubaliev9964 6 месяцев назад
Where is the root passwords reset? You show to reset passwd to other user.
@prekshasalvi8622
@prekshasalvi8622 4 месяца назад
Thanks a lot 😊
@TheIndianPolitico
@TheIndianPolitico 9 месяцев назад
When I am typing new password, I am unable to type. What can I do?
@fiestamoodvav9651
@fiestamoodvav9651 Месяц назад
it worked . good work !
@normalizedaudio2481
@normalizedaudio2481 Год назад
My mom locks the computer room.
@shrutikolhe1304
@shrutikolhe1304 7 месяцев назад
It's really helpful 😊
@iiitvadodara6387
@iiitvadodara6387 5 месяцев назад
Thank you very much, it works for me.......🤓🤓
@KodyWebb
@KodyWebb 9 месяцев назад
Thank you!!!!
@Linkolite
@Linkolite 10 месяцев назад
Thank you :)
@abuwilliams7228
@abuwilliams7228 2 месяца назад
Thank you so much
@sindhuns2960
@sindhuns2960 8 месяцев назад
Oh my god 😱 It actually worked Thank you very much 🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏
@hushmandi
@hushmandi 4 месяца назад
Thank you Bro. God bless You!!!
@sniperdepijama
@sniperdepijama 9 дней назад
wha rapend if not work word with comma ande passwd doesn t exist?
@sebastianmattar5379
@sebastianmattar5379 3 месяца назад
THANK YOU SO MUCH❤❤
@user-fz3yi9mn8s
@user-fz3yi9mn8s 5 месяцев назад
Thank Bhai
@AllinOne-vd9oy
@AllinOne-vd9oy Год назад
Thanks, It's work me
@rok.cernetic
@rok.cernetic 2 месяца назад
How can i change password for other not superusers without changing superuser password?
@shanteshhosmath526
@shanteshhosmath526 11 месяцев назад
at 3:22,When I click on root,it asks "Give root password for maintenance" but for you it is asking "Press enter for maintenance".What do I do?
@hanako6465
@hanako6465 11 месяцев назад
same ya
@pranavas3641
@pranavas3641 11 месяцев назад
Did you get any solution??
@shanteshhosmath526
@shanteshhosmath526 11 месяцев назад
@@pranavas3641 No
@tasnovashahrin5477
@tasnovashahrin5477 10 месяцев назад
Did you get any solution?(2)🙂
@hanako6465
@hanako6465 10 месяцев назад
I'd say fuck it and create the whole system again
@chase2910
@chase2910 8 месяцев назад
You rock, thank you
@jyotirmayapanigrahi4149
@jyotirmayapanigrahi4149 4 месяца назад
Many many thanks sir
@um9963
@um9963 Месяц назад
Worked. 😊
@user-xk2nf6hk9u
@user-xk2nf6hk9u 3 дня назад
Thank you.
@crauguns
@crauguns 3 месяца назад
Thank you brow. I am from Brazilian.
@Duminek-Qt2
@Duminek-Qt2 Месяц назад
Nice bro thanks
@Woityschreck
@Woityschreck 8 месяцев назад
thank u a lot help very much
@robibalazs6521
@robibalazs6521 9 месяцев назад
Thx, saved me ❤
@mogalagadiphahleng921
@mogalagadiphahleng921 2 часа назад
Thanks 🙏
@SaigangaUdayakumar
@SaigangaUdayakumar Месяц назад
Thanks bro
@jrmyrgd
@jrmyrgd 6 месяцев назад
thank you so muuuuuuuch!
@LupeLokota
@LupeLokota 6 месяцев назад
This worked partway: it changed my password and allowed me to log in to my user, however I'm immediately presented with a window saying that my log-in password no longer matches that of my login keyring and demanding the old password.
@esraylmaz49
@esraylmaz49 9 месяцев назад
It's not working bc command line does show up. System asks for root password and when you press enter it says Login Incorrect and asks again.
@DejeneSamuel
@DejeneSamuel 6 месяцев назад
the same is too
@1234567890000918
@1234567890000918 7 месяцев назад
Thank you
@salemdevian
@salemdevian 5 месяцев назад
I press enter,, it asks for password AGAIN!!!
@jmizzle11
@jmizzle11 11 месяцев назад
When I press Enter for maintenance, it responds with "Login Incorrect". What should I do?
@Infinite_Mainak
@Infinite_Mainak 11 месяцев назад
Same
@DejeneSamuel
@DejeneSamuel 6 месяцев назад
the same too
@Guyisgamer573
@Guyisgamer573 3 месяца назад
it dident let me type my new password can someone plz halp me
@_Raj_kumar_2
@_Raj_kumar_2 5 месяцев назад
3:27 , In mine after choosing the root and click Enter . I got something in bottom, Its asking root password for maintenance but yr case PRESS ENTER FOR MAINTENANCE!. Now what should i do sir??
@Strange2309
@Strange2309 5 месяцев назад
same bro, did you find any solution?
@_Raj_kumar_2
@_Raj_kumar_2 5 месяцев назад
No bro..if u find any solution..let me!!
@Strange2309
@Strange2309 5 месяцев назад
@@_Raj_kumar_2 i guess there is no solution after we change root password
@kedartanwer9296
@kedartanwer9296 11 месяцев назад
Thanks for password reset advised
@geethaab4943
@geethaab4943 5 месяцев назад
Thanku... It worked
@ItssMeeKaw
@ItssMeeKaw 6 месяцев назад
Tyvm
@bojukakt222
@bojukakt222 2 месяца назад
Mine says give root password for maintenance
@piyushtambe167
@piyushtambe167 4 месяца назад
Lovely bhaii 🥵
@373323
@373323 Год назад
also, many ubuntu systems disable root login, so resetting the root password is moot. you need to reset the other user's password, that has sudo privileges and not root , show them how to find the usernames ( other than the obviously disabled root ) and reset that password , also , if password login is disabled , this is not going to do anything
@lowfitimes
@lowfitimes 11 месяцев назад
Hi, I am facing this issue. Please could you share on what to do?Tha nks
@engineer9830
@engineer9830 4 месяца назад
Thankyou it worked
@373323
@373323 Год назад
you are running it on a windows, yukk
@raavn0007
@raavn0007 Месяц назад
it is showing me, give root password for maintenance
@syedmehranjameel2294
@syedmehranjameel2294 10 месяцев назад
Bro when I try to type new password the keys no working pls help
@Hustlerblancior
@Hustlerblancior 15 часов назад
Bro they invisible, they typing but u cant see them
@AKKHAN-w8c
@AKKHAN-w8c 13 дней назад
worked
@MrKingoverall
@MrKingoverall 5 месяцев назад
I love you man !!!! 👍👍😁😁❤️😭😭
@smorfnimda
@smorfnimda 3 месяца назад
IT's like Ubuntu changes the passwords on us wihtout our permission. hackers? What's the deal?
@ahmed8873
@ahmed8873 6 месяцев назад
Thanks Brother ❤❤❤
@user-rz8qu2yt9o
@user-rz8qu2yt9o 4 месяца назад
Thank you very much. It work😂
@vn_loc7316
@vn_loc7316 5 месяцев назад
This guide is to reset a user's password. After you logged into the user, you can use this command to reset root password. sudo passwd root
@ArielTVChannel
@ArielTVChannel 4 месяца назад
Incomplete tutorial, shift + esc was not work
@sahiltondale5578
@sahiltondale5578 8 месяцев назад
My keyboard is not working
@kinkpelionel3287
@kinkpelionel3287 7 месяцев назад
Thanks
Далее
60 Linux Commands you NEED to know (in 10 minutes)
10:50
Your Old PC is Your New Server
11:07
Просмотров 6 млн
What's going on with Windows Laptops?
10:30
Просмотров 766 тыс.
How to change forgotten Linux password
6:33
Просмотров 75 тыс.
Password Hacking in Kali Linux
24:22
Просмотров 775 тыс.
30 Windows Commands you CAN’T live without
14:35
Просмотров 2,2 млн
Reset Password On Any Linux Distro (No Root Needed)
13:12
How to Reset your Forgotten Password in Ubuntu 20.04?
3:23