Both sides previous revision Previous revision Next revision | Previous revision |
redhat:other-redhat:reset-root-pw [2017/09/26 21:58] – michael | redhat:other-redhat:reset-root-pw [2019/03/07 14:48] (current) – michael |
---|
====== CentOS / RHEL7 RESET root Password ====== | ====== RESET root Password on CentOS / RHEL7 ====== |
| |
| |
| |
| |
- Im Bootloader Standarteintrag editieren und bei „**Linux16**“ //**(am Ende)**// **rd.break** eintragen. ->> mit ''**CTRL + X**'' booten | <WRAP center box 100%> |
- System root mit **RW** remounten: ->> ''**mount –oremount,rw /sysroot**'' | * **Schritt 1** - ''Denn automatischen Bootprozess mit den **Pfeiltasten "auf / ab"** unterbrechen, anschliessend den Bootloader Standarteintrag durch drücken von von "**e**" editieren'' {{ :redhat:other-redhat:how-to-reset-forgotten-root-password-step1.png?nolink |}} |
- In richtiges Root System wechseln. ->> ''**chroot /sysroot**'' | |
- Passwort neu setzen: ->> ''**passwd root**'' >> (Neues PW 2x eingeben) | |
- **SELinux relabeling** (beim nächsten boot) veranlassen: ->> ''**touch /.autorelabel**'' | |
- System neustarten: ->> ''**exit**'' ->> ''**reboot**'' | |
| |
<wrap em>The root password should now be resettet!</wrap> | ---- |
| |
http://www.elinuxbook.com/how-to-reset-forgotten-root-password-in-rhel-7/ | * **Schritt 2** - ''Ergänzung bei "**Linux16**" //(am Ende der Zeile)// **"rd.break" eintragen**. -> danach das System mit **CTRL + X** booten!'' {{ :redhat:other-redhat:how-to-reset-forgotten-root-password-step2.png?nolink |}} |
| |
| ---- |
| |
{{ :redhat:other-redhat:cracked-lock.jpg?nolink |}} | * **Schritt 3** - ''System sysroot mit **RW** remounten, da standartmässig /sysroot beim booten nur ro (Read Only) gemountet wird: -> **mount –oremount,rw /sysroot**'' |
| * **OPTIONAL**: //Mit "''mount | grep root''" Überprüfen, wie /sysroot aktuell gemountet ist:// {{:redhat:other-redhat:how-to-reset-forgotten-root-password-step3.png?nolink|}} <WRAP clear/> |
| * ''Remounten von /sysroot mit **RW Berechtigungen**:''<WRAP clear/> {{:redhat:other-redhat:how-to-reset-forgotten-root-password-step3.2.png?nolink |}} <WRAP clear/> |
| * **OPTIONAL**: //Erneutes Überprüfen, wie /sysroot gemountet ist (Falls man möchte):// {{:redhat:other-redhat:how-to-reset-forgotten-root-password-step3.3.png?nolink|}} <WRAP clear/> |
| |
| ---- |
| |
| * **Schritt 5** - In richtiges Root System wechseln. -> ''<wrap em>chroot /sysroot</wrap>'' |
| * **Schritt 6** - Passwort neu setzen: -> ''<wrap em>passwd root</wrap>'' >> **(Neues PW 2x eingeben)** |
| * **Schritt 7** - **SELinux relabeling** (beim nächsten boot) veranlassen: -> ''<wrap em>touch /.autorelabel</wrap>'' |
| * **Schritt 8** - System neustarten: -> ''<wrap em>exit</wrap>'' -> ''<wrap em>reboot</wrap>'' |
| |
| <wrap em>The root password should be resettet now!</wrap> |
| </WRAP> |
| |
| |
| {{ :redhat:other-redhat:cracked-lock.jpg?nolink&400 |}} |