Unix Technical Forum

How many locks have been used?

This is a discussion on How many locks have been used? within the Informix forums, part of the Database Server Software category; --> I am trying to determine how many locks have been used or are currently being used. On IDS 9.3 ...


Go Back   Unix Technical Forum > Database Server Software > Informix

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-20-2008, 08:31 AM
malcolm weallans
 
Posts: n/a
Default How many locks have been used?


I am trying to determine how many locks have been used
or are currently being used. On IDS 9.3 we can do an
onstat -k and look at the last line of output but when
we try to do the same with IDS 9.4 the onstat -k often
hangs. It seems that the onstat -k is OK for small
numbers of locks but when the number of locks in use
grows it seems that onstat -k has problems. Has
anybody else seen this?

I am running IDS 9.40.FC3 on AIX 5.2.

regards

Malcolm
sending to informix-list
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-20-2008, 08:32 AM
Doug Lawry
 
Posts: n/a
Default Re: How many locks have been used?

Hi Malcolm.

I use this:

# Display Informix locks - Doug Lawry, 16/04/03

(dbaccess sysmaster 2>&1 | egrep '^[a-z]') <<!

SELECT dbsname [1,18] database,
tabname [1,18] table,
username [1,08] user,
type lock,
tty [6,12] tty,
pid ::SMALLINT process,
count(*) ::SMALLINT number

FROM syslocks,
syssessions

WHERE dbsname != "sysmaster"
AND sid = owner

GROUP BY 1, 2, 3, 4, 5, 6
ORDER BY 1, 2, 3, 4, 5, 6

!

--
Regards,
Doug Lawry
www.douglawry.webhop.org


"malcolm weallans" <malcolm.iiug@btopenworld.com> wrote in message
news:1107169828.9a4acae707bd45453ee3277b3e145595@t eranews...
>
> I am trying to determine how many locks have been used
> or are currently being used. On IDS 9.3 we can do an
> onstat -k and look at the last line of output but when
> we try to do the same with IDS 9.4 the onstat -k often
> hangs. It seems that the onstat -k is OK for small
> numbers of locks but when the number of locks in use
> grows it seems that onstat -k has problems. Has
> anybody else seen this?
>
> I am running IDS 9.40.FC3 on AIX 5.2.
>
> regards
>
> Malcolm
> sending to informix-list



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-20-2008, 08:32 AM
Paul Watson
 
Posts: n/a
Default Re: How many locks have been used?

select * from syslocks is a good starting point

malcolm weallans wrote:

> I am trying to determine how many locks have been used
> or are currently being used. On IDS 9.3 we can do an
> onstat -k and look at the last line of output but when
> we try to do the same with IDS 9.4 the onstat -k often
> hangs. It seems that the onstat -k is OK for small
> numbers of locks but when the number of locks in use
> grows it seems that onstat -k has problems. Has
> anybody else seen this?
>
> I am running IDS 9.40.FC3 on AIX 5.2.
>
> regards
>
> Malcolm
> sending to informix-list



--
Paul Watson #
Oninit Ltd # Growing old is mandatory
Tel: +44 1436 672201 # Growing up is optional
Fax: +44 1436 678693 #
Mob: +44 7818 003457 #
www.oninit.com #
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:23 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com