38. Bootloader

Bootloader installation and configuration base module

38.1. Authors

  • Jiri Srain <jsrain@suse.cz>

  • Olaf Dabrunz <od@suse.de>

38.2. Summary of Module Globals

List of Global Functions

List of Global Variables

38.3. Global Functions

38.3.1. Bootloader

Constructor

Return value

  • void

38.3.2. DelDuplicatedSections

Delete duplicated boot sections from BootCommon::sections

Return value

  • void

38.3.3. Export

Export bootloader settings to a map

Return value

  • map - bootloader settings

38.3.4. FlagOnetimeBoot

Set section to boot on next reboot

Function parameters

  • string section

Return value

  • boolean - true on success

38.3.5. Import

Import settings from a map

Function parameters

  • map settings

Return value

  • boolean - true on success

38.3.6. PreUpdate

Process update actions needed before packages update starts

Return value

  • void

38.3.7. Propose

Propose bootloader settings

Return value

  • void

38.3.8. Read

Read settings from disk

Return value

  • boolean - true on success

38.3.9. ReadOrProposeIfNeeded

Check whether settings were read or proposed, if not, decide what to do and read or propose settings

Return value

  • void

38.3.10. Reset

Reset bootloader settings

Return value

  • void

38.3.11. ResetEx

Reset bootloader settings

Function parameters

  • boolean init

Return value

  • void

38.3.12. ResolveSymlink

Resolve a single symlink in key image_key in section map s

Function parameters

  • map<string,any> section

  • string key

Return value

  • map<string,any> - section map of the changed section

38.3.13. RunDelayedUpdates

Set section to boot on next reboot

Return value

  • void - true on success

38.3.14. SetWriteMode

Set settings how to write bootloader

Function parameters

  • map<string,any> settings

Return value

  • void

38.3.15. Summary

Display bootloader summary

Return value

  • list<string> - a list of summary lines

38.3.16. Update

Update the whole configuration

Function parameters

  • map<string,any> iv

  • map<string,any> uv

Return value

  • boolean - true on success

38.3.17. UpdateConfiguration

Update read settings to new version of configuration files

Return value

  • void

38.3.18. UpdateGfxMenu

Update the language of GFX menu according to currently selected language

Return value

  • boolean - true on success

38.3.19. Write

Write bootloader settings to disk

Return value

  • boolean - true on success

38.3.20. WriteInstallation

Write bootloader settings during installation

Return value

  • boolean - true on success

38.3.21. getBootDevice

Get device containing /boot directory

Return value

  • string - boot device

38.3.22. getDefaultSection

return default section label

Return value

  • string - default section label

38.3.23. getKernelParam

get kernel parameters from bootloader configuration file

Function parameters

  • string section

  • string key

Return value

  • string - value, "false" if not present, "true" if present key without value

38.3.24. getLoaderType

Get currently used bootloader, detect if not set yet

Return value

  • string - botloader type

38.3.25. getProposedDefaultSection

Get default section as proposed during installation

Return value

  • string - section that was proposed as default during installation, if not known, return current default section if it is of type "image", if not found return first linux section, if no present, return empty string

38.3.26. getRootDevice

Get root fs device

Return value

  • string - root device

38.3.27. getSectionsList

Get list of bootloader sections

Function parameters

  • symbol type

Return value

  • list - of strings representing sections names

38.3.28. listKernelParams

List kernel parameters

Function parameters

  • string section

Return value

  • list<string> - a list of kernel parameters (in the form 'hdd=ide-scsi')

38.3.29. setBootDevice

Set device containing /boot directory

Function parameters

  • string device

Return value

  • void

38.3.30. setLoaderType

Set type of bootloader Just a wrapper to BootCommon::setLoaderType

Function parameters

  • string bootloader

Return value

  • void

38.3.31. setRootDevice

Set root fs device

Function parameters

  • string device

Return value

  • void

38.4. Global Variables

38.4.1. cached_proposal

Cache for the installation proposal

38.4.2. proposed_cfg_changed

Configuration was changed during inst. proposal if true

38.4.3. repeating_write

Write is repeating again Because of progress bar during inst_finish

38.5. Module Requirements

38.5.1. Module Imports

  • Arch
  • Arch
  • BootCommon
  • BootELILO
  • BootGRUB
  • BootLILO
  • BootPOWERLILO
  • Directory
  • Initrd
  • Installation
  • Kernel
  • Mode
  • ProductFeatures
  • Progress
  • Stage
  • Storage

38.5.2. Module Includes

  • bootloader/routines/popups.ycp
  • bootloader/routines/switcher.ycp