Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Lost my password and lost my way. I’m in the process of learning Centos7 and had to move to another project for the last month. Returned to my computer and realized I didn’t write down my password anywhere. Oops.
So I went on line and found this solution:
1 - At the boot menu, press e to edit the existing kernel
2 - Next, scroll down to the list until you see the line underlined below ( ro ) . What we need to do is change that ro to rw and start into a bash shell. It should look like this rw init=/sysroot/bin/sh.
//So far so good. I’m now in the shell. However the next instruction is to type “chroot /sysroot” at the prompt. The prompt in the instruction, however, is :/# and my prompt is dracut:/#
//When I type chroot /sysroot at my prompt (dracut:/#), I get “failed to run command ‘/bin/sh’: No such file or directory.
//After this, the instructions are to create a new password via:
3 - Finally, run the commands below to change the root password - passwd root
4 - You’ll be prompted to create and confirm a new password. After creating the password, run the commands below to update SELinux parameters - touch /.autorelabel
The way I've usually gotten around that is to enter "init = /bin/bash" as a kernel boot option (in GRUB 2, select CentOS 7, press "e", and add it to the line that says "linux" or "linux16"). At the resulting bash shell, you can use passwd to reset the root password, then do an ugly reboot since systemd wasn't loaded. If you're using an older system, you may have to hook up a PS/2 keyboard for this to work.