Author: odabrunz
Date: Tue Jul 10 21:48:07 2007
New Revision: 39300
URL: http://svn.opensuse.org/viewcvs/yast?rev=39300&view=rev
Log:
- added help texts and widget descriptions to grub and elilo
(#221737)
- Fixed type of passed arguments in function Import() (in
modules/Bootloader.ycp & modules/BootELILO.ycp) (#236163)
- bootloader.rnc fixed for autoyast schema check
- set __auto key to false when user clones sections (#241158)
- added log message when FixSections() silently discards a section
(#241158)
Modified:
trunk/bootloader/src/config/bootloader.rnc
trunk/bootloader/src/elilo/helps.ycp
trunk/bootloader/src/generic/section_type_widget.ycp
trunk/bootloader/src/grub/helps.ycp
trunk/bootloader/src/modules/Bootloader.ycp
trunk/bootloader/src/routines/lilolike.ycp
trunk/bootloader/src/routines/section_widgets.ycp
Modified: trunk/bootloader/src/config/bootloader.rnc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/config/bootloader.rnc?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/config/bootloader.rnc (original)
+++ trunk/bootloader/src/config/bootloader.rnc Tue Jul 10 21:48:07 2007
@@ -41,6 +41,7 @@
bl_location = element location { text }
bl_global =
element global {
+ element boot_custom { text }? &
lines_cache_id? &
bl_timeout? &
gfxmenu? &
Modified: trunk/bootloader/src/elilo/helps.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/elilo/helps.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/elilo/helps.ycp (original)
+++ trunk/bootloader/src/elilo/helps.ycp Tue Jul 10 21:48:07 2007
@@ -21,25 +21,67 @@
global map elilo_help_messages = $[
"boot-loader-location" : _("<p><big><b>Boot Loader Location</b></big><br>"),
+ "boot" : _("<p><b>Boot Image Location</b></p>"),
+ "default" : _("<p><b>Default Boot Section</b></p>"),
+ "timeout" :
+ _("<p><b>Timeout in tenth of seconds</b><br> Specifies the the time the
+bootloader will wait in interactive mode until the default entry is
+booted.</p>"),
+ "verbose" :
+ _("<p><b>Set level of verbosity [0-5]</b><br> Increase verbosity of ELILO
+in case of boot problems.</p>"),
+ "append" :
+ _("<p><b>Global Append string of options to kernel command line</b><br>
+Lets you define global, additional parameters to pass to the kernel. These are
+used if no 'append' appears in a given section.</p>"),
+ "initrd" :
+ _("<p><b>Name of default initrd file</b>, if non-empty, defines the initial
+ramdisk to use. Either enter the path and file name directly or choose by using
+<b>Browse</b></p>"),
+ "image" :
+ _("<p><b>Name of default image file</b></p>"),
+ "chooser" :
+ _("<p><b>Specify user interface for ELILO ('simple' or 'textmenu')</b><br>
+Beware: 'textmenu' has occasionally caused problems on some machines.</p>"),
+ "noedd30" :
+ _("<p><b>Prevent EDD30 mode</b><br>
+By default, if EDD30 is off, elilo will try and set the variable to TRUE.
+However, some controllers do not support EDD30 and forcing the variable
+may cause problems. Therefore as of elilo-3.2, there is an option to
+avoid forcing the variable.</p>"),
+ "relocatable" :
+ _("<p><b>Allow attempt to relocate</b><br>
+In case of memory allocation error at initial load point of
+kernel, allow attempt to relocate (assume this kernel is relocatable).
+</p>"),
+ "image_append" :
+ _("<p><b>Optional kernel command line parameter</b></p>
+May be empty, if already specified in global section.</p>"),
+ "image_readonly" :
+ _("<p><b>Force root filesystem to be mounted read-only</b><br>
+Usually specified in global section</p>"),
+ "image_relocatable" :
+ _("<p><b>Allow attempt to relocate</b></p>
+Usually specified in global section</p>"),
];
global map elilo_descriptions = $[
"boot" : _("Boot Image Location"),
"default" : _("Default Boot Section"),
- "timeout" : _("Timeout in Seconds"),
- "delay" : _("Delay to wait before auto booting in seconds"),
- "prompt" : _("Show boot menu"),
+ "timeout" : _("Timeout in tenth of seconds (in interactive mode)"),
+ "delay" : _("Delay to wait before auto booting in seconds (used if not in interactive mode)"),
+ "prompt" : _("Force interactive mode"),
"verbose" : _("Set level of verbosity [0-5]"),
- "root" : _("Set global root filesystem"),
+ "root" : _("Set default root filesystem"),
"readonly" : _("Force rootfs to be mounted read-only"),
- "append" : _("Append string of options to kernel command line"),
- "initrd" : _("Name of initrd file"),
- "image" : _("Name of image file"),
- "chooser" : _("Specify kernel chooser to use"),
+ "append" : _("Global append string of options to kernel command line"),
+ "initrd" : _("Name of default initrd file"),
+ "image" : _("Name of default image file"),
+ "chooser" : _("Specify user interface for ELILO ('simple' or 'textmenu')"),
"message" : _("Message printed on main screen (if supported)"),
"fX" : _("Display the content of a file by function keys"),
- "noedd30" : _("Don't force EDD30 mode if not set"),
+ "noedd30" : _("Prevent EDD30 mode"),
"fpswa" : _("Specify the filename for a specific FPSWA to load"),
"relocatable" : _("Allow attempt to relocate"),
"boot_custom" : _("Custom Boot Partition"),
Modified: trunk/bootloader/src/generic/section_type_widget.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/generic/section_type_widget.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/generic/section_type_widget.ycp (original)
+++ trunk/bootloader/src/generic/section_type_widget.ycp Tue Jul 10 21:48:07 2007
@@ -67,6 +67,7 @@
{
BootCommon::current_section["name"] = "";
BootCommon::current_section["original_name"] = "";
+ BootCommon::current_section["__auto"] = false;
}
return nil;
}
Modified: trunk/bootloader/src/grub/helps.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/grub/helps.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/grub/helps.ycp (original)
+++ trunk/bootloader/src/grub/helps.ycp Tue Jul 10 21:48:07 2007
@@ -20,53 +20,152 @@
textdomain "bootloader";
global map grub_help_messages = $[
+ "boot-menu" :
+ _("<p><big><b>Boot Menu</b></big><br></p>"),
+ "activate" :
+ _("<b>Set active Flag in Partition Table for Boot Partition</b><br>
+To activate the partition which contains the boot loader. The generic MBR code will then
+boot the active partition. Older BIOSes require one partition to be active even
+if the boot loader is installed in the MBR.</p>"),
+ "timeout" :
+ _("<p><b>Timeout in Seconds</b><br>
+Specifies the the time the bootloader will wait until the default kernel is loaded.</p>"),
+ "default" :
+ _("<p> By pressing <b>Set as Default</b> you mark the selected
+section as default. When booting, the boot loader will provide
+a boot menu and wait for the user to select the kernel or another
+OS to boot. If no key is pressed before the time-out, the default
+kernel or OS will be booted. The order of the sections in the boot loader
+menu can be changed using the <b>Up</b> and <b>Down</b> buttons.</p>"),
+ "generic_mbr" :
+ _("<p><big><b>Write generic Boot Code to MBR</b></big><br>
+To replace the master boot record of your disk with generic code (OS independent code which
+boots the active partition), select <b>Write generic Boot Code to MBR</b>.</p>"),
+ "boot_boot" :
+ _("<p><b>Boot from Boot Partition</b> is one of the recommended options, the other is
+<b>Boot from Root Partition</b>.</p>"),
+ "boot_mbr" :
+ _("<p><b>Boot from Master Boot Record</b> is not recommended if you have another operating system
+installed on your computer</p>"),
+ "boot_root" :
+ _("<p><b>Boot from Root Partition</b> is the recommended option whenever there is a suitable
+partition. Either select <b>Set active Flag in Partition Table for Boot Partition</b> and <b>Write generic Boot Code to MBR</b>
+in <b>Boot Loader Options</b> to update the master boot record if that is needed or configure your other boot manager
+to start this section.</p>"),
+ "boot_custom" :
+ _("<p><b>Custom Boot Partition</b> lets you choose a partition to boot from</p>"),
+ "serial" :
+ _("<p><b>Serial Connection Parameters</b> lets you define the paramters to use
+for a serial console. Please see the grub documentation (<code>info grub</code>) for details.</p>"),
+ "terminal" :
+ _("<p><b>Terminal Definition</b></p><br>
+Defines the type of terminal you want to use. For a serial terminal (eg. a serial console),
+you have to specify <code>serial</code>. You can also pass <code>console</code> to the
+command, as <code>serial console</code>. In this case, a terminal in which you
+press any key will be selected as a GRUB terminal.</p>"),
"fallback" :
- _("<b>Fallback</b> contains a list of section numbers that will be used for
-booting in case the default section is unbootable."),
+ _("<p><b>Fallback Sections if default Fails</b> contains a list of section numbers
+that will be used for booting in case the default section is unbootable.</p>"),
+ "hiddenmenu" :
+ _("<p>Selecting <b>Hide Menu on Boot</b> will hide the boot menu</p>"),
+ "gfxmenu" :
+ _("<p><b>Graphical Menu File</b> defines the file to use for the graphical boot menu.</p>"),
+ "password" :
+ _("<p><b>Password for the Menu Interface</b><br>
+Define the password that will be required to access the boot menu. YaST will only accept the password if you repeat
+it in <b>Retype Password</b>.</p>"),
+ "type_image" :
+ _("<p><b>Image Section</b></p>"),
+ "image_image" :
+ _("<p><b>Kernel Image</b> defines the kernel to boot. Either enter the name directly or choose via <b>Browse</b></p>"),
+ "image_root" :
+ _("<p><b>Root Device</b> sets the device to pass to the kernel as root device.</p>"),
+ "image_vgamode" :
+ _("<p><b>Vga Mode</b> defines the VGA mode for the <i>console</i> the kernel should set when booting</p>"),
+ "image_append" :
+ _("<p><b>Optional Kernel Command Line Parameter</b> lets you define additional parameters to pass to the kernel</p>"),
+ "image_initrd" :
+ _("<p><b>Initial RAM Disk</b>, if non-empty, defines the initial ramdisk to use. Either enter the path and file name
+directly or choose by using <b>Browse</b></p>"),
+ "image_noverifyroot" :
+ _("<p>Selecting <b>Do not verify Filesystem before Booting</b> will skip all file system checks.</p>"),
+ "type_other" :
+ _("<p>Select <b>Chainloader Section</b> if you want to define a section for booting an OS other than Linux</p>"),
+ "other_lock" :
+ _("<p>Setting <b>Use Password Protection</p> will require a password to select this section</p>"),
+ "other_chainloader" :
+ _("<p><b>Other System</b> lets you choose among the non-Linux operating systems found on your computer.</p>"),
+ "other_makeactive" :
+ _("<p>Select <b>Activate this Partition when selected for Boot</b> if your BIOS needs this flag set in order to boot it</p>"),
+ "other_blockoffset" :
+ _("<p><b>Block Offset for Chainloading</b> lets you specify the list of blocks to boot. In most cases you want
+to specify <code>+1</code> here. For specifics on blocklist notation see the grub documentation</p>"),
+ "type_xen" :
+ _("<p>Select <b>Xen Section</b> to add a new Linux kernel or other image,
+but to start it in a XEN environment.</p>"),
+ "xen_image" :
+ _("<p><b>Kernel Image</b> defines the kernel to boot. Either enter the name directly or choose via <b>Browse</b></p>"),
+ "xen_append" :
+ _("<p><b>Optional Kernel Command Line Parameter</b> lets you define additional parameters to pass to the kernel</p>"),
+ "xen_xen" :
+ _("<p><b>Hypervisor</b> specifies the Hypervisor to use.</p>"),
+ "xen_root" :
+ _("<p><b>Root Device</b> sets the device to pass to the kernel as root device.</p>"),
+ "xen_vgamode" :
+ _("<p><b>Vga Mode</b> defines the VGA mode for the <i>console</i> the kernel should set when booting</p>"),
+ "xen_initrd" :
+ _("<p><b>Initial RAM Disk</b>,if non-empty, defines the initial ramdisk to use. Either enter the path and file name
+directly or choose by using <b>Browse</b></p>"),
+ "type_menu" :
+ _("<p><b>Menu Section</b></p>"),
+ "menu_root" :
+ _("<p><b>Partition of Menu File</b></p>"),
+ "menu_configfile" :
+ _("<p><b>Menu Description File<b></p>"),
];
global map grub_descriptions = $[
- "boot" : _("Boot Loader Locations"),
- "activate" : _("Set active Flag in Partition Table for Boot Partition"),
- "timeout" : _("Timeout in Seconds"),
- "default" : _("Default Boot Section"),
- "generic_mbr" : _("Write generic Boot Code to MBR"),
- "boot_custom" : _("Custom Boot Partition"),
- "boot_mbr" : _("Boot from Master Boot Record"),
- "boot_root" : _("Boot from Root Partition"),
- "boot_boot" : _("Boot from Boot Partition"),
- "serial" : _("Serial Connection Parameters"),
- "terminal" : _("Terminal Definition"),
- "fallback" : _("Fallback Sections if default Fails"),
- "hiddenmenu" : _("Hide Menu on Boot"),
- "gfxmenu" : _("Graphical Menu File"),
- "password" : _("Password for the Menu Interface"),
- "debug" : _("Debugging Flag"),
- "type_image" : _("Image Section"),
- "image_image" : _("Kernel Image"),
- "image_root" : _("Root Device"),
- "image_vgamode" : _("Vga Mode"),
- "image_append" : _("Optional Kernel Command Line Parameter"),
- "image_initrd" : _("Initial RAM Disk"),
- "image_noverifyroot" : _("Do not verify Filesystem before Booting"),
- "type_other" : _("Chainloader Section"),
- "other_lock" : _("Use Password Protection"),
- "other_chainloader" : _("Other System"),
- "other_noverifyroot" : _("Do not verify Filesystem before Booting"),
- "other_makeactive" : _("Activate this Partition when selected for Boot"),
- "other_blockoffset" : _("Block Offset for Chainloading"),
- "type_xen" : _("Xen Section"),
- "xen_xen" : _("Hypervisor"),
- "xen_xen_append" : _("Additional Xen Hypervisor Parameters"),
- "xen_image" : _("Kernel Image"),
- "xen_root" : _("Root Device"),
- "xen_vgamode" : _("Vga Mode"),
- "xen_append" : _("Optional Kernel Command Line Parameter"),
- "xen_initrd" : _("Initial RAM Disk"),
- "type_menu" : _("Menu Section"),
- "menu_root" : _("Partition of Menu File"),
- "menu_configfile" : _("Menu Description File"),
+ "boot" : _("Boot Loader Locations"),
+ "activate" : _("Set active Flag in Partition Table for Boot Partition"),
+ "timeout" : _("Timeout in Seconds"),
+ "default" : _("Default Boot Section"),
+ "generic_mbr" : _("Write generic Boot Code to MBR"),
+ "boot_custom" : _("Custom Boot Partition"),
+ "boot_mbr" : _("Boot from Master Boot Record"),
+ "boot_root" : _("Boot from Root Partition"),
+ "boot_boot" : _("Boot from Boot Partition"),
+ "serial" : _("Serial Connection Parameters"),
+ "terminal" : _("Terminal Definition"),
+ "fallback" : _("Fallback Sections if default Fails"),
+ "hiddenmenu" : _("Hide Menu on Boot"),
+ "gfxmenu" : _("Graphical Menu File"),
+ "password" : _("Password for the Menu Interface"),
+ "debug" : _("Debugging Flag"),
+ "type_image" : _("Image Section"),
+ "image_image" : _("Kernel Image"),
+ "image_root" : _("Root Device"),
+ "image_vgamode" : _("Vga Mode"),
+ "image_append" : _("Optional Kernel Command Line Parameter"),
+ "image_initrd" : _("Initial RAM Disk"),
+ "image_noverifyroot" : _("Do not verify Filesystem before Booting"),
+ "type_other" : _("Chainloader Section"),
+ "other_lock" : _("Use Password Protection"),
+ "other_chainloader" : _("Other System"),
+ "other_noverifyroot" : _("Do not verify Filesystem before Booting"),
+ "other_makeactive" : _("Activate this Partition when selected for Boot"),
+ "other_blockoffset" : _("Block Offset for Chainloading"),
+ "type_xen" : _("Xen Section"),
+ "xen_xen" : _("Hypervisor"),
+ "xen_xen_append" : _("Additional Xen Hypervisor Parameters"),
+ "xen_image" : _("Kernel Image"),
+ "xen_root" : _("Root Device"),
+ "xen_vgamode" : _("Vga Mode"),
+ "xen_append" : _("Optional Kernel Command Line Parameter"),
+ "xen_initrd" : _("Initial RAM Disk"),
+ "type_menu" : _("Menu Section"),
+ "menu_root" : _("Partition of Menu File"),
+ "menu_configfile" : _("Menu Description File"),
];
Modified: trunk/bootloader/src/modules/Bootloader.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/modules/Bootloader.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/modules/Bootloader.ycp (original)
+++ trunk/bootloader/src/modules/Bootloader.ycp Tue Jul 10 21:48:07 2007
@@ -39,7 +39,7 @@
import "BootPOWERLILO"; // The ppc-LILO File
global define map Export ();
- global define boolean Import (map settings);
+ global define boolean Import (map settings);
global define void Propose ();
global define boolean Read ();
global define void Reset ();
@@ -134,7 +134,7 @@
* @param settings map of bootloader settings
* @return boolean true on success
*/
- global define boolean Import (map settings) {
+ global define boolean Import (map settings) {
y2milestone ("Importing settings: %1", settings);
Reset ();
Modified: trunk/bootloader/src/routines/lilolike.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/routines/lilolike.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/routines/lilolike.ycp (original)
+++ trunk/bootloader/src/routines/lilolike.ycp Tue Jul 10 21:48:07 2007
@@ -450,7 +450,9 @@
else
{
// section was created by us, then changed by the user:
- // - keep it
+ // - keep it, except if no newly created section of same type can
+ // be found (which probably means we have a bug, because
+ // "__auto" says we created the old section as well)
// - maybe notify user to check it (and then mark it as a "user
// defined section")
y2milestone ("Warning on section %1", label);
@@ -467,11 +469,18 @@
}
});
}
- // if the devices for this section and the freshly created one of
- // the same type are different, notify user
+ // find section of same type in newly created sections;
+ // if not found (which should not happen, since according to the
+ // "__auto" key we created it) delete this section
map new_this_section = new_sect[type]:$[];
- if (new_this_section == $[])
+ if (new_this_section == $[]) {
+ y2warning("Warning, could not find freshly proposed section" +
+ "corresponding to section %1, deleting it",
+ s["name"]:"");
return $[];
+ }
+ // if the devices for this section and the freshly created one of
+ // the same type are different, notify user
list new_devs = toset(new_this_section["__devs"]:[]);
list old_devs = toset(s["__devs"]:[]);
if (size (new_devs) != size (old_devs))
@@ -483,7 +492,7 @@
cont = false;
});
}
- // display popup for this section;
+ // display info popup for this section;
// also, next time we come through this function, consider this
// section as a section created by the user (and leave it as it is)
if (! cont)
Modified: trunk/bootloader/src/routines/section_widgets.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/bootloader/src/routines/section_widgets.ycp?rev=39300&r1=39299&r2=39300&view=diff
==============================================================================
--- trunk/bootloader/src/routines/section_widgets.ycp (original)
+++ trunk/bootloader/src/routines/section_widgets.ycp Tue Jul 10 21:48:07 2007
@@ -317,6 +317,7 @@
{
BootCommon::current_section["name"] = "";
BootCommon::current_section["original_name"] = "";
+ BootCommon::current_section["__auto"] = false;
BootCommon::current_section["lines_cache_id"] = "";
}
y2milestone ("Added section template: %1", BootCommon::current_section);
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org