Documentation ¶
Overview ¶
Package boot facilitates communication with Intel® AMT devices to access and configure Boot Config Setting, Boot Service, and Boot Source Setting features of AMT.
ConfigSetting: A class derived from SettingData that provides the container to arrange all the BootSourceSetting instances in an ordered sequence. There can be one or more of the BootConfigSetting instances associated to a ComputerSystem. For example, one such BootConfigSetting could be a default boot configuration supplied by the manufacturer, a second one could be a configuration recommended by the IT Administrator. A third one could be the one actually to be used on next system boot.
Service: A class derived from Service that provides the controls to manage the boot configuration of a managed computer system or device. This includes changing the order of the boot devices and affecting settings on managed elements during the boot process. This service can also affect the load of a specific operating system on the computer system through a BootSourceSetting that points to a specific operating system image.
SourceSetting: A class derived from SettingData that provides the information necessary to describe a boot source. This may be optionally associated to a bootable logical device, such as a hard disk partition, or a network device. The information from this class instance is used by the boot manager, such as BIOS/EFI or OS Loader to initiate the boot process, when this instance appears in a BootConfigSetting collection.
Index ¶
- Constants
- Variables
- type Body
- type BootConfigSetting
- type BootService
- type BootSourceSetting
- type ChangeBootOrder_OUTPUT
- type ConfigSetting
- func (configSetting ConfigSetting) ChangeBootOrder(source Source) (response Response, err error)
- func (configSetting ConfigSetting) Enumerate() (response Response, err error)
- func (configSetting ConfigSetting) Get() (response Response, err error)
- func (configSetting ConfigSetting) Pull(enumerationContext string) (response Response, err error)
- type EnabledState
- type FailThroughSupported
- type OperationalStatus
- type PullResponse
- type RequestedState
- type Response
- type ReturnValue
- type Service
- func (service Service) Enumerate() (response Response, err error)
- func (service Service) Get() (response Response, err error)
- func (service Service) Pull(enumerationContext string) (response Response, err error)
- func (service Service) SetBootConfigRole(instanceID string, role int) (response Response, err error)
- type SetBootConfigRole_OUTPUT
- type Source
- type SourceSetting
Constants ¶
const ( CIMBootConfigSetting string = "CIM_BootConfigSetting" CIMBootSourceSetting string = "CIM_BootSourceSetting" CIMBootService string = "CIM_BootService" ChangeBootOrder string = "ChangeBootOrder" ValueNotFound string = "Value not found in map" SetBootConfigRole string = "SetBootConfigRole" )
Variables ¶
var FailThroughSupportedToString = map[FailThroughSupported]string{ FailThroughSupportedUnknown: "Unknown", FailThroughSupportedIsSupported: "IsSupported", FailThroughSupportedNotSupported: "NotSupported", }
FailThroughSupportedToString is a mapping of the FailThroughSupported value to a string.
var ReturnValueToString = map[ReturnValue]string{ ReturnValueCompletedNoError: "CompletedNoError", ReturnValueNotSupported: "NotSupported", ReturnValueUnknownError: "UnknownError", ReturnValueBusy: "Busy", ReturnValueInvalidReference: "InvalidReference", ReturnValueInvalidParameter: "InvalidParameter", ReturnValueAccessDenied: "AccessDenied", }
ReturnValueToString is a mapping of the ReturnValue value to a string.
Functions ¶
This section is empty.
Types ¶
type Body ¶
type Body struct { XMLName xml.Name `xml:"Body"` ConfigSettingGetResponse BootConfigSetting `xml:"CIM_BootConfigSetting"` SourceSettingGetResponse BootSourceSetting `xml:"CIM_BootSourceSetting"` ServiceGetResponse BootService `xml:"CIM_BootService"` EnumerateResponse common.EnumerateResponse PullResponse PullResponse `xml:"PullResponse"` ChangeBootOrder_OUTPUT ChangeBootOrder_OUTPUT `xml:"ChangeBootOrder_OUTPUT"` SetBootConfigRole_OUTPUT SetBootConfigRole_OUTPUT `xml:"SetBootConfigRole_OUTPUT"` }
Response Types.
type BootConfigSetting ¶
type BootConfigSetting struct { XMLName xml.Name `xml:"CIM_BootConfigSetting"` InstanceID string `xml:"InstanceID"` // Within the scope of the instantiating Namespace, InstanceID opaquely and uniquely identifies an instance of this class. To ensure uniqueness within the NameSpace, the value of InstanceID should be constructed using the following "preferred" algorithm: <OrgID>:<LocalID> Where <OrgID> and <LocalID> are separated by a colon (:), and where <OrgID> must include a copyrighted, trademarked, or otherwise unique name that is owned by the business entity that is creating or defining the InstanceID or that is a registered ID assigned to the business entity by a recognized global authority. (This requirement is similar to the <Schema Name>_<Class Name> structure of Schema class names.) In addition, to ensure uniqueness, <OrgID> must not contain a colon (:). When using this algorithm, the first colon to appear in InstanceID must appear between <OrgID> and <LocalID>. <LocalID> is chosen by the business entity and should not be reused to identify different underlying (real-world) elements. If the above "preferred" algorithm is not used, the defining entity must assure that the resulting InstanceID is not reused across any InstanceIDs produced by this or other providers for the NameSpace of this instance. For DMTF-defined instances, the "preferred" algorithm must be used with the <OrgID> set to CIM. ElementName string `xml:"ElementName"` // The user-friendly name for this instance of SettingData. In addition, the user-friendly name can be used as an index property for a search or query. (Note: The name does not have to be unique within a namespace.) }
Response Types.
type BootService ¶
type BootService struct { XMLName xml.Name `xml:"CIM_BootService"` Name string `xml:"Name"` // The Name property uniquely identifies the Service and provides an indication of the functionality that is managed. This functionality is described in more detail in the Description property of the object. CreationClassName string `xml:"CreationClassName"` // CreationClassName indicates the name of the class or the subclass that is used in the creation of an instance. When used with the other key properties of this class, this property allows all instances of this class and its subclasses to be uniquely identified. SystemName string `xml:"SystemName"` // The Name of the scoping System. SystemCreationClassName string `xml:"SystemCreationClassName"` // The CreationClassName of the scoping System. ElementName string `xml:"ElementName"` // A user-friendly name for the object. This property allows each instance to define a user-friendly name in addition to its key properties, identity data, and description information. Note that the Name property of ManagedSystemElement is also defined as a user-friendly name. But, it is often subclassed to be a Key. It is not reasonable that the same property can convey both identity and a user-friendly name, without inconsistencies. Where Name exists and is not a Key (such as for instances of LogicalDevice), the same information can be present in both the Name and ElementName properties. Note that if there is an associated instance of CIM_EnabledLogicalElementCapabilities, restrictions on this properties may exist as defined in ElementNameMask and MaxElementNameLen properties defined in that class. OperationalStatus []OperationalStatus `xml:"OperationalStatus"` // Indicates the current statuses of the element. Various operational statuses are defined. EnabledState EnabledState `xml:"EnabledState"` // EnabledState is an integer enumeration that indicates the enabled and disabled states of an element. RequestedState RequestedState `xml:"RequestedState"` // RequestedState is an integer enumeration that indicates the last requested or desired state for the element, irrespective of the mechanism through which it was requested. }
Response Types.
type BootSourceSetting ¶
type BootSourceSetting struct { XMLName xml.Name `xml:"CIM_BootSourceSetting"` ElementName string `xml:"ElementName"` // he user-friendly name for this instance of SettingData. In addition, the user-friendly name can be used as an index property for a search or query. (Note: The name does not have to be unique within a namespace.) InstanceID string `xml:"InstanceID"` // Within the scope of the instantiating Namespace, InstanceID opaquely and uniquely identifies an instance of this class. To ensure uniqueness within the NameSpace, the value of InstanceID should be constructed using the following "preferred" algorithm: <OrgID>:<LocalID> Where <OrgID> and <LocalID> are separated by a colon (:), and where <OrgID> must include a copyrighted, trademarked, or otherwise unique name that is owned by the business entity that is creating or defining the InstanceID or that is a registered ID assigned to the business entity by a recognized global authority. (This requirement is similar to the <Schema Name>_<Class Name> structure of Schema class names.) In addition, to ensure uniqueness, <OrgID> must not contain a colon (:). When using this algorithm, the first colon to appear in InstanceID must appear between <OrgID> and <LocalID>. <LocalID> is chosen by the business entity and should not be reused to identify different underlying (real-world) elements. If the above "preferred" algorithm is not used, the defining entity must assure that the resulting InstanceID is not reused across any InstanceIDs produced by this or other providers for the NameSpace of this instance. For DMTF-defined instances, the "preferred" algorithm must be used with the <OrgID> set to CIM. StructuredBootString string `xml:"StructuredBootString"` // A string identifying the boot source using the format "<OrgID>:<identifier>:<index>", in which neither <OrgID>, <identifier> or <index> contains a colon (":"). The value of <OrgID> is a copyrighted, trademarked or otherwise unique name that is owned by the entity defining the <identifier>, or is a registered ID that is assigned to the entity by a recognized global authority. For DMTF defined identifiers, the <OrgID> is set to 'CIM'. The <identifiers> are "Floppy", "Hard-Disk", "CD/DVD", "Network", "PCMCIA", "USB". The value of <index> shall be a non-zero integer. BIOSBootString string `xml:"BIOSBootString"` // BIOS description of the boot option. UTF8 null-terminated string, relevant only to One-Click Recovery WinRE and PBA (pre-boot application) boot options. BootString string `xml:"BootString"` // BIOS description of the EFI device path. UTF8 null-terminated string, relevant only to One-Click Recovery WinRE and PBA (pre-boot application) boot options. FailThroughSupported FailThroughSupported `xml:"FailThroughSupported"` // An enumeration indicating the behavior when the attempt to boot using the boot source fails (no media, timeout). }
Response Types.
type ChangeBootOrder_OUTPUT ¶
type ChangeBootOrder_OUTPUT struct {
ReturnValue ReturnValue `xml:"ReturnValue"`
}
Response Types.
type ConfigSetting ¶
type ConfigSetting struct {
// contains filtered or unexported fields
}
func NewBootConfigSettingWithClient ¶
func NewBootConfigSettingWithClient(wsmanMessageCreator *message.WSManMessageCreator, client client.WSMan) ConfigSetting
NewBootConfigSettingWithClient instantiates a new ConfigSetting.
func (ConfigSetting) ChangeBootOrder ¶
func (configSetting ConfigSetting) ChangeBootOrder(source Source) (response Response, err error)
ChangeBootOrder sets the boot order within a boot configuration.
An ordered array of BootSourceSetting instances is passed to this method. Each BootSourceSetting instance MUST already be associated with this BootConfigSetting instance via an instance of OrderedComponent. If not, the implementation MUST return a value of "Invalid Parameter" Upon execution of this method, the value of the AssignedSequence property on each instance of OrderedComponent will be updated such that the values are monotonically increasing in correlation with the position of the referenced BootSourceSetting instance in the source input parameter. That is, the first position in the array will have the lowest value for AssignedSequence. The second position will have the second lowest value, and so on. For BootSourceSetting instances which are associated with the BootConfigSetting instance via OrderedComponent and not present in the input array, the AssignedSequence property on the OrderedComponent association will be assigned a value of 0.
Additional Notes:
1) A boot source cannot be set if some special boot options were set in AMT_BootSettingData (such as UseSOL, UseIDER, ReflashBIOS, BIOSPause, BIOSSetup)
2) Parameter 'Source' changed in capitalization. Intel AMT Release 5.0 and earlier releases use 2.13.0 MOF version and therefor expect 'Source' parameter as 'source'.
3) Intel AMT Release 7.0: Returns WSMAN Fault = “access denied” if user consent is required but IPS_OptInService.OptInState value is not 'Received' or 'In Session'. An exception to this rule is when the Source parameter is an empty array.
func (ConfigSetting) Enumerate ¶
func (configSetting ConfigSetting) Enumerate() (response Response, err error)
Enumerate returns an enumeration context which is used in a subsequent Pull call.
func (ConfigSetting) Get ¶
func (configSetting ConfigSetting) Get() (response Response, err error)
Get retrieves the representation of the instance.
type EnabledState ¶
type EnabledState int
EnabledState is an integer enumeration that indicates the enabled and disabled states of an element.
const ( EnabledStateUnknown EnabledState = iota EnabledStateOther EnabledStateEnabled EnabledStateDisabled EnabledStateShuttingDown EnabledStateNotApplicable EnabledStateEnabledButOffline EnabledStateInTest EnabledStateDeferred EnabledStateQuiesce EnabledStateStarting EnabledStateIntelOneClickRecoveryAndIntelRPEAreDisabledAndAllOtherBootOptionsAreEnabled EnabledState = 32768 EnabledStateIntelOneClickRecoveryIsEnabledAndIntelRPEIsDisabledAndAllOtherBootOptionsAreEnabled EnabledState = 32769 EnabledStateIntelRPEIsEnabledAndIntelOneClickRecoveryIsDisabledAndAllOtherBootOptionsAreEnabled EnabledState = 32770 EnabledStateIntelOneClickRecoveryAndIntelRPEAreEnabledAndAllOtherBootOptionsAreEnabled EnabledState = 32771 )
func (EnabledState) String ¶ added in v2.2.4
func (e EnabledState) String() string
String returns the string representation of the EnabledState value.
type FailThroughSupported ¶
type FailThroughSupported int
FailThroughSupported is an enumeration indicating the behavior when the attempt to boot using the boot source fails (no media, timeout).
const ( FailThroughSupportedUnknown FailThroughSupported = iota FailThroughSupportedIsSupported FailThroughSupportedNotSupported )
func (FailThroughSupported) String ¶ added in v2.2.4
func (f FailThroughSupported) String() string
String returns the string representation of the FailThroughSupported value.
type OperationalStatus ¶
type OperationalStatus int
OperationalStatus is an enumeration indicating the current statuses of the element.
const ( OperationalStatusUnknown OperationalStatus = iota OperationalStatusOther OperationalStatusOK OperationalStatusDegraded OperationalStatusStressed OperationalStatusPredictiveFailure OperationalStatusError OperationalStatusNonRecoverableError OperationalStatusStarting OperationalStatusStopping OperationalStatusStopped OperationalStatusInService OperationalStatusNoContact OperationalStatusLostCommunication OperationalStatusAborted OperationalStatusDormant OperationalStatusSupportingEntityInError OperationalStatusCompleted OperationalStatusPowerMode OperationalStatusRelocating )
func (OperationalStatus) String ¶ added in v2.2.4
func (o OperationalStatus) String() string
String returns the string representation of the OperationalStatus value.
type PullResponse ¶
type PullResponse struct { BootSourceSettingItems []BootSourceSetting `xml:"Items>CIM_BootSourceSetting"` BootConfigSettingItems []BootConfigSetting `xml:"Items>CIM_BootConfigSetting"` BootServiceItems []BootService `xml:"Items>CIM_BootService"` }
Response Types.
type RequestedState ¶
type RequestedState int
RequestedState is an integer enumeration that indicates the last requested or desired state for the element, irrespective of the mechanism through which it was requested.
const ( RequestedStateUnknown RequestedState = 0 RequestedStateEnabled RequestedState = 2 RequestedStateDisabled RequestedState = 3 RequestedStateShutDown RequestedState = 4 RequestedStateNoChange RequestedState = 5 RequestedStateOffline RequestedState = 6 RequestedStateTest RequestedState = 7 RequestedStateDeferred RequestedState = 8 RequestedStateQuiesce RequestedState = 9 RequestedStateReboot RequestedState = 10 RequestedStateReset RequestedState = 11 RequestedStateNotApplicable RequestedState = 12 RequestedStateDisableIntelOneClickRecoveryAndIntelRPEAndEnableAllOtherBootOptions RequestedState = 32768 RequestedStateDisableIntelRPEAndEnableIntelOneClickRecoveryAndAllOtherBootOptions RequestedState = 32769 RequestedStateDisableIntelOneClickRecoveryAndEnableIntelRPEAndAllOtherBootOptions RequestedState = 32770 RequestedStateEnableAllBootOptions RequestedState = 32771 )
func (RequestedState) String ¶ added in v2.2.4
func (r RequestedState) String() string
String returns the string representation of the RequestedState value.
type Response ¶
type Response struct { *client.Message XMLName xml.Name `xml:"Envelope"` Header message.Header `xml:"Header"` Body Body `xml:"Body"` }
Response Types.
type ReturnValue ¶ added in v2.2.4
type ReturnValue int
ReturnValue is an enumeration indicating the return value of the operation.
const ( ReturnValueCompletedNoError ReturnValue = iota ReturnValueNotSupported ReturnValueUnknownError ReturnValueBusy ReturnValueInvalidReference ReturnValueInvalidParameter ReturnValueAccessDenied )
func (ReturnValue) String ¶ added in v2.2.4
func (r ReturnValue) String() string
String returns the string representation of the ReturnValue value.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewBootServiceWithClient ¶
func NewBootServiceWithClient(wsmanMessageCreator *message.WSManMessageCreator, client client.WSMan) Service
NewBootService returns a new instance of the BootService struct.
func (Service) Enumerate ¶
Enumerate returns an enumeration context which is used in a subsequent Pull call.
type SetBootConfigRole_OUTPUT ¶ added in v2.5.0
type SetBootConfigRole_OUTPUT struct {
ReturnValue ReturnValue `xml:"ReturnValue"`
}
Response Types.
type Source ¶
type Source string
const ( HardDrive Source = "Intel(r) AMT: Force Hard-drive Boot" CD Source = "Intel(r) AMT: Force CD/DVD Boot" PXE Source = "Intel(r) AMT: Force PXE Boot" OCRUEFIHTTPS Source = "Intel(r) AMT: Force OCR UEFI HTTPS Boot" OCRUEFIBootOption1 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 1" OCRUEFIBootOption2 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 2" OCRUEFIBootOption3 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 3" OCRUEFIBootOption4 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 4" OCRUEFIBootOption5 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 5" OCRUEFIBootOption6 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 6" OCRUEFIBootOption7 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 7" OCRUEFIBootOption8 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 8" OCRUEFIBootOption9 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 9" OCRUEFIBootOption10 Source = "Intel(r) AMT: Force OCR UEFI Boot Option 10" )
type SourceSetting ¶
type SourceSetting struct {
// contains filtered or unexported fields
}
func NewBootSourceSettingWithClient ¶
func NewBootSourceSettingWithClient(wsmanMessageCreator *message.WSManMessageCreator, client client.WSMan) SourceSetting
NewBootSourceSetting returns a new instance of the BootSourceSetting struct.
func (SourceSetting) Enumerate ¶
func (sourceSetting SourceSetting) Enumerate() (response Response, err error)
Enumerate returns an enumeration context which is used in a subsequent Pull call.