Article ID: 126745, created on Aug 30, 2015, last review on Aug 30, 2015

  • Applies to:
  • Operations Automation 6.0
  • Operations Automation 5.5

Symptoms

The task Protect Calendar folder for mailbox fails with the error:

Provisioning request failed. Call of method "SW Managed Exchange::ProtectMailboxCalendarFolder" failed.
Type: Parallels.Wpe.Utils.WpeProcedureException.

Inner exception(s):
-------------------
The term 'LogWarning' 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.

Error position: At C:\Program Files\Parallels\Windows Provisioning Engine\Providers\SW Managed Exchange\ProtectMailboxCalendarFolder.ps1:59 char:5
+ LogWarning("[ProtectMailboxCalendarFolder] 'Add-MailboxFolderPermission' for ...
+ ~~~~~~~~~~

Type: Parallels.Wpe.PowerShell.PowerShellException.

-------------------
The term 'LogWarning' 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.
Type: System.Management.Automation.CommandNotFoundException.

Cause

Bug POA-93023

Resolution

The issue has been fixed in OA update 6.0.5 https://kb.odin.com/en/126467. Please schedule the installation of this update to fix the issue.

The issue occurs because of syntax error in WPE .ps scripts:

C:\Program Files\Parallels\Windows Provisioning Engine\Providers\Common\ProviderUtils\ProviderUtils.psm1 defines LogWarn function:

....
288 function LogWarn(
289     [Parameter(Position=0, Mandatory=$true)]
290     [string]$Message)
....
643 Export-ModuleMember LogDebug, LogInfo, LogWarn, LogError, LogObject, LogStart, LogStop
....

However, the file C:\Program Files\Parallels\Windows Provisioning Engine\Providers\SW Managed Exchange\ProtectMailboxCalendarFolder.ps1 refers to a slightly different name - LogWarning:

....
59                              LogWarning("[ProtectMailboxCalendarFolder] 'Add-MailboxFolderPermission' for group '{0}' failed with error '{1}'" -f  $organizationGroupDN,$_.Exception.Message)
....

To workaround the issue, change LogWarning to LogWarn in the file ProtectMailboxCalendarFolder.ps1.

Search Words

logwarning is not

Failed task

the term 'LogWarning' is not recognized

task

5356b422f65bdad1c3e9edca5d74a1ae caea8340e2d186a540518d08602aa065 e12cea1d47a3125d335d68e6d4e15e07 956c448bddc7e1f3585373687602379f 6f1456866eed87488c0f02b298a741c0 5b048d9bddf8048a00aba7e0bdadef37 2554725ed606193dd9bbce21365bed4e

Email subscription for changes to this article
Save as PDF