Skip to main content

Teams Powershell Issues : The term 'Get-CsTeamsMeetingPolicy' is not recognized as the name of a cmdlet


While trying to run the command Get-CSTeamsMeetingPolicy,  i received follwoing errrors on the domain joined machine.

PS C:\WINDOWS\system32> Get-CsTeamsMeetingPolicy

Get-CsTeamsMeetingPolicy : The term 'Get-CsTeamsMeetingPolicy' is not recognized as the name of a cmdlet, function,

script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is

correct and try again.

At line:1 char:1

+ Get-CsTeamsMeetingPolicy

+ ~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : ObjectNotFound: (Get-CsTeamsMeetingPolicy:String) [], CommandNotFoundException

    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\WINDOWS\system32> $sfbSession = New-CsOnlineSession

Please enter the user principal name (ex. User@Domain.Com): a@no.onmicrosoft.com

New-PSSession : [admin2e.online.lync.com] Connecting to remote server admin2e.online.lync.com failed with the

following error message : The WinRM client cannot process the request. Basic authentication is currently disabled in

the client configuration. Change the client configuration and try the request again. For more information, see the

about_Remote_Troubleshooting Help topic.

At C:\Program Files\Common Files\Skype for Business

Online\Modules\SkypeOnlineConnector\SkypeOnlineConnectorStartup.psm1:254 char:16

+ ...  $session = New-PSSession -Name $psSessionName -ConnectionUri $Connec ...                                         +                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                                                 + CategoryInfo          : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin     gTransportException                                                                                                      + FullyQualifiedErrorId : -2144108321,PSSessionOpenFailed


************************************************************************

Solution:

I used a non domain machine and these steps helped me to get the command working:

First of all install the Skype for business Powershell module :

Launch Powershell as admin and run these commands

Set-ExecutionPolicy unrestricted 

Import-Module "C:\\Program Files\\Common Files\\Skype for Business Online\\Modules\\SkypeOnlineConnector\\SkypeOnlineConnector.psd1"

 winrm set winrm/config/client/auth '@{Basic="True"}'

 $session = New-CsOnlineSession -Credential $cred

 Import-PSSession $session

 Get-CsTeamsMeetingPolicy

More information :

https://techcommunity.microsoft.com/t5/microsoft-teams/meeting-attendance-list/m-p/1327910

https://www.cloudfronts.com/microsoft-teams-powershell-module-overview/

http://kressmark.blogspot.com/2019/10/powershell-for-teams-management.html

Hope this helps


Comments

Popular posts from this blog

Citrix XenApp 6.5 Discovery fails Event 3989

Citrix XenApp 6.5 Service account password change caused console discovery to fail and we saw event ID 3989 in System Event logs "Citrix XenApp failed to connect to the Data Store. ODBC error while connecting to the database: 28000 -> [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed. The login is from an untrusted domain and cannot be used with Windows authentication." After changing the service account password needed to run the following command on the delivery controllers. DSMAINT CONFIG /user:abc\ABCSVCCitrix /pwd:nP@ssword /dsn:"C:\Program Files (x86)\Citrix\Independent Management Architecture\mf20.dsn" Restart IMA service You should now be able to run the discovery successfully Hope this helps

Group Policy Object did not apply because it failed with error code '0x80070534 No mapping between account names and security IDs was done

One of our servers was losing the Local Admin settings as we control them using GPO (restricted Groups) We were receiving the following event on this particular server : Event ID 4098 Application Event Log The computer 'Administrators (built-in)' preference item in the 'Servers Local Admins {odjd9DBD-22AF-48EA-ADF5-F42ADE4182hst}' Group Policy Object did not apply because it failed with error code '0x80070534 No mapping between account names and security IDs was done.' This error was suppressed. To fix the issue we deleted all the folders from the following location and rebooted the server C:\ProgramData\Microsoft\Group Policy\History Hope this helps.

DSS WSUS server fail to download Updates HTTP status 404: The requested URL does not exist on the server.

When managing a Downstream WSUS server , it may happen that when a patch is approved it tried to immediately download it form the source server (USS) Sometime we see errors in event viewer stating that the the download failed Event ID: 364 Content file download failed. Reason: HTTP status 404: The requested URL does not exist on the server. Source File: /Content/6E/72131F469F73C884B32124746BAFCA2C8E0A106E.cab Destination File: E:\WSUS\WsusContent\6E\72131F469F73C884B32124746BAFCA2C8E0A106E.cab Event ID 10032 The server is failing to download some updates. We also see following entries in softwaredistribution.log 2016-09-26 07:53:29.287 UTC Warning WsusService.3 ContentSyncAgent.ProcessBITSNotificationQueue ContentSyncAgent recieved Failure for Item: f52f0b8a-2b22-43cf-933e-af8de6b11eb6, Item fails 2016-09-26 07:53:29.287 UTC Info WsusService.3 ContentSyncAgent.ContentSyncSPFireStateMachineEvent ContentSyncAgent firing Event: FileDownloadFailed for Item: f5...