Resetting Root Password and Relabeling with SElinux on Linux Systems on SLE Micro
This document (000021384) is provided subject to the disclaimer at the end of this document.
Environment
Situation
Resolution
2. While the Grub menu is displayed, move the cursor to the intended boot entry (usually the first one) and press "E" to edit.
3. Locate the line beginning with linux, and append init=/bin/bash autorelabel=1 to the end of the line as additional kernel command line arguments.
4. Press Ctrl-X (or F10) and allow the system to boot to the shell prompt.
5. Enter passwd and press Enter, then input a new password twice.
6. Type exec /sbin/init after the shell prompt and press Enter. This will proceed the system to boot to the login prompt.
7. Login as root with the new password
8. Run restorecon /etc/shadow
9. Reboot the system
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:000021384
- Creation Date: 04-Mar-2024
- Modified Date:05-Mar-2024
-
- SUSE Linux Enterprise Micro
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com