ADSM-L

Re: [ADSM-L] 6.2.2 equivalent of "show logpinned"?

2011-05-02 12:28:14
Subject: Re: [ADSM-L] 6.2.2 equivalent of "show logpinned"?
From: Dave Canan <ddcanan AT GMAIL DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Mon, 2 May 2011 09:26:52 -0700
Zoltan, there is no "show logpinned" command in V6.2.2, but it is still
possible to figure out which session and transaction is causing the log to
be pinned. Here is an example of what you would need to do:
This isn't quite as straight-forward as the old show command, but this will
work. Call or re-post if you have questions.


1. You need to start with doing a "show txnt" command. Here is an example of
one:


Session established with server xxxxxxx: AIX
  Server Version 6, Release 2, Level 2.0
  Server date/time: 05/02/11   12:09:43  Last access: 05/02/11   12:09:30


tsm: xxxxxxx>show txnt

Transaction hash table contents (slots=256):
slot -> 38:
Tsn=0:688678, Resurrected=False, InFlight=True, Distributed=False,
Persistent=True, Addr 113001ab8
  Start ThreadId=17986, Timestamp=05/02/11 12:10:06, Creator=imdmgr.c(3552)
  Last known in use by ThreadId=17986
  Participants=1, summaryVote=ReadOnly
  EndInFlight False, endThreadId 0, tmidx 0 0, processBatchCount 0,
mustAbort
False.
    Participant DB: voteReceived=False, ackReceived=False
      DB: Txn 11295a158, ReadOnly(YES), connP=1128ab1f8, applHandle=23208,
openTbls=2:
      DB: --> OpenP=115facf38 for table=Management.Classes.
      DB: --> OpenP=116eba978 for table=Management.Class.Ids.
      DB: --> RegSqlId=0x03000000 SELECT for table=Backup.Objects,
executed(Yes).
slot -> 39:
Tsn=0:688679, Resurrected=False, InFlight=True, Distributed=False,
Persistent=True, Addr 115646a78
  Start ThreadId=17986, Timestamp=05/02/11 12:10:06, Creator=imdmgr.c(3673)
  Last known in use by ThreadId=17986
  Participants=2, summaryVote=ReadOnly
  EndInFlight False, endThreadId 0, tmidx 0 0, processBatchCount 0,
mustAbort
False.
    Participant DB: voteReceived=False, ackReceived=False
      DB: Txn 112f855b8, ReadOnly(NO), connP=112ef88f8, applHandle=23205,
openTbls=24:
      DB: --> OpenP=1147eded8 for table=Activity.Summary.
      DB: --> OpenP=118b7e038 for table=Group.Objects.ByLeader.
      DB: --> OpenP=112fbdcf8 for table=Backup.Objects.
      DB: --> OpenP=11300d3d8 for table=Group.Leaders.
      DB: --> OpenP=11730b3b8 for table=AS.Volume.Status.
      DB: --> OpenP=11307a7b8 for table=AF.Vol.Clusters.
      DB: --> OpenP=11743acd8 for table=AF.Clusters.
      DB: --> OpenP=117335198 for table=BF.Dereferenced.Chunks.
      DB: --> OpenP=112fa2bb8 for table=DF.Segments.
      DB: --> OpenP=113084658 for table=AS.Segments.
      DB: --> OpenP=1160b65b8 for table=AF.Damaged.
      DB: --> OpenP=112fe8b78 for table=BF.Bitfile.Extents.
      DB: --> OpenP=115641438 for table=AF.Segments.
      DB: --> OpenP=115f7d578 for table=AF.Bitfiles.
      DB: --> OpenP=114536ad8 for table=DF.Bitfiles.
      DB: --> OpenP=11303ff78 for table=BF.Aggregate.Attributes.
      DB: --> OpenP=118c62eb8 for table=BF.Aggregated.Bitfiles.
      DB: --> OpenP=1170581d8 for table=ARCH_EXPDIRS.
      DB: --> OpenP=1147ec498 for table=Archive.Objects.
      DB: --> OpenP=11604ddb8 for table=Management.Class.Ids.
      DB: --> OpenP=116e91c98 for table=Management.Classes.
      DB: --> OpenP=113034e98 for table=Filespaces.
      DB: --> OpenP=1144d3e38 for table=Nodes.
      DB: --> OpenP=114d1ce58 for table=Policy.Domain.Members.
    Participant IM: voteReceived=False, ackReceived=False
  Locks held by Tsn=0:688679 :
    Type=19002(im node filespace), NameSpace=0, SummMode=xLock, Mode=xLock,
Key='154.1'
    Type=19001(im node), NameSpace=0, SummMode=ixLock, Mode=ixLock,
Key='154'
    Type=19000(im universe), NameSpace=0, SummMode=ixLock, Mode=ixLock,
Key=''
slot -> 165:
Tsn=0:692901, Resurrected=False, InFlight=True, Distributed=False,
Persistent=True, Addr 114532178
  Start ThreadId=17984, Timestamp=05/02/11 12:10:07, Creator=imdmgr.c(2460)
  Last known in use by ThreadId=17984
  Participants=1, summaryVote=ReadOnly
  EndInFlight False, endThreadId 0, tmidx 0 0, processBatchCount 0,
mustAbort
False.

2. What you're going to want to do is look at the lines that state "Start
Threadid=nnnnn, Timestamp=". You need to find the oldest Timestamp. That
will also give you the threadid. From there you do a "show threads" command.
Here is a piece from that command :

       Thread 17980, Parent 42: psSessionThread, Storage 0, AllocCnt 490
HighWaterAmt
174080
 tid=253c, ptid=1e2a, det=1, zomb=0, join=0, result=0, sess=4612
  Holding mutex OUTV->mutex (0x112018018), acquired at output.c(3267)

  Stack trace:
    0x0900000000595f30 _cond_wait_global
    0x0900000000596abc _cond_wait
    0x09000000005977ac pthread_cond_wait
    0x0000000100008414 pkWaitConditionTracked
    0x00000001000130f8 outGetNext
    0x0000000100870e58 SmAdminOutput
    0x000000010086ffb8 SmExecuteAdminCommand
    0x000000010086f888 SmAdminSession
    0x00000001003f123c DoAdminGeneral
    0x00000001003ec9bc smExecuteSession
    0x000000010009ad48 psSessionThread
    0x000000010001b688 StartThread


3. Look for the thread Id for the longest running transaction in the first
step. This will also point you to the session matching that thread. From
there, the session (that is the longest running transaction), can be
canceled.


Dave Canan
IBM ATS TSM Performance
ddcananATUSDOTIBMDOTCOM
916-723-2410


On Fri, Apr 29, 2011 at 5:50 AM, Zoltan Forray <zforray.vcu AT gmail DOT 
com>wrote:

> Yes, I realize 6.x is DB2 but I was wondering is there is an equivalent to
> "show logpinned". I seem to be in some kind of situation where the logs are
> not being released and growing daily, eventhough I have performed numerous
> full DB backups and backup volhist.
>
> I am going to have to bounce it soon, if I can't kill whatever is holding
> things up.
>
> My suspicion is a hung import.  I have been moving numerous nodes from an
> old 5.5 server and along the way at least 2-export/imports have crashed for
> various reasons and left zombie imports on the 6.2.2 server  (yes I tried
> cancel proc with no results other than "cancel in progress")
>
> --
> Zoltan Forray
> TSM Software & Hardware Administrator
> Virginia Commonwealth University
> UCC/Office of Technology Services
> zforray AT vcu DOT edu - 804-828-4807
> Don't be a phishing victim - VCU and other reputable organizations will
> never use email to request that you reply with your password, social
> security number or confidential personal information. For more details
> visit
> http://infosecurity.vcu.edu/phishing.html
>