Enterprise Application in maintenance mode

Hi,

I’m using squaredup V4 to create enterprise applications. Via the dashboard, I can set the whole application in maintenance mode. Can I do this also via powershell and how?

Thanks,

Kind regards,

Luc

Hi,

try this:

#Modify the Time if needed
$Time = ((Get-Date).AddMinutes(10))

#Replace "Name" with your Application Name
Get-SCOMClass -DisplayName "*Enterprise Application (Base)" | Get-SCOMClassInstance | Where-Object{$_.DisplayName -eq "Name"} | Start-SCOMMaintenanceMode -EndTime $Time

Kind regards