UNSOLVED

sbeltz-walter

updated

21 years ago

SW

sbeltz-walter

1 Rookie

•

3 Posts

0

1346

December 2nd, 2005 07:00

customized reports through the command line

Hello All,
We support several companies at our location. One company is looking for daily reports on the backups of their particular servers. They were at one time supported by another outsource IT company that sent these reports with very nice formatting. following is an example:
savegroup: BKDMZ02.FITS_FXUXSQT01 completed (fxuxsqt01.tiginsurance.com Succeeded)

--- Successful Save Sets ---

fxuxsqt01.tiginsurance.com: / level=full, 1094 MB 00:07:56 46857 files
fxuxsqt01.tiginsurance.com: /var level=full, 2617 MB 00:22:34 6313 files
* fxuxsqt01.tiginsurance.com:/opt save: Warning - `/opt/symantec/ita/system/fxuxsqt01/syslog' size grew during save
* fxuxsqt01.tiginsurance.com:/opt save: Expected 1274623981 bytes for `/opt/symantec/ita/system/fxuxsqt01/syslog', got 1274641180 bytes
fxuxsqt01.tiginsurance.com: /opt level=full, 2428 MB 00:13:32 22700 files
fxuxsqt01.tiginsurance.com: /devs01 level=full, 7792 MB 00:38:55 50 files
fxuxsqt01.tiginsurance.com: /devs02 level=full, 7969 MB 00:39:40 207 files
fxuxsqt01.tiginsurance.com: /devs03 level=full, 5786 MB 00:32:55 31 files
fxuxsqt01.tiginsurance.com: /devs04 level=full, 8082 MB 00:53:04 38 files
* fxuxsqt01.tiginsurance.com:/devs05 save: Warning - `/devs05/oradata/infot01/in


When you right click on a group and select Details, this is the exact information it gives you with the nice formatting.

Does anyone know the command line executable used to create the savegrp detailed report providing information like unsuccessful save sets, successful savesets, etc? And are there parameters used to provide the formatting? this is something that once I figure it out, will get automated. so right now, i'm doing this all by hand.

I hope this makes sense. Anyway, any help would be greatly appreciated. As I am in front of a brick wall.
  • DavidHampson

    2 Intern

    •

    1080 Posts

    708

    0

    Posted December 2nd, 2005 07:00

    You need to configure the savegroup completion notification which is one of the standard notifications that comes with Networker - you will need to use something like smtpmail or blat in the action field to mail this to specific user(s). The default behaviour for this notification is to append the savegroup completion report to /nsr/logs/savegrp.log
  • sbeltz-walter

    1 Rookie

    •

    3 Posts

    708

    0

    Posted December 2nd, 2005 09:00

    thank you. i will give this a try and let you know if this works.
    appreicate your quick response
  • ble1

    6 Operator

    •

    14354 Posts

    •

    56186 Points

    708

    0

    Posted December 4th, 2005 12:00

    Shannon,

    Example you showed is default savegrp completion report. By default on backup servers running on UNIX this is sent via mailx to local root account for each group when completed.

    So, if you go to Notifications you will see something called "Savegroup completion". This is default (unless someone changed it). Action field says where log goes - on UNIX it is mailx action which sends this to local root account. If you change it to for example "/usr/bin/cat >> /nsr/logs/savegrp.log" (without quotes) it will write (append) to log file on disk. You can also write down a script and call it from action field and do whatever you want further.

    Given that fothcoming 7.3 will feature NMC like GUI so via web you will be able to administer everything (including log reports) I would expect that in 2006 this is probably how you will check the logs.
  • ble1

    6 Operator

    •

    14354 Posts

    •

    56186 Points

    708

    0

    Posted December 7th, 2005 02:00

    AFAIK you can't run two commands, but you can do following:
    - leave nsrlog -f notification as it is and create new one
    - in action field put the path to your batch
    - from batch file call blat and send the log created by first notification

    That works (tested).
  • sbeltz-walter

    1 Rookie

    •

    3 Posts

    708

    0

    Posted December 7th, 2005 02:00

    thanks for the pointers.
    i found exactly what I was wanting, well sort of.
    if you go into owner notification, and give it the nsrlog -f command, you can out put the info to a neat little text file. this contains the neatness format and the information that i need.
    for the e-mail part, i am using blat. do you know if you can enter two commands in the owner notification field? i am trying this now. two separate commands. separated by a semicolon (;)but this is not working. If i run the same blat command (just the blat command) it works just fine. so i know my context of the blat command is correct.
    here is the command I am using
    nsrlog -f "D:\legato\nsr\logs\clientlogs\mfrkuxapp06test.log"; blat.exe D:\legato\nsr\logs\clientlogs\mfrkuxapp06test.log -ti 90 -tf c:\temp\email_list.txt -subject "MFRKUXAPP06test SaveLog" -f sbeltzwalter@mfxroanoke.com -debug -server mailservernamehere.com

    can you not run two commands from the owner notification?
  • shegde1

    3 Posts

    708

    0

    Posted December 7th, 2005 23:00

    You can also have a look at Support Note "62248 - How to print statistics on total size backed up" in the Knowledge Base

    -Shyam