Dell Command Update – Install & Manage via PowerShell

So if you haven’t read my last post yet, Dell Command Update – pulling back the curtains – GARYTOWN ConfigMgr Blog, you should, as I go into how Dell Command Update (DCU) gets it’s feed of information under the hood. That is the basis for a lot of things I’ll be doing.

In this post, I’m going to cover a few Functions I’ve written for Installing, Managing and Running Dell Command Update. There are 3 that are the main functions, then other helper functions which the main ones use, but you could also use if you like.

My Demo machine is an OptiPlex 3090, SKU 0B8A, and the script is located on GitHub with a DNS forwarder for dell.garytown.com, which is how I load it quickly: iex (irm dell.garytown.com)

  • Install-DCU
  • Set-DCUSettings
  • Invoke-DCU
  • Get-DCUVersion
  • Get-DCUInstallDetails

So on my test machine, I just quick demo a couple of functions to show that DCU isn’t installed. Lets go ahead and run the Function to install it. Basically, using the magic of the last post, it’s looking of the DCU catalog for the device it is running on, then it pulls the URL, downloads and installs.

Install-DCU

So the Function provides a bit of output. Then after it completed, I ran Get-DCUVersion and Get-DCUInstallDetails just to show the information provided in those.

Set-DCUSettings

Next I’ll set a few different settings using Set-DCUSettings. Here is a list of the parameters I’ve created so far to help manage DCU. You’d basically run the Function for each setting you want to set, so if you want to set deferralInstallCount and autoSuspendBitlocker, you’d just run the function twice.

Lets take a look at some defaults when you install and first launch DCU

Now lets modify them with the function

Lets go back to the App and see how it looks

Ok, looks good, lets try a few more

So you’ll notice that you picked one setting, but then several others also get set. Some settings, like the deferrals have pre-req settings, so it will automatically set those as well.

Ok, so that’s nifty, you’ve been able to setup DCU with several settings with PowerShell, which makes it easy to then do with a Remediation Script.

Invoke-DCU

Now let’s just go ahead an run the Dell CLI, which can be 100% controlled by the command line that’s passed to it.

I’ll have DCU scan for driver updates:

Lets just let it run and install now, I’ll replace scan with -applyUpdates and let it go.

Lets take a look at the Programs, first a screenshot before I started, no DCU yet:

And now, DCU & the Intel Management Engine

So, now that you can do all this via PowerShell, you can turn this into remediations scripts to run from Intune or ConfigMgr, or any management system. This helps to simplify the management of Dell Command Update.

In a future post, I’ll cover additional functions around creating DCU offline Repos, setting DCU to use those repos and running DCU with them, all via PowerShell. (If I figure it out).

GARYTOWN

7 thoughts on “Dell Command Update – Install & Manage via PowerShell”

  1. Install-DCU tried to install version 4.9.0 when I already have 5.4.0 installed

    PS C:\Users\john> Get-DCUVersion
    5.4.0
    PS C:\Users\john> Install-DCU
    New Update available: Installed = Not Installed DCU = 4.9.0

    Reply
    • You can check the XML for that device, see if it has newer versions and then their might be a bug in the code. Hoewever, odds are good that the XML for that model doesn’t list a newer version than 4.9.0. I’ve run into that myself on my older test machines. I really wish Dell would have an API for their latest tool versions.

      Reply
      • Similar thing happened to me for a brand new Precision 3680 received from Dell in December 2024. DCU 5.4.0 was already pre-installed from the factory. Ran Install-DCU and it wanted to install DCU 4.3.0. I narrowed the issue down to the part of the function that compares if the detected available DCU version is greater than the currently installed DCU version. On my computer “CurrentVersion” variable was evaluating to empty string or null at the comparison in the IF statement. I think I fixed the issue by changing “If ($DCUVersionInstalled -ne $false){[Version]$CurrentVersion = $DCUVersionInstalled.Version}” to “If ($DCUVersionInstalled -ne $false){[Version]$CurrentVersion = [Version]$DCUVersionInstalled}” Now the function does not attempt to install DCU since the currently installed version if greater than the script detected available version from Dell. The CurrentVersion variable was now set to version value 5.4.0 after the fix. I was running the functions inside of PowerShell ISE if that makes any difference. I copied and pasted the whole Dell-CMSL.ps1 version 25.1.25.2 file into PowerShell ISE and then called the Install-DCU function at the bottom of that. Haven’t looked into why the function is only seeing DCU 4.3.0 available for this new of a computer.

        Reply
        • I’ve made some modifications to the script. Feel free to take a look and see if it is working now. I think I resolved the issue with only finding older DCU installers.

          Reply

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.