home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!olivea!spool.mu.edu!caen!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!usenet.ins.cwru.edu!alpha.ces.cwru.edu!yangying
- From: yangying@ces.cwru.edu (Ying Yang)
- Newsgroups: comp.databases.sybase
- Subject: Re: KILLed Sybase process will not die?
- Message-ID: <1ideloINN1bd@usenet.INS.CWRU.Edu>
- Date: 6 Jan 93 02:03:36 GMT
- References: <1993Jan5.192546.8743@mcm.com>
- Organization: Agency Rent-A-Car, Cleveland, OH
- Lines: 59
- NNTP-Posting-Host: easy.ces.cwru.edu
-
- In article <1993Jan5.192546.8743@mcm.com> wall@mcm.com (Steve Wall) writes:
- >Several times I've wanted to KILL a Sybase process with the
- >equivalent of the UNIX kill -9 (die NOW!, no sig catch, etc.).
- >Sybase gives you KILL, but under certain circumstance, the kill
- >doesn't seem to take effect until some kind of variable delay
- >(seems to be dependent on the type of process). Probably due
- >to the Sybase kernel scheduler, resources in use by the proc,
- >process run state (blocked or not), etc.
- >
- >For instance, this morning I have a DBCC process that is running
- >later than usual due to delays up the pipeline (yes, I'm aware
- >that DBCC in multiuser is not technically correct, and we interpret
- >the results with this in mind), And now the DBCC is hogging the
- >Server when people are trying to perform typical, daily queries.
- >Thus, I want to KILL it since it is not mandatory that we get
- >DBCC results every day.
- >
- >[Actually, the DBCC (spid=1) is blocking all my users due to locking
- >on sysobjects (DBCC has a shared page lock on sysobjects
- >page 2, my other proc (spid=10) is trying to get an Ex-table on
- >sysobjects - see below). Why is DBCC locking sysobjects for so long?]
- >
-
-
-
- When we kill a Sybase process, we may get (at least) four different
- results :
-
- 1. The process is a ordinary retrieve transaction, i.e. SELECT, it
- dies immediately.
-
- 2. The process is an update transaction, it does not die until the
- server has rolled back the transaction. The time is directly related to
- the size of transaction.
-
- 3. The process is a DBCC transaction. Sybase forks a separate process
- for the transaction, and the new one is out of users' control. I have
- experience to check multi-million row tables(with checktable option).
- DBCC checks the tables index by index, we can only kill it when it
- finishes one index and ready for the next one. It may take amywhere
- from several minutes to four hours to die. In your case, it seems you
- were running checkallec or checkdb, so the process held locks on the
- sysobjects, and you could not control the "ghost" Sybase process.
-
-
- 4. The process is sleeping. We cannot kill a sleeping process. When an
- end-user process gets disconnected, we cannot kill the Sybase process
- and release the locks. To deal with this, we have installed a EBF to
- kill disconnected processes when our clients turn off their PCs. At
- last year's User Conference, Sybase said the 5.0 version would provide
- unconditional KILL, hope this is true.
-
-
-
- Ying Yang
-
- MIS
- Agency Rent-A-Car
-
-