DocumentConfigMgrCB
DocumentConfigMgrCB copied to clipboard
Error in function Get-PWCMCoMgmtAdminCenterDeviceUploadStatus
I always get an error from the command in line 2972:
Invoke-CimMethod : The WS-Management service cannot process the request because it contains an invalid character. WS-Management cannot convert the string to a number. String: true. Ensure that the string represents the correct datatype. At D:\Tools\DocumentConfigMgrCB-master\DocumentCMCB.ps1:2972 char:34
- ... onMapping = Invoke-CimMethod -Namespace "ROOT\SMS\site_$SiteCode" -Ci ...
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- CategoryInfo : ProtocolError: (ROOT\SMS\site_xxx:SMS_CoMgmtConfigs:String) [Invoke-CimMethod], CimExcep tion
- FullyQualifiedErrorId : HRESULT 0x80338041,Microsoft.Management.Infrastructure.CimCmdlets.InvokeCimMethodCommand
- PSComputerName : SiteServer.domain.yyy
@NorbertBauer, is your SiteCode a number like 001
? If so, try quoting it in the command line parameter to force it to be typed as a string.
No, the SiteCode is like "AB1"
It looks like you can get that same error if you do not have the AAD Tenant ID defined in CM. So, perhaps something missing in the co-management configuration in your site? Hard to say. I don't have access to a fully configured CM environment anymore. Job has changed and I don't spend much time with it anymore, so it's all a bit fuzzy.
When I run the commands in this function one by one, then I can get the AAD tenant ID but this command also fails, even if I can see all variables have correct values.
Gesendet von Outlook für iOShttps://aka.ms/o0ukef
Von: Paul Wetter @.> Gesendet: Saturday, February 25, 2023 1:51:18 AM An: paulwetter/DocumentConfigMgrCB @.> Cc: NorbertBauer @.>; Mention @.> Betreff: Re: [paulwetter/DocumentConfigMgrCB] Error in function Get-PWCMCoMgmtAdminCenterDeviceUploadStatus (Issue #103)
It looks like you can get that same error if you do not have the AAD Tenant ID defined in CM. So, perhaps something missing in the co-management configuration in your site? Hard to say. I don't have access to a fully configured CM environment anymore. Job has changed and I don't spend much time with it anymore, so it's all a bit fuzzy.
— Reply to this email directly, view it on GitHubhttps://github.com/paulwetter/DocumentConfigMgrCB/issues/103#issuecomment-1444826179, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKOR7FPK6JGOSVM4INB4KQ3WZFJQNANCNFSM6AAAAAAVFM4SWI. You are receiving this because you were mentioned.Message ID: @.***>
Anyway, maybe I can spend some time in different customer environments to test, check and maybe find a solution for this one.
Gesendet von Outlook für iOShttps://aka.ms/o0ukef
Von: Paul Wetter @.> Gesendet: Saturday, February 25, 2023 1:51:18 AM An: paulwetter/DocumentConfigMgrCB @.> Cc: NorbertBauer @.>; Mention @.> Betreff: Re: [paulwetter/DocumentConfigMgrCB] Error in function Get-PWCMCoMgmtAdminCenterDeviceUploadStatus (Issue #103)
It looks like you can get that same error if you do not have the AAD Tenant ID defined in CM. So, perhaps something missing in the co-management configuration in your site? Hard to say. I don't have access to a fully configured CM environment anymore. Job has changed and I don't spend much time with it anymore, so it's all a bit fuzzy.
— Reply to this email directly, view it on GitHubhttps://github.com/paulwetter/DocumentConfigMgrCB/issues/103#issuecomment-1444826179, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKOR7FPK6JGOSVM4INB4KQ3WZFJQNANCNFSM6AAAAAAVFM4SWI. You are receiving this because you were mentioned.Message ID: @.***>
Possible it's changed. What build of CM you getting the errors in?
CM 2207
Gesendet von Outlook für iOShttps://aka.ms/o0ukef
Von: Paul Wetter @.> Gesendet: Saturday, February 25, 2023 9:11:17 AM An: paulwetter/DocumentConfigMgrCB @.> Cc: NorbertBauer @.>; Mention @.> Betreff: Re: [paulwetter/DocumentConfigMgrCB] Error in function Get-PWCMCoMgmtAdminCenterDeviceUploadStatus (Issue #103)
Possible it's changed. What build of CM you getting the errors in?
— Reply to this email directly, view it on GitHubhttps://github.com/paulwetter/DocumentConfigMgrCB/issues/103#issuecomment-1445026969, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKOR7FPSR5U6FTQWKW7FBITWZG5CLANCNFSM6AAAAAAVFM4SWI. You are receiving this because you were mentioned.Message ID: @.***>
On the co-management configuration, could you provide the details here. It is failing in collecting that page details. It seems it throws that error if wmi query has an incorrect tenant ID. Can you confirm that matches what was configured? Maybe there are other issues too.. But, that is what i'm seeing.
on this page, all settings are enabled and all devices are uploaded. Also the TenantID, that the Script reads from WMI ist the same, as shown in the console. And with each WMI query within this function, I do only get one Item, so there should be no issue with that.
Ahhh... We do not specify "Upload specific collection" and therefore, this WMI Method will not find a Collection. Maybe the error is "by design" in that case?