MSEndpointMgr / ConfigMgr

Microsoft Endpoint Configuration Manager scripts and tools
637 stars 280 forks source link

Error Code List #253

Open chaosisbliss opened 4 years ago

chaosisbliss commented 4 years ago

I remember there being a list of error codes on the old site that we could use to help identify issues. I cannot seem to find that list anymore. Since updating to 6.4.8 and using verion 3.0.4 Invoke-CMApplyDriverPackage.ps1, I seem to be getting error code 1 on 90% of images.

NickolajA commented 4 years ago

Since version 3.x the error codes was removed and replaced by a single error 1. Check the real error as it should be outputted to the ApplyDriverPackage.log file.

chaosisbliss commented 4 years ago

Ah. Thanks for the quick response. I've looked at about 50 different ApplyDriverPackage logs as I have them dumped at the end of the task sequence. They don't indicate the issue. Processing driver package with 4 detection methods: Drivers - Driver package name. Then goes to the next line, Apply Driver package failed, please refer to previous error or warning messages. Everything prior is successful. It detects the model, sku, target build.

NickolajA commented 4 years ago

https://github.com/MSEndpointMgr/ModernDriverManagement/blob/master/Invoke-CMApplyDriverPackage_Legacy.ps1

Please try version 3.0.6 (remember to rename the file and the remove the '_Legacy' part). It should contain, hopefully, a bit more logging information for where I believe the error to occur.

chaosisbliss commented 4 years ago

Great ! Thank you sir! I've got everything copied over and will keep you updated.

chaosisbliss commented 4 years ago

It is saying the invoke-cmapplydriverpackage.ps1 to the -File parameter does not exist. Provide the path to an existing .ps1 file argument to the -File parameter. Failed to run the action. Error -196608.

I guess it does not like the -File paramter below? I have had it this way for almost a year now. I have all of the powershell scripts in a package and deploying through a run command line. I was having issues in the beginning with the TS.Environment.Variable where it would fail if I did not call it this way and disable 64 bit file system redirection.

%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -WindowStyle Hidden -ExecutionPolicy Bypass -File Invoke-CMApplyDriverPackage.ps1 -URI "http://FQDN/ConfigMgrWebService/ConfigMgr.asmx" -SecretKey "MySecretyHere" -Filter "Drivers" -DeploymentType DriverUpdate -TargetOSVersion "18363"

NickolajA commented 4 years ago

I'd assume the same error is present in the ApplyDriverPackage.log, could you verify and paste a screenshot of it?

chaosisbliss commented 4 years ago

My fault on the above error code. I put and underscore instead of a hypen when changing the new script. We're back to the original error code 1 message.

SMSTS.log image

ApplyDriverPackage.log image

vbateman commented 4 years ago

I just noticed something, why are you running this as install software, when you could just use the action in OSD to run powershell. Could that be the problem.

vbateman commented 4 years ago

powershell

chaosisbliss commented 4 years ago

I have two different options to install drivers and firmware both of which are producing the same error. I have one that is used during PXE to install drivers and firmware. Logs are showing the same errors. The second one is used Post PXE so our support reps can update machines while windows is installed. Logs are showing the same errors.

It's a run command line, and I have another that is run powershell. Both are having the same issue.

NickolajA commented 4 years ago

What you're doing is right, there's something about the package it's processing that the code doesn't like and bails out. I thought it was in the part where it constructs a custom object of all driver package properties that's combined with local data of the device used for the matching process in the next phase. It might be the later stage where it does some HP 'magic' that's required. Let me download that package and run it in debug mode and get back to you. In the meantime, could you please take a screenshot of the properties of the package from ConfigMgr?

chaosisbliss commented 4 years ago

Good deal. That makes me feel better. When I upgraded to 6.4.8, I deleted all source packages and removed everything from SCCM and started over.

image

chaosisbliss commented 4 years ago

Just making sure I didn't miss any updates to the invoke package. Should we revert back to the older version for the time being?

chaosisbliss commented 4 years ago

I had to revert back to the 2.2.7 invoke-applydriverpackage.ps1 file.

Ar5had07 commented 4 years ago

I am having the same problem. I can't build any devices atm.

image image

NickolajA commented 4 years ago

I may have found an issue where HP have not done their homework really, and put a space-char instead of a comma-space in the list of SKU's. The script has been updated to 3.0.7, but only available in the new repo:

https://github.com/MSEndpointMgr/ModernDriverManagement/blob/master/Invoke-CMApplyDriverPackage_Legacy.ps1

Not sure if this is the same issue that you're describing here though.

@Ar5had07: Your log shows that the script crashes on the 1040 G4 driver package, could you post the package properties of that?

NickolajA commented 4 years ago

I've found the issue causing this behavior and we're working on a fix. Stay tuned.

Ar5had07 commented 4 years ago

I may have found an issue where HP have not done their homework really, and put a space-char instead of a comma-space in the list of SKU's. The script has been updated to 3.0.7, but only available in the new repo:

https://github.com/MSEndpointMgr/ModernDriverManagement/blob/master/Invoke-CMApplyDriverPackage_Legacy.ps1

Not sure if this is the same issue that you're describing here though.

@Ar5had07: Your log shows that the script crashes on the 1040 G4 driver package, could you post the package properties of that?

Here you go

image

Ar5had07 commented 4 years ago

I may have found an issue where HP have not done their homework really, and put a space-char instead of a comma-space in the list of SKU's. The script has been updated to 3.0.7, but only available in the new repo:

https://github.com/MSEndpointMgr/ModernDriverManagement/blob/master/Invoke-CMApplyDriverPackage_Legacy.ps1

Just tried the Legacy.ps1 and same error

NickolajA commented 4 years ago

Yup, that's the exact error. I've spoken with Maurice too so that we verify it's not a change in how HP is exposing their data in the XML feed. Anyway, we now know what the issue is and you can expect a fix shortly.

NickolajA commented 4 years ago

Check out version 3.0.8 that was just committed, it shouldn't crash like this in that version.

Ar5had07 commented 4 years ago

Check out version 3.0.8 that was just committed, it shouldn't crash like this in that version.

Thank you, that's now working. But the detection of models isn't. It's not detecting HP 800 G2 Small Form Factor

image

Ar5had07 commented 4 years ago

Check out version 3.0.8 that was just committed, it shouldn't crash like this in that version.

I renamed the package in ConfigMgr to force it to match, but failed somewhere else.

image

Ar5had07 commented 4 years ago

^ it crashed on 800 G3 because it didn't have a models in the description. I deleted that package. I ran the script again and this time, this error.

image

NickolajA commented 4 years ago

Version 3.x of the script should have filtered out driver packages that didn't have any data in the Comments/Description field, could you verify it did? It's logged right before the processing starts.

Are you using the -TargetOSVersion "18363" parameter with input for 1909, so that it's able to detect?

Ar5had07 commented 4 years ago

-TargetOSVersion "18363"

Right, it's now working when I add the TargetOSVersion, but it's not filtering out packages that don't have Comments/Description. (I've had to delete a package that dont have comments for it to work) This is the beginning of the log image

tunnelofsludge commented 4 years ago

I also seem to show that adding -TargetOSVersion "18363" to the command line, works. This may cause older driverpacks (1809/1903) to fail, but I haven't tested it.