Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
en:system:init_systems:openrc [2024/12/31 16:02] throgh |
en:system:init_systems:openrc [2025/03/13 01:05] (current) throgh [The system can't shutdown correctly] |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== OpenRC ====== | ====== OpenRC ====== | ||
| - | OpenRC is an init system for operating systems such as GNU/Linux, GNU/Hurd and Unix. It is a [[https:// | + | OpenRC is an init system for operating systems such as GNU/Linux, GNU/Hurd and Unix. It is a [[https:// |
| OpenRC emerged at the end of 2007, ((for more details go to: [[https:// | OpenRC emerged at the end of 2007, ((for more details go to: [[https:// | ||
| Line 12: | Line 12: | ||
| OpenRC provides a number of interesting features: | OpenRC provides a number of interesting features: | ||
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | + | ||
| - | ===== Configuration ===== | + | |
| - | + | ||
| - | Configuring OpenRC is a simple task. Below are some steps to optimize the use of this initialization system. | + | |
| - | + | ||
| - | ==== Boot logs ==== | + | |
| - | + | ||
| - | Open the configuration file <color # | + | |
| - | The log files for the entire **rc** process will be stored in <color # | + | |
| - | + | ||
| - | ==== Hostname ==== | + | |
| - | + | ||
| - | To add or edit a host name, edit or create the file <color # | + | |
| - | + | ||
| - | <code bash> | + | |
| - | hostname=" | + | |
| - | </ | + | |
| - | + | ||
| - | ==== Keyboard ==== | + | |
| - | + | ||
| - | To modify the key map for use in the **console**: | + | |
| - | + | ||
| - | <code bash> | + | |
| - | keymap=" | + | |
| - | </ | + | |
| - | + | ||
| - | To configure the keyboard for use with a **graphical interface**, | + | |
| - | + | ||
| - | <code bash> | + | |
| - | keymap=" | + | |
| - | </ | + | |
| - | + | ||
| - | After editing the files, run the command: | + | |
| - | + | ||
| - | <code bash> | + | |
| - | # rc-service keymaps restart | + | |
| - | </ | + | |
| - | + | ||
| - | ==== Login manager ==== | + | |
| - | + | ||
| - | **xorg-xdm** | + | |
| - | + | ||
| - | To enable the login manager, edit <color # | + | |
| - | + | ||
| - | If that file does not already exist, then first make sure to install the package **xorg-xdm**: | + | |
| - | <code bash> | + | |
| - | pacman -S xorg-xdm | + | |
| - | </ | + | |
| - | + | ||
| - | As an example, to use **slim** as the graphical login manager (//with the precondition to install the package **slim**// | + | |
| - | <code bash> | + | |
| - | DISPLAYMANAGER=" | + | |
| - | </ | + | |
| - | + | ||
| - | In order for changes to take effect, make sure to enable the xdm daemon, like so: | + | |
| - | <code bash> | + | |
| - | # rc-update add xdm default | + | |
| - | </ | + | |
| - | + | ||
| - | **slim** | + | |
| - | + | ||
| - | The alternative would be to use **slim** direct. So first make sure to install the package **slim**: | + | |
| - | <code bash> | + | |
| - | pacman -S slim | + | |
| - | </ | + | |
| - | + | ||
| - | You can add the service direct at the corresponding runlevel: | + | |
| - | <code bash> | + | |
| - | # rc-update add slim default | + | |
| - | </ | + | |
| - | + | ||
| - | ==== Kernel modules ==== | + | |
| - | + | ||
| - | For the automatic loading of any module of the <color # | + | |
| - | + | ||
| - | <code bash> | + | |
| - | modules=" | + | |
| - | </ | + | |
| - | + | ||
| - | This is only necessary after installation of an application or driver, made by the system administrator, | + | |
| ===== Runlevels ===== | ===== Runlevels ===== | ||
| Line 139: | Line 59: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 145: | Line 65: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 151: | Line 71: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 157: | Line 77: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 163: | Line 83: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 173: | Line 93: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| - | |||
| - | < | ||
| ===== Migration ===== | ===== Migration ===== | ||
| Line 217: | Line 135: | ||
| ==> rc ' | ==> rc ' | ||
| </ | </ | ||
| + | |||
| + | ==== Boot logs ==== | ||
| + | |||
| + | Open the configuration file <color # | ||
| + | The log files for the entire **rc** process will be stored in <color # | ||
| ==== Hostname ==== | ==== Hostname ==== | ||
| Line 235: | Line 158: | ||
| </ | </ | ||
| - | ==== Network settings | + | ==== Keyboard and Keymap |
| - | You need to enable | + | To modify |
| <code bash> | <code bash> | ||
| - | # rc-update add dhcpcd default | + | keymap=" |
| </ | </ | ||
| - | ==== Keymap ==== | + | To configure the keyboard for use with a **graphical interface**, |
| - | As the hostname, you need to setup the keymap in the file <color # | + | < |
| - | + | ||
| - | < | + | |
| keymap=" | keymap=" | ||
| </ | </ | ||
| - | If you have an advanced usage of your keymap, you can watch the other functionalities, documented in the comments. You can find all the available keymaps in <color # | + | After editing |
| <code bash> | <code bash> | ||
| Line 259: | Line 180: | ||
| < | < | ||
| - | ==== Login display manager | + | ==== Network settings |
| - | Unlike in many other operating system distributions: | + | You need to enable |
| - | Just make sure that you have first read and understood the information in the [[OpenRC#login_manager|Login Manager section]]. | + | <code bash> |
| + | # rc-update add dhcpcd default | ||
| + | </ | ||
| - | For example, to use <color # | ||
| + | |||
| + | ==== Login manager ==== | ||
| + | |||
| + | **xorg-xdm** | ||
| + | |||
| + | To enable the login manager, edit <color # | ||
| + | |||
| + | If that file does not already exist, then first make sure to install the package **xorg-xdm**: | ||
| + | <code bash> | ||
| + | pacman -S xorg-xdm | ||
| + | </ | ||
| + | |||
| + | As an example, to use **slim** as the graphical login manager (//with the precondition to install the package **slim**// | ||
| + | <code bash> | ||
| + | DISPLAYMANAGER=" | ||
| + | </ | ||
| + | |||
| + | In order for changes to take effect, make sure to enable the xdm daemon, like so: | ||
| <code bash> | <code bash> | ||
| # rc-update add xdm default | # rc-update add xdm default | ||
| </ | </ | ||
| + | |||
| + | **slim** | ||
| + | |||
| + | The alternative would be to use **slim** direct. So first make sure to install the package **slim**: | ||
| + | <code bash> | ||
| + | pacman -S slim | ||
| + | </ | ||
| + | |||
| + | You can add the service direct at the corresponding runlevel: | ||
| + | <code bash> | ||
| + | # rc-update add slim default | ||
| + | </ | ||
| + | |||
| + | ==== Kernel modules ==== | ||
| + | |||
| + | For the automatic loading of any module of the <color # | ||
| + | |||
| + | <code bash> | ||
| + | modules=" | ||
| + | </ | ||
| + | |||
| + | This is only necessary after installation of an application or driver, made by the system administrator, | ||
| + | |||
| ===== Adaptation between systemctl and rc-update ===== | ===== Adaptation between systemctl and rc-update ===== | ||
| Line 357: | Line 320: | ||
| <code bash> | <code bash> | ||
| - | # passwd | + | # usermod |
| </ | </ | ||
| Line 366: | Line 329: | ||
| </ | </ | ||
| - | ===== Acknowledgement ===== | ||
| - | This wiki article is based on **[[https:// | ||