ADSM-L

Re: [ADSM-L] SQL command to query Sessions with MediaWait or Idle

2008-12-18 16:25:24
Subject: Re: [ADSM-L] SQL command to query Sessions with MediaWait or Idle
From: humberto.castro AT AMERICAS.BNPPARIBAS DOT COM
To: ADSM-L AT VM.MARIST DOT EDU
Date: Thu, 18 Dec 2008 16:23:03 -0500
Richard,

This is what I made to let me know what session is holding up what process
because it's waiting for media.. Maybe this is what you are looking for?


select sessions.SESSION_ID, sessions.CLIENT_NAME,
sessions.OUTPUT_VOL_ACCESS,processes.process_num as
"PROCESS_NUM",processes.process, TRIM(BOTH ' ' from
SUBSTR(processes.STATUS,posstr(processes.STATUS,'Waiting')+34,10)) as
"VOLUME" from sessions, processes where
posstr(sessions.OUTPUT_VOL_ACCESS,',')>0 and sessions.OUTPUT_VOL_ACCESS
like '%'||TRIM(BOTH ' ' from
SUBSTR(processes.STATUS,posstr(processes.STATUS,'Waiting')+34,10))||'%'

It should return something like:

 SESSION_ID     CLIENT_NAME            OUTPUT_VOL_ACCESS      PROCESS_NUM
  PROCESS                VOLUME
-----------     ------------------     ------------------     -----------
  ------------------     ------------------
      15864     LINUXWEB0051           VTL_C1,000130L3,61             122
  Backup Storage         000130L3
     Pool

Best Regards,

Humberto Castro
BNP Paribas RCC
Data Protection Engineer
Core IT Production
Office: 201.850.5703
Mobile: 917.254.8904



Internet
Richard.Cheung AT SANTOS DOT COM

Sent by: ADSM-L AT VM.MARIST DOT EDU
12/04/2008 11:13 PM
Please respond to
ADSM-L AT VM.MARIST DOT EDU


To
ADSM-L
cc

Subject
[ADSM-L] SQL command to query Sessions with MediaWait or Idle





Hello all

I am trying to figure out an effective way to get alerted if a backup
job is idle or not proceeding due to a MediaWait state.....  I want it
to have the smarts to maybe only alert me if it finds the same
successive node has been in the same MediaWait state for a predetermined
period (eg an hour) - given that I am aware at different times an
occasional  'mediawait' warning is just part of normal function....

What is the best way of doing this?   I am thinking either running a SQL
query of some sort to do this, then fire an email or netsend to someone
- OR use SNMP..

Would welcome any suggestions or hints?



<html>
<body>
<font face="arial" color=#808080 size="-2"><img
alt="Santos Logo" src="http://www.santos.com/library/logo.gif";>
<br>Santos Ltd A.B.N. 80 007 550 923<br>
Disclaimer: The information contained in this email is intended only for
the use of the person(s) to whom it is addressed and may be confidential
or contain privileged information.
If you are not the intended recipient you are hereby notified that any
perusal, use, distribution, copying or disclosure is strictly prohibited.
If you have received this email in error please immediately advise us by
return email and delete the email without making a copy.</font>
<font face="arial" color=#008000 size="-2">Please consider the environment
before printing this email</font>
</body>
</html>


This message and any attachments (the "message") is intended solely for
the addressees and is confidential. If you receive this message in error,
please delete it and immediately notify the sender. Any use not in accord
with its purpose, any dissemination or disclosure, either whole or partial,
is prohibited except formal approval. The internet can not guarantee the
integrity of this message. BNP PARIBAS (and its subsidiaries) shall (will)
not therefore be liable for the message if modified. Please note that certain
functions and services for BNP Paribas may be performed by BNP Paribas RCC, Inc.