Skip to content

Josh's IT-Blog

Information Technology, and other interesting things …

  • Home
  • About
  • Contact
  • Links

Windows Azure Pack doesn’t show Automation dashboard after updating SMA

Posted on 20. February 202020. October 2020 By Burkard Josh
SMA, System Center

this days, I updated Service Management Automation (SMA) in our production environment from version 2016 UR7 to version 2019.

after the update, I had an issue with Windows Azure Pack, which couldn’t display the dashboard for the Automation provider.

after some research, i found out, that the root cause was some months earlier. we have a lot of concurrent jobs running and some times the SMA workers was overloaded and all new jobs where hanging in the queue. the solution I found on some other websites, was to mark this queued jobs as failed inside the database and then restart the worker service:

USE SMA

-- New Jobs
UPDATE [Core].[Jobs] SET StatusID=5 WHERE StatusID=1

-- Running Jobs
UPDATE [Core].[Jobs] SET StatusID=5 WHERE StatusID=3

-- Suspended Jobs
UPDATE [Core].[Jobs] SET StatusID=5 WHERE StatusID=8

after setting this jobs to failed state, I had to configure the Runbook worker to start only one Runbook per Sandbox process in the file C:\Program Files\Microsoft System Center\Service Management Automation\Orchestrator.Settings.config:

<add key="MaxRunningJobs" value="1"/>
<add key="TotalAllowedJobs" value="1"/>

the Runbook worker could now be restarted and was working properly again. Stability was much better, than before.

unfortunately, there is an other problem, with the workaround of setting the jobs to failed. every 15 minutes the SMA database executes a Purge Job, to remove old Job entries and all stream datas for this old jobs. but this Purge Job is removing only Jobs with a valid EndDate, which is still NULL when you set the Job to failed with the query above. in my case i had over 15000 old jobs inside the database.

to set hanging jobs to failed, you should use this query:

USE SMA
 
-- New Jobs
update [Core].[Jobs] set StatusID=5, EndTime=LastModifiedTime where StatusID=1

-- Running Jobs
update [Core].[Jobs] set StatusID=5, EndTime=LastModifiedTime where StatusID=3

-- Suspended Jobs
update [Core].[Jobs] set StatusID=5, EndTime=LastModifiedTime where StatusID=8

this query sets the hanging jobs to failed inside the Jobs table and sets the EndTime, which is important for the Purge Job. After this, the Purge Job will run for some minutes and will remove the 1000  oldest jobs per batch until the defined age. you can define the age of the oldest jobs with the commandlet Set-SmaAdminConfiguration.

after all old jobs where removed, my Windows Azure Pack was working again properly

Share this:

  • Facebook
  • Twitter
  • Email
  • Print

Post navigation

❮ Previous Post: getting Security Scopes of SCCM folder
Next Post: remove sensitive files from GIT ❯

About

Author Image
My name is Josh Burkard.
I'm a DevOps Engineer working with one of swiss largest telecom and full-service hosting provider. in my work I have a lot to do with Microsoft server operating systems, System Center, VMware, Microsoft Azure Cloud and other software.
On this site I will write some posts about different technology problems and their solutions.
please note also my tweets and retweets from this area.

Follow me on Twitter

My Tweets

Categories

  • General (13)
  • Hardware (9)
    • Network (8)
      • Cisco (2)
    • Storage (2)
  • Microsoft Azure (1)
    • Automation (1)
  • PowerShell (1)
  • Software (1)
    • Excel (1)
  • System Center (19)
    • SCCM (3)
    • SCDPM (1)
    • SCOM (13)
    • SCSM (1)
    • SMA (1)
  • VMware (8)
  • Windows 2008 R2 (10)
    • Active Directory (7)
  • Windows 2012 R2 (1)
  • Windows 2016 (1)
  • Windows 7 (4)
    • BitLocker (1)
  • WordPress (1)

Links

  • Burkard-Fingerlin Family
  • Swisscom (Schweiz) AG
Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

About

Author Image
My name is Josh Burkard.
I'm a DevOps Engineer working with one of swiss largest telecom and full-service hosting provider. in my work I have a lot to do with Microsoft server operating systems, System Center, VMware, Microsoft Azure Cloud and other software.
On this site I will write some posts about different technology problems and their solutions.
please note also my tweets and retweets from this area.

Follow me on Twitter

My Tweets

FOLLOW ME ON GITHUB

joshburkard (Josh Burkard)

Josh Burkard

joshburkard
Belgium
https://www.burkard.it
Joined on Jul 10, 2015
13 Public Repositories
0 Public Gists

Copyright © 2023 Josh's IT-Blog.

Theme: Oceanly by ScriptsTown

 

Loading Comments...
 

    loading Cancel
    Post was not sent - check your email addresses!
    Email check failed, please try again
    Sorry, your blog cannot share posts by email.