Ytria logo TUTORIALS

This website require JavaScript for full functionality. Please enable JavaScript in your Web browser.


Before you begin:

If you want to learn more about how Ytria's automation scripts function, see our automation basics help page.

Step 1 Copy/paste the script below into any text editor and save it as an XML file.
Step 2 Open replicationEZ and load the servers you want to check.
Step 3 From replicationEZ's Server menu, select the option 'Execute Automation File on...', select aclEZ from the list, select the servers you want to analyze, and then click 'OK'.
Step 4 Finally, find and select the XML file you just saved, and then click 'Open.'

Here is the script:

<ytriaAutomation Application="aclEZ" ApplicationVersion="16.5">
<!--This will set the script's behavior when encountering an error.
In this case, it will continue.-->
<onerror continue="true" />

<!--First it is specified that the NAB presence is NOT to be checked and groups are NOT
to be "expanded."-->
<Option Type="PresenceInNAB" value="false"/>
<Option Type="GroupExpander" value="ExpandNone"/>
<TreeSelectionLive Value="True"/>
<!--All databases on the current server will be deselected in the tree.-->
<unselect target="tree" server="true"/>

<!--Then the mail directory folder for the current server will be selected.-->
<select target="tree" folder="mail"/>

<!--The next part of the script defines the actions to be taken within the Audit grid.
The grid layout will be set as stated below.
A Suspend Grid Redraw function is added so the processing will be held off until
all columns are set.-->
<SuspendRedraw value="true"/>

<!--All columns are removed from the main grid in order to prepare for the columns
that will be added.-->

<!--The grid columns are moved to the first position in reverse order.
The name of the columns are indicated.-->
<Add ColumnID="DB6" Position="1"/><!-- Catalog Categories -->
<Add ColumnID="DB4" Position="1"/><!-- Database Type -->
<Add ColumnID="A9" Position="1"/><!-- Replicate or Copy Documents -->
<Add ColumnID="A8" Position="1"/><!-- Write Public Documents -->
<Add ColumnID="A7" Position="1"/><!-- Read Public Documents -->
<Add ColumnID="A6" Position="1"/><!-- Create LS/Java Agents -->
<Add ColumnID="A5" Position="1"/><!-- Create Shared Folder/Views -->
<Add ColumnID="A4" Position="1"/><!-- Create Private Folders/Views -->
<Add ColumnID="A3" Position="1"/><!-- Create Private Agents -->
<Add ColumnID="A2" Position="1"/><!-- Delete Documents -->
<Add ColumnID="A1" Position="1"/><!-- Create Documents -->
<Add ColumnID="ACL4" Position="1"/><!-- Type -->
<Add ColumnID="ACL1" Position="1"/><!-- Name -->
<Add ColumnID="DB3" Position="1"/><!-- Database File -->
<Add ColumnID="DB2" Position="1"/><!-- Database Path -->
<Add ColumnID="STATUS" Position="1"/><!-- Status -->
<!--Any residual grouping and sorting is cleared.-->

<!--A new grouping configuration is set.-->
<GroupBy ColumnID="ACL5"/><!-- Access -->
<GroupBy ColumnID="DB7"/><!-- Server -->

<!--And a new sorting configuration is set.-->
<Sort columnID="DB2" Ascending="true"/><!-- Database Path -->
<Sort columnID="DB4" Ascending="true"/><!-- Database Type -->
<Sort columnID="DB3" Ascending="true"/><!-- Database Filename -->

<!--A filter is added to isolate only mail owners,and then the grid processing is
reactivated by turning off
the Suspend Grid Redraw state.-->
<Filter columnID="ACL3" Empty="true"/><!-- Mail Owner -->
<SuspendRedraw value="false"/>

<!--The following If condition will test if the main grid has any rows loaded.
If there are any rows loaded (meaning that Mail Owners were found) the nested
child actions will be carried out.-->
<if target="Grid" test="VisibleRowsCount" Mode="GreaterThan" Value="0">

<!--The following If condition declares that if this script is not being used in a
loop, the Excel file will be opened as soon as it is generated.
This can't be done if a loop is being run since the Excel file still may need
to be worked on with the results of another server (depending on what you need
to do). Keep in mind that we can't set an If condition with a SetParam value,
hence the use of this variable.
The variable is initialised first, and it will be changed if not in a loop.-->
<SetVar vOpenExcelFile="False"/>
<if target="var" test="{%ListSize%}" mode="Equals" Value="">
<SetVar vOpenExcelFile="true"/>

<!--Finally, any findings regarding the databases and their respective mail owners,
and the rights those mail owners hold, will be exported.
Note that this report will be generated in the same location that this file
is being run from.-->
<SetParam field="FilePath" value="{%CurFilePath%}report_aclEZ.xlsx"/>
<SetParam field="SelectedRowsOnly" value="false"/>
<SetParam field="ExportType" value="Excel"/>
<SetParam field="Mode" value="AppendRows"/>
<SetParam field="ExcelSheetName" value="Email Owner Access"/>
<SetParam field="OpenFileOnceGenerated" value="{%vOpenExcelFile%}"/>