mrichardson1

updated

18 years ago

M

mrichardson1

1 Message

0

1741

July 16th, 2008 04:00

Merging CX Analyzer Logging

Hi there,

I am wondering how I can automate the delivery of my analyzer logs on my cx340 and cx320's.

At the moment I manually look a the logs but it would be useful to be able to automate the merging of say a weeks worth of logs and then have them emailed to me ?

Is this possible please.

Thanks in advance.

Regards
Mark
  • AranH1

    2163 Posts

    527

    0

    Posted July 16th, 2008 13:00

    Mark,
    Like ovivier I collect the analyzer files but don't merge them. I keep about two months worth of .nar files for historical analysis of the array. My management station is a windows host and I use the scheduler to run the following batch script every day.

    -------- Begin Script ------
    REM Analyzer Archive Retrieve Script

    @echo off

    echo Dumping analyzer data from SPA on all arrays...

    cd "C:\Program Files\EMC\Navisphere CLI"

    naviseccli -h w.x.y.z analyzer -archiveretrieve -file Cx3-80a_SPA.nar -location c:\SAN\Analyzer\Cx3-80a -Overwrite y -Retry 2 -v

    naviseccli -h w.x.y.z analyzer -archiveretrieve -file Cx700a_SPA.nar -location c:\SAN\Analyzer\Cx700a -Overwrite y -Retry 2 -v

    naviseccli -h w.x.y.z analyzer -archiveretrieve -file Cx700b_SPA.nar -location c:\SAN\Analyzer\Cx700b -Overwrite y -Retry 2 -v

    naviseccli -h w.x.y.z analyzer -archiveretrieve -file Cx3-20a_SPA.nar -location c:\SAN\Analyzer\Cx3-20a -Overwrite y -Retry 2 -v

    echo Renaming files to inlcude date stamp

    FOR /F "TOKENS=1* DELIMS= " %%A IN ('DATE/T') DO SET CDATE=%%B
    For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set date=%%a%%b%%c)

    ren c:\SAN\Analyzer\Cx3-80a\Cx3-80a_SPA.nar "%date%_Cx3-80a_SPA.nar"

    ren c:\SAN\Analyzer\Cx700a\Cx700a_SPA.nar "%date%_Cx700a_SPA.nar"

    ren c:\SAN\Analyzer\Cx700b\Cx700b_SPA.nar "%date%_Cx700b_SPA.nar"

    ren c:\SAN\Analyzer\Cx3-20a\Cx3-20a_SPA.nar "%date%_Cx3-20a_SPA.nar"

    exit

    ----- End Script ----

    As you can see I only collect .nar files from SPA since I don't need files from both SPs to collect and analyze array performance. This way I don't have to worry about merging files from different SPs. Also since the naviagent and array are on FLARE 26 I use naviseccli. But the user profile that the script is run under has a authorization file already created so authentication is handled using that method.
  • ovivier

    142 Posts

    448

    1

    Posted July 16th, 2008 05:00

    Hi Mark,

    I have automated the daily copy of NAR files to a UNIX directory :
    - install Analyzer CLI
    - write a script using archiveretrieve.jar (included in Analyzer CLI) which collect the NAR files from each SP of your CX.
    - put the script in a scheduler

    I have seen that you can use archivemerge.jar (also included in Analyzer CLI) to merge NAR files, but I have never used it as I want to keep maximum information. When you merge NAR files you have less points in graphics.

    Hope this help
  • kelleg

    6 Operator

    •

    4537 Posts

    448

    1

    Posted July 16th, 2008 12:00

    Remember to not merger SPA and SPB NAR files, only SPA to SPA or SPB to SPB.

    Also, the number of data points displayed when you open a NAR file is fixed - about 255 points. If you merge 5 NAR files, some of the points will not be shown, they are in the merged file, but will not display.

    glen
  • sarpydog

    2 Intern

    •

    360 Posts

    448

    0

    Posted July 26th, 2008 20:00

    Deal All,

    So the merging functions just use for the same SP files, not for SPA and SPA merging at a period.

    Is above right?

    Thanks,
    Dennis
  • AranH1

    2163 Posts

    448

    0

    Posted July 28th, 2008 08:00

    Dennis,
    The merging is just for files from the same SP. So if I want to see the performance statistics for the week I merge the Monday through Friday .nar files from SPA or SPB.

    Does that make sense?

    Aran
  • kelleg

    6 Operator

    •

    4537 Posts

    448

    0

    Posted July 28th, 2008 09:00

    When merging NAR files always use NAR files from the same SP.

    So, if you have SPA and SPB NARs from Monday and SPA and SPB NAR files from Tuesday, only merge the SPA NAR files from Monday and Tuesday or the SPB NAR files from Monday and Tuesday. Do not merge SPA and SPB NARs together.

    glen
  • sarpydog

    2 Intern

    •

    360 Posts

    448

    0

    Posted August 2nd, 2008 06:00

    Thanks for the reply.

    Dennis
  • gem_guy

    60 Posts

    448

    0

    Posted September 12th, 2008 10:00

    Could someone provide an example for using the archiveretrieve.jar command?
  • kelleg

    6 Operator

    •

    4537 Posts

    448

    0

    Posted September 23rd, 2008 10:00

    archivemerge.jar

    Merges Analyzer archive files
    Description The archivemerge Java command line application merges two
    archive files.

    Note: The archivemerge.jar command recognizes and reports an error
    message when you try to open an encrypted archive file
    .
    The navicli.jar is not required for the archivemerge command to run.

    Format

    The archivemerge.jar command is used as follows.

    java -jar archivemerge.jar -data archive1 archive2 [-out filename] [-overwrite y|n] [-Help]

    where

    -data archive1 archive2

    Informs the merger to merge data of two archive files that you specify.

    -out filename

    Specifies a filename to which to write the merged archive. Use quotes around the filename if it has spaces If you do not specify this switch, the output merged file will be in the current directory with the default name (the current time stamp with the .nar extension.

    -overwrite y|n

    Specifies whether or not to overwrite an existing archive file on the client system.

    y = Overwrite existing file
    n = Do not overwrite existing file

    -Help

    Displays command usage.

    Example

    java -jar archivemerge.jar -data C:\Temp\archive1.nar C:\Temp\archive2.nar -out C:\Temp\mergedArchive.nar

    This command merges the file C:\Temp\archive1.nar and C:\Temp\archive2.nar and writes the merged archive in C:\Temp\mergedArchive.nar.

    glen
  • ChipHeaton

    11 Posts

    276

    0

    Posted March 24th, 2009 14:00

    java -jar archivemerge.jar -data C:\Temp\archive1.nar
    C:\Temp\archive2.nar -out C:\Temp\mergedArchive.nar

    This command merges the file C:\Temp\archive1.nar and
    C:\Temp\archive2.nar and writes the merged archive in
    C:\Temp\mergedArchive.nar


    Nevermind, I finally answered my own question.

    -Chip

    Message was edited by:
    ChipHeaton