FIM - How to obtain pending exports from a MA

I promised a colleague I would post my script on parsing the "Pending Exports"  from a management agent via the "Log File and Stop" Export run profile.

The script parses through the XML document and creates a report (which can be loaded into Excel after saving as a CSV) to sort and report on any objects with an EAF or that are being added/deleted/modified in that particular MA.

This is typically most useful after performing a Full Sync due to deploying a big change, new management agent, adding an attribute-flow, changing precedence or go-live. Since I wanted to explain it more in detail, I posted it on my blog, but feel free to add it to the scriptbox if you think its helpful.

FIM - Export Pending Changes

Update:

I ended up writing and posting my c# console application in addition to the script, after working on a project with some ECMA. The script can parse the MA Export XML file and the c# console app can parse the CSExport.exe XML file, for more details refer to the blog post. 

P.S. There may be a few bugs; for those of you that use either the script or program, let me know if you encounter any issues.

December 1st, 2012 12:21am

I wholeheartedly agree with that approach and do much the same -- of course using SQLXML capabilites in SQL Server (I know SQL and runs really fast). When I get a chance I will give this a whirl.

It looks like this is a nice contribution to the community!

Free Windows Admin Tool Kit Click here and download it now
December 5th, 2012 9:41am

I got a memory error (my XML file was 500MB+)

Error: Exception of type 'System.OutOfMemoryException' was thrown.

I tried with and without the showModifications switch.

csExport doesn't have a notion of -resultSize, so perhaps your parser could?

July 18th, 2014 6:01am

Nice one! I've written something similar and also got some inspiration from Carols scripts and used C# to write the pending export details into a Word document. If you're running live, it's also cool if you can use wmi to grab the operation log that corresponds to the export log and parse that as well so you get a view of any errors that occurred during the export.

If you're just looking at one pending export as a once off type of thing though, I've found the easiest way to do it is to use Excels (2010) built in xml parser. Just open a new excel doc and drag the xml file on top. You get three options, I use the first and you get a great view with columns that you can filter on. :)

Free Windows Admin Tool Kit Click here and download it now
July 18th, 2014 6:22am

Mike,

If the problem is with CSExport generating the file then another approach would be to create an export profile that stops and drops a file. The structure is a little different but very similar.

If the issue is with using Paul's script to transform it then you could try what Dan says about Excel. I have seen some colleagues get excellent results just dragging the file into Excel.

David

July 18th, 2014 5:40pm

I forgot I had that script posted and haven't updated it since I wrote it. I think the XML format from the CSExport utility has changed slightly so i'm not sure how accurate it is. Recently I've created a compiled C# library that will validate the schema against XSD and extract out the different hologram information (pending exports/imports, synchronized data, etc..). The library I'm working on will also help when you have a 1GB+ xml document by parsing through it versus throwing it in memory.

Free Windows Admin Tool Kit Click here and download it now
July 25th, 2014 12:58pm

Looking forward to seeing it, thanks Paul!
July 25th, 2014 4:51pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics