Set-CMDriverBootImage
Adds a driver to a boot image or removes a driver from a boot image.
Syntax
Set-CMDriverBootImage
-BootImageId <String>
-DriverId <Int32>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImage <IResultObject>
-DriverId <Int32>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImage <IResultObject>
-DriverName <String>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImage <IResultObject>
-Driver <IResultObject>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImageId <String>
-DriverName <String>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImageId <String>
-Driver <IResultObject>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImageName <String>
-DriverId <Int32>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImageName <String>
-DriverName <String>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-CMDriverBootImage
-BootImageName <String>
-Driver <IResultObject>
[-PassThru]
-SetDriveBootImageAction <SetDriveBootImageActionType>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Set-CMDriverBootImage cmdlet adds a driver to a boot image or removes a driver from a boot image. You can add Windows device drivers that you have imported into the Configuration Manager driver catalog to one or more boot images. You should add only mass storage device drivers and network adapter device drivers to boot images because other types of drivers are not needed and will increase the size of the boot image.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>
. For more information, see getting started.
Examples
Example 1: Add a driver to a boot image
PS XYZ:\> Set-CMDriverBootImage -SetDriveBootImageAction AddDriverToBootImage -DriverName "Adaptec Embedded SCSI HostRAID Controller" -BootImageName "Boot image (x64)"
This command adds the driver named Adaptec Embedded SCSI HostRAID Controller to the boot image named Boot image (x64).
Example 2: Remove a driver from a boot image
PS XYZ:\> Set-CMDriverBootImage -SetDriveBootImageAction RemoveDriverFromBootImage -DriverName "Adaptec SCSI HostRAID Management Processor Device" -BootImageName "Boot image (x64)"
This command removes the driver named Adaptec SCSI HostRAID Management Processor Device from the boot image named Boot image (x64).
Parameters
-BootImage
Specifies a CMBootImage object. To obtain a CMBootImage object, use the Get-CMBootImage cmdlet.
Type: | IResultObject |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BootImageId
Specifies the ID of a boot image.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BootImageName
Specifies the name of a boot image.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DisableWildcardHandling
This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Driver
Specifies a driver object. To obtain a CMDriver object, use the Get-CMDriver cmdlet.
Type: | IResultObject |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DriverId
Specifies the ID of a driver.
Type: | Int32 |
Aliases: | Id, CIId, CI_ID |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DriverName
Specifies the name of a driver.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ForceWildcardHandling
This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-PassThru
Add this parameter to return an object that represents the item with which you're working. By default, this cmdlet may not generate any output.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-SetDriveBootImageAction
Specifies the boot image action. The acceptable values for this parameter are:
- AddDriverToBootImage
- RemoveDriverFromBootImage
Type: | SetDriveBootImageActionType |
Accepted values: | AddDriverToBootImage, RemoveDriverFromBootImage |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet doesn't run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
Microsoft.ConfigurationManagement.ManagementProvider.IResultObject
Outputs
System.Object