Linux

how do i change the root password in Linux?
deklinmAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

pilson66Commented:
enter "passwd root"
0
farzanjCommented:
If you are root, just say

passwd

If you are not root, you can issue command
passwd root

as pilson66 said.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
omarfaridCommented:
as root user run

passwd

you will not be prompted for old password

but if you are some other user then use

passwd root

and you will be prompted for old root password
0
Duncan RoeSoftware DeveloperCommented:
Do you still have the old root password? The above answers only work if you do. Otherwise you have to reboot with init=/bin/bash appended to the boot command line. That gives you a root shell prompt and then you change the password as in http:#a37309842 above.
The procedure for appending to the boot line is explained here
0
Dmitriy SkyIT EngeneerCommented:
if you under ubuntu, you have sudo to use root permissions, do not actualy need root password, and root login, (for security), u can use
sudo -sH
sudo su


to run as root,

also sudo *command* run it as root, but without root enviroment, it's not actualy need, only if you install Oracle/or something, that use u'r system enviroment


but if you still need root pass/ or forget old

type:
passwd root
sudo passwd

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.