Questo contenuto non è disponibile nella lingua selezionata.
10.3. Plymouth
Plymouth
is a graphical boot system and logger for Red Hat Enterprise Linux 7, which makes use of the kernel-based mode setting (KMS) and Direct Rendering Manager (DRM). Plymouth
also handles user interaction during boot.
10.3.1. Branding the Theme Copia collegamentoCollegamento copiato negli appunti!
Plymouth
is composed of a theme data file and a compiled splash plugin module. The data file has a .plymouth
extension, and is installed in the /usr/share/plymouth/themes/
directory.
[Plymouth Theme]
section, in the key-value format. Valid keys for this group are Name, Description, and ModuleName. While the first two keys are self-explanatory, the third specifies the name of a Plymouth
splash plugin module. Different plugins provide different animations at boot time and the underlying implementation of the various themes:
Example 10.2. A .plymouth File Specimen
[Plymouth Theme] Name=Charge Description=A theme that features the shadowy hull of my logo charge up and finally burst into full form. ModuleName=two-step
[Plymouth Theme]
Name=Charge
Description=A theme that features the shadowy hull of my logo charge up and finally burst into full form.
ModuleName=two-step
Procedure 10.3. Changing the Plymouth Theme
- Search for the existing
Plymouth
themes and choose the most preferable one. Run the following command:yum search plymouth-theme
# yum search plymouth-theme
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Or run theplymouth-set-default-theme --list
command to view the installed themes.You can also install all the themes when installing all the plymouth packages. However, you will install a number of unnecessary packages as well.yum install plymouth\*
# yum install plymouth\*
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Set the new theme as default with the
plymouth-set-default-theme theme_name
command.Example 10.3. Set "spinfinity" as the Default Theme
You have chosen the spinfinity theme, so you run:plymouth-set-default-theme spinfinity
# plymouth-set-default-theme spinfinity
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Rebuild the
initrd
daemon after editing otherwise your theme will not show in the boot screen. Do so by running:dracut -f
# dracut -f# dracut -f
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
10.3.2. Creating a New Plymouth Theme Copia collegamentoCollegamento copiato negli appunti!
Procedure 10.4. Creating Your Own Theme from an Existing Theme
- Copy an entire content of a
plymouth/
directory. As a template directory, use, for example, the default theme for Red Hat Enterprise Linux 7,/usr/share/plymouth/themes/charge/charge.plymouth
, which uses a two-step splash plugin (two-step is a popular boot load feature of a two phased boot process that starts with a progressing animation synced to boot time and finishes with a short, fast one-shot animation):Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Save the
charge.plymouth
file with a new name in the/usr/share/plymouth/themes/newtheme/
directory, in the following format:newtheme.plymouth
newtheme.plymouthnewtheme.plymouth
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Update the settings in your
/usr/share/plymouth/themes/newtheme/newtheme.plymouth
file according to your preferences, changing color, alignment, or transition. - Set your newtheme as default by running the following command:
plymouth-set-default-theme newtheme
# plymouth-set-default-theme newtheme# plymouth-set-default-theme newtheme# plymouth-set-default-theme newtheme
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Rebuild the
initrd
daemon after changing the theme by running the command below:dracut -f
# dracut -f
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
10.3.2.1. Using Branded Logo Copia collegamentoCollegamento copiato negli appunti!
Important
Procedure 10.5. Add Your Logo to the Theme
- Create an image file named
logo.png
with your logo. - Edit the
/usr/share/plymouth/themes/newtheme.plymouth
file by updating the ImageDir key to point to the directory with thelogo.png
image file you created in step 1:ImageDir=/usr/share/plymouth/themes/newtheme
ImageDir=/usr/share/plymouth/themes/newtheme
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Plymouth
, see the plymouth
(8) man page.