Social

torsdag den 16. januar 2014

Renaming configurations/connections

When working with Orchestrator in a production environment you develop your runbooks in a development environment (if not, you should start doing that right now!). More often than not the configurations for various IPs have different names than the ones in the production environment, which means the runbook will fail to run when moved. Anders Asp have provided a solution in which you edit the ois file prior to importing.

But why not just align the configurations names in the first place and be done with it? The obvious answer is: "I have hundreds of activities using the same configurations . It will take me days of work to change them all".

Well you could just change it all with a simple SQL-query. Some IPs uses QIK (ex. the AD IP), in which the configurations only needs to be renamed in a single table. dbo.QIKOBJECT will list all activities using a QIK-configuration. Update this using the query below:

UPDATE [Orchestrator].[dbo].[QIKOBJECT]
SET Configuration = 'New configuration name'
FROM [Orchestrator].[dbo].[QIKOBJECT] WHERE Configuration = 'Old configuration name'

Easy as that - now manually rename the configuration in the Runbook Designer! Remember to backup and test this in a non-production environment. Optimally you will never need to do this in production and just align the configuration names in all other environments with the names in production.

Not all IPs uses QIK (ex. the SCSM2012 IP). Here you will have to update a table for each activity. For SCSM2012 IP the tables are called SCSM2012_*. The approach is the same as the one above with a slight twist. I am no SQL-expert, but there is a type-clash in the WHERE clause, hence you will need to convert the Connection column:

DECLARE @NewConnection NVARCHAR(MAX)
SET @NewConnection = N'connection_new'

DECLARE @OldConnection NVARCHAR(MAX)
SET @OldConnection = N'connection_old'

UPDATE [Orchestrator].[dbo].[SCSM2012_XXX]
SET Connection = @NewConnection
FROM [Orchestrator].[dbo].[SCSM2012_XXX] WHERE CONVERT(NVARCHAR(MAX), Connection) = @OldConnection

Replace XXX with the proper tablename, and whatever the connections are called.

You may have to refresh the runbooks in the Runbook Designer before the changes kicks through. It may be a caching issue. I have had activities abort a few times and then suddenly work by themselves (usually within a few minutes after executing the query). Lesson to learn: Go to lunch after you run the query :D

tags: Orchestrator, OIP, Configuration, Connection, export, import

søndag den 12. januar 2014

Slow Management Pack Import during Installation of SCSM 2012

Ever since I decided to reinstall test/development-environment with a dedicated SQL-server I have been having trouble. At first the MPs wouldn't even import during Service Manager installation, and eventually it would timeout and rollback the entire installation. Then I figured out that if I set the default database size to somewhat more than 2000 mb (I think anywhere from 3500-5000 did the trick) the MP importing suddenly worked, although very slow (anywhere between 1 minute to several minutes to import a single MP or MPB).  After installation (takes several hours) it would take up to 30 seconds to create an empty MP in the console. More details described here: Technet.
Since then I had reinstalled my entire server, put it into a box due to me moving, and I have finally gotten around to taking it out of the box and setting it up. And I figured out what the problem was!

Setting the maximum (and minimum) memory allowed for a SQL instance did the trick! The SQL-server was simply starving the OS for memory, and I guess the increased DB-size somehow gave it a (slow) disk-buffer, allowing it to import MPs, but at a very reduced speed.

If you have a limited setup this is something you want to do before even starting the installation. I suggest Googling/Binging/(Insert your favorite search engine and add 'ing' to the name) best practices and such. Then go ahead with installing your favorite System Center component ;)

Anyways, hope for and expect more frequent updates from now on.

Søg i denne blog