|
Guides All Guides and HOWTO's. |
|
Thread Tools | Display Modes |
|
|||
multibooting OpenBSD 4.4 through Vista's boot manager
Quote:
Microsoft has moved boot information into Boot Configuration Data (BCD), and provides the bcdedit command-line utility to fully manage this database. There are still a few duplicated features controlling multibooting found in the Systems applet GUI (Start | Control Panel | System and Maintenance | System | Advanced system settings | Advanced tab | Startup and Recovery Settings | System startup), but adding new BCD entries can only be done from the command-line. Those familiar with earlier versions of Windows (but unfamiliar with UAC...) will undoubtedly be surprised when they try to invoke bcdedit from the command-line after logging in as an Administrator: Code:
C:\Windows\System32>bcdedit The boot configuration data store could not be opened. Access is denied. C:\Windows\System32> UAC can be disabled, but this defeats the purpose of UAC's security features. Running bcdedit with no arguments provides an overview of the BCD database: Code:
C:\Windows\system32>bcdedit Windows Boot Manager -------------------- identifier {bootmgr} device partition=C: description Windows Boot Manager locale en-US inherit {globalsettings} default {default} resumeobject {f4bad82f-d5dc-11db-b83c-fff6129dfa33} displayorder {default} {current} toolsdisplayorder {memdiag} timeout 10 customactions 0x10000ba000001 0x54000001 custom:54000001 {572bcd55-ffa7-11d9-aae0-0007e994107d} Windows Boot Loader ------------------- identifier {current} device partition=C: path \Windows\system32\winload.exe description Microsoft Windows Vista locale en-US inherit {bootloadersettings} osdevice partition=C: systemroot \Windows resumeobject {f4bad82f-d5dc-11db-b83c-fff6129dfa33} nx OptIn C:\Windows\system32> Code:
C:\Windows\system32>bcdedit /? BCDEDIT - Boot Configuration Data Store Editor The Bcdedit.exe command-line tool modifies the boot configuration data store. The boot configuration data store contains boot configuration parameters and controls how the operating system is booted. These parameters were previously in the Boot.ini file (in BIOS-based operating systems) or in the nonvolatile RAM entries (in Extensible Firmware Interface-based operating systems). You can use Bcdedit.exe to add, delete, edit, and append entries in the boot configuration data store. For detailed command and option information, type bcdedit.exe /? <command>. For example, to display detailed information about the /createstore command, type: bcdedit.exe /? /createstore For an alphabetical list of topics in this help file, run "bcdedit /? TOPICS". Commands that operate on a store ================================ /createstore Creates a new and empty boot configuration data store. /export Exports the contents of the system store to a file. This file can be used later to restore the state of the system store. /import Restores the state of the system store using a backup file created with the /export command. Commands that operate on entries in a store =========================================== /copy Makes copies of entries in the store. /create Creates new entries in the store. /delete Deletes entries from the store. Run bcdedit /? ID for information about identifiers used by these commands. Commands that operate on entry options ====================================== /deletevalue Deletes entry options from the store. /set Sets entry option values in the store. Run bcdedit /? TYPES for a list of datatypes used by these commands. Run bcdedit /? FORMATS for a list of valid data formats. Commands that control output ============================ /enum Lists entries in the store. /v Command-line option that displays entry identifiers in full, rather than using names for well-known identifiers. Use /v by itself as a command to display entry identifiers in full for the ACTIVE type. Running "bcdedit" by itself is equivalent to running "bcdedit /enum ACTIVE". Commands that control the boot manager ====================================== /bootsequence Sets the one-time boot sequence for the boot manager. /default Sets the default entry that the boot manager will use. /displayorder Sets the order in which the boot manager displays the multiboot menu. /timeout Sets the boot manager time-out value. /toolsdisplayorder Sets the order in which the boot manager displays the tools menu. Commands that control Emergency Management Services for a boot application ========================================================================== /bootems Enables or disables Emergency Management Services for a boot application. /ems Enables or disables Emergency Management Services for an operating system entry. /emssettings Sets the global Emergency Management Services parameters. Command that control debugging ============================== /bootdebug Enables or disables boot debugging for a boot application. /dbgsettings Sets the global debugger parameters. /debug Enables or disables kernel debugging for an operating system entry. C:\Windows\system32> http://technet.microsoft.com/en-us/l.../cc709667.aspx The official OpenBSD FAQ describes what is needed to copy OpenBSD's PBR to a file: http://openbsd.org/faq/faq4.html#Multibooting ...and this is no different when using Vista. Even if Microsoft has enhanced the boot manager interface, the basic process of booting through the MBR (Master Boot Record) has not fundamentally changed. It is still necessary to provide enough information to the boot manager to load OpenBSD's kernel into memory from its appropriate partition. The remainder of this document will be tagged with "MANDATORY" & "SUPPLEMENTARY" as some steps are necessary while others are provided for to show additional functionality.
Code:
C:\Windows\system32>bcdedit /create /d "OpenBSD/i386 4.5" /application bootsector The entry {05a763ce-d81b-11db-b3ec-000000000000} was successfully created. C:\Windows\System32>
Code:
C:\Windows\system32>bcdedit /? create This command creates a new entry in the boot configuration data store. If a well-known identifier is specified, then the /application, /inherit and /device options cannot be specified. If the <id> is not specified, or if <id>is not well-known, then you must specify an /application, /inherit or /device option. bcdedit /create [{<id>}] /d <description> [-application <apptype> | /inherit [<apptype>] | /inherit DEVICE | /device] <id> Specifies the identifier to be used for the new entry. For more information about identifiers, run "bcdedit /? ID". <description> Specifies the description to be applied to the new entry. /application <apptype> Specifies that the new entry must be an application entry. <apptype> specifies the application type. <apptype> can be one of the following: BOOTSECTOR OSLOADER RESUME STARTUP If you use other application types instead of one of these, you must also specify a well-known identifier. /inherit [<apptype>] Specifies that the new entry must be an inherit entry, and <apptype> specifies the application type. If <apptype> is not specified, then the entry can be inherited by any entry. If specified, <apptype> can be one of the following: BOOTMGR BOOTSECTOR FWBOOTMGR MEMDIAG NTLDR OSLOADER RESUME The modifier prevents the inherit entry from being inherited by an application entry of <apptype>. /inherit DEVICE Specifies that the new entry must be an inherit entry, and that the entry can only be inherited by a device options entry. /device Specifies that the new entry must be an additional device options entry. Examples: The following command creates a NTLDR based OS loader entry (Ntldr): bcdedit /create {ntldr} /d "Earlier Windows OS Loader" The following command creates a RAM disk additional options entry: bcdedit /create {ramdiskoptions} /d "Ramdisk options" The following command creates a new operating system boot entry: bcdedit /create /d "Windows Vista" /application osloader The following command creates a new debugger settings entry: bcdedit /create {dbgsettings} /d "Debugger Settings" C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /set {05a763ce-d81b-11db-b3ec-000000000000} device boot The operation completed successfully. C:\Windows\system32>bcdedit /set {05a763ce-d81b-11db-b3ec-000000000000} path \openbsd.pbr The operation completed successfully. C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /? set This command sets an entry option value in the boot configuration data store. bcdedit [/store <filename>] /set [{<id>}] <datatype> <value> <filename> Specifies the store to be used. If this option is not specified, the system store is used. For more information, run "bcdedit /? store". <id> Specifies the identifier of the entry to be modified. If not specified, {current} is used. For more information about identifiers, run "bcdedit /? ID". <datatype> Specifies the option data type that will be created or modified. Run "bcdedit /? TYPES" for more information about data types. <value> Specifies the value that should be assigned to the option. The format of <value> depends on the data type specified. Run "bcdedit /? FORMATS" for more information about data formats. Examples: The following command sets the application device to the partition C: for the specified operating system entry: bcdedit /set {cbd971bf-b7b8-4885-951a-fa03044f5d71} device partition=C: The following command sets the application path to \windows\system32\winload.exe for the specified operating system entry: bcdedit /set {cbd971bf-b7b8-4885-951a-fa03044f5d71} path \windows\system32\winload.exe The following command sets the NX policy to OptIn for the current operating system boot entry. bcdedit /set nx optin C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /displayorder {05a763ce-d81b-11db-b3ec-000000000000} /addfirst The operation completed successfully. C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /? displayorder This command sets the display order to be used by the boot manager. bcdedit /displayorder <id> [...] [ /addfirst | /addlast | /remove ] <id> [...] Specifies a list of identifiers that make up the display order. At least one identifier must be specified and they must be separated by spaces. For more information about identifiers, run "bcdedit /? ID". /addfirst Adds the specified entry identifier to the top of the display order. If this switch is specified, only a single entry identifier may be specified. If the specified identifier is already in the list, it will be moved to the top of the list. /addlast Adds the specified entry identifier to the end of the display order. If this switch is specified, only a single entry identifier may be specified. If the specified identifier is already in the list, it is moved to the end of the list. /remove Removes the specified entry identifier from the display order. If this switch is specified, only a single entry identifier may be specified. If the identifier is not in the list then the operation has no effect. If the last entry is being removed, then the display order value is deleted from the boot manager entry. Examples: The following command sets two OS entries and the NTLDR based OS loader in the boot manager display order: bcdedit /displayorder {802d5e32-0784-11da-bd33-000476eba25f} {cbd971bf-b7b8-4885-951a-fa03044f5d71} {ntldr} The following command adds the specified OS entry to the end of the boot manager display order: bcdedit /displayorder {802d5e32-0784-11da-bd33-000476eba25f} /addlast C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /default {05a763ce-d81b-11db-b3ec-000000000000} The operation completed successfully. C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /? default This command sets the default entry that the boot manager will use when the timeout expires. bcdedit /default <id> <id> Specifies the identifier of the boot entry to be used as the default when the time-out expires. For information about identifiers, run "bcdedit /? ID". Examples: The following command sets the specified entry as the default boot manager entry: bcdedit /default {cbd971bf-b7b8-4885-951a-fa03044f5d71} The following command sets the NTLDR based OS loader as the default entry: bcdedit /default {ntldr} C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /timeout 10 The operation completed successfully. C:\Windows\system32>
Code:
C:\Windows\system32>bcdedit /? timeout This command sets the time to wait, in seconds, before the boot manager selects a default entry. For information about setting the default entry, run "bcdedit /? default". bcdedit /timeout <timeout> <timeout> Specifies the time to wait, in seconds, before the boot manager selects a default entry. Example: The following command sets the boot manager <timeout> to 30 seconds: bcdedit /timeout 30 C:\Windows\system32> Code:
C:\Windows\system32>bcdedit Windows Boot Manager -------------------- identifier {bootmgr} device partition=C: description Windows Boot Manager locale en-US inherit {globalsettings} default {default} resumeobject {f4bad82f-d5dc-11db-b83c-fff6129dfa33} displayorder {default} {current} toolsdisplayorder {memdiag} timeout 10 customactions 0x10000ba000001 0x54000001 custom:54000001 {572bcd55-ffa7-11d9-aae0-0007e994107d} Real-mode Boot Sector --------------------- identifier {default} device boot path \openbsd.pbr description OpenBSD/i386 4.5 Windows Boot Loader ------------------- identifier {current} device partition=C: path \Windows\system32\winload.exe description Microsoft Windows Vista locale en-US inherit {bootloadersettings} osdevice partition=C: systemroot \Windows resumeobject {f4bad82f-d5dc-11db-b83c-fff6129dfa33} nx OptIn C:\Windows\system32> Questions and/or comments are welcomed. |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
OpenBSD 4.6 i386 boot hangs with old gateway system - resolved | comet--berkeley | OpenBSD Installation and Upgrading | 6 | 22nd July 2011 08:15 AM |
openbsd hangs momentarily at boot | bogd | OpenBSD General | 11 | 9th January 2009 02:53 PM |
MultiBooting OpenBSD. | bsdnewbie999 | OpenBSD Installation and Upgrading | 13 | 26th October 2008 12:00 PM |
download manager | graudeejs | General software and network | 11 | 16th October 2008 04:23 AM |
Dual-boot laptop won't boot OpenBSD after upgrade to 4.3 | kbeaucha | OpenBSD Installation and Upgrading | 17 | 30th May 2008 02:40 PM |