Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Jack Papa asked how to find and deal with defunct engine processes and hung sessions. Mike Magie gave a shell loop to kill defunct processes, but Jack was not the process owner. Mike advised watching reads/writes in onstat -u over time to spot a hung session. Art Kagel said to kill the session inside the server with onmode -z sessionid as informix.
Auto-generated by Claude from the posts below — may be imperfect; read the full thread.
Hi Maggie,
Thanks a lot. Prior to posting, i did execute "ps -ef|grep -in "defunct" and
it showed the defunct sessions but can't kill -9 sesid because i'm not the
owner...
From the DB point of view, how can i check which process is holding or causing
a particular SQL statement to hang?
i did onstat -u, (to show the user information).
then, i did onstat -g sess to show the session ids for each user.
I just want to know, in which particular table the select statement hangs and
can i kill it?
↪ replying to JACK PAPA
MIKE MAGIE — — source: IIUG Forums & Mailing Lists
One way is to look at the reads and writes column in the onstat -u over a
period of time for each session (the session id can be grepped out of the
onstat -u output). If you find a session whose reads and writes are notincrementing it could be hung.
MM
You can kill the session within the database server by running:
onmode -z <sessionid>
as informix.
Art
Art S. Kagel
Oninit (www.oninit.com)
IIUG Board of Directors (art@iiug.org)
Disclaimer: Please keep in mind that my own opinions are my own opinions and
do not reflect on my employer, Oninit, the IIUG, nor any other organization
with which I am associated either explicitly or implicitly. Neither do
those opinions reflect those of other individuals affiliated with any entity
with which I am affiliated nor those of the entities themselves.
On Tue, Nov 10, 2009 at 7:31 PM, JACK PAPA <informix2009@gmail.com> wrote:
> Hi Maggie,
>
> Thanks a lot. Prior to posting, i did execute "ps -ef|grep -in "defunct"
> and
> it showed the defunct sessions but can't kill -9 sesid because i'm not the
> owner...
>
> >From the DB point of view, how can i check which process is holding or
> causing
> a particular SQL statement to hang?
>
> i did onstat -u, (to show the user information).
>
> then, i did onstat -g sess to show the session ids for each user.
>
> I just want to know, in which particular table the select statement hangs
> and
> can i kill it?
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--0015174766d63c7fd1047823bc96
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.