Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Kill Command

5 posts in Windows NT Last posting was on 2001-04-27 20:38:10.0Z
Scott Posted on 2001-04-09 19:32:10.0Z
From: Scott
Date: Mon, 9 Apr 2001 15:32:10 -0400
Newsgroups: sybase.public.sqlserver.nt
Subject: Kill Command
Message-ID: <A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums>
Lines: 2
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com!webforums.sybase.com!news
Xref: forums-1-dub sybase.public.sqlserver.nt:976
Article PK: 1087583

Is there anyway that you can give permison to somebody to kill processes
without the user being an SA, ie creating a new role?


Ray DiMarcello Posted on 2001-04-27 20:38:10.0Z
From: "Ray DiMarcello" <rdimarcello@ingva.com>
References: <A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums>
Subject: Re: Kill Command
Date: Fri, 27 Apr 2001 16:38:10 -0400
Lines: 23
X-Newsreader: Microsoft Outlook Express 4.72.3110.5
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Message-ID: <7o3Tlz1zAHA.191@forums.sybase.com>
Newsgroups: sybase.public.sqlserver.nt
NNTP-Posting-Host: 207.245.124.67
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:874
Article PK: 1087481

We implemented a method that goes something like this (sounds complicated
but it's only a few moving parts) ...

users can run a proc called sp__killme. It takes a spid as an argument.

The proc inserts the spid in a table and then calls xp_cmdshell
"d:\scripts\killme.bat"

d:\scripts\killme.bat (which lives on the dataserver machine) logs into the
server as "sa" and generates a kill command for each spid in the table. It
saves this generated code, then turns around in a second step and runs the
generated code, thus killing the spids. It also deletes the spid entries
from the table as a clean up step.

we built some safeguards into it like they can only kill another spid with
the same suser_name(), etc.

Scott wrote in message ...
>Is there anyway that you can give permison to somebody to kill processes
>without the user being an SA, ie creating a new role?


Rob Verschoor Posted on 2001-04-09 21:15:38.0Z
Reply-To: "Rob Verschoor" <rob@sypron.nl>
From: "Rob Verschoor" <rob@sypron.nl>
References: <A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums>
Subject: Re: Kill Command
Date: Mon, 9 Apr 2001 23:15:38 +0200
Lines: 27
Organization: Sypron B.V.
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2919.6600
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600
Message-ID: <3Fu7jzTwAHA.165@forums.sybase.com>
Newsgroups: sybase.public.sqlserver.nt
NNTP-Posting-Host: i0336.pvu.euronet.nl 194.134.165.81
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:974
Article PK: 1087580


<Scott> wrote in message
news:A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums...
> Is there anyway that you can give permison to somebody to kill
processes
> without the user being an SA, ie creating a new role?

Unfortunately, no, this isn't possible. This has actually shown up as
an ISUG enhancement request, so if you're an ISUG member, I suggest
you go to www.isug.com and vote for it...

HTH,

Rob
----------------------------------------------------------------------
Rob Verschoor

Certified Sybase Professional DBA for ASE 12.0/11.5/11.0

Author of "The Complete Sybase ASE Quick Reference Guide"
Online orders accepted at http://www.sypron.nl/qr

email mailto:rob@sypron.nl.*No*Spam*Please*
WWW http://www.sypron.nl
snail Sypron B.V., P.O.Box 10695, 2501HR Den Haag, The Netherlands
----------------------------------------------------------------------


Bret Halford Posted on 2001-04-16 19:03:30.0Z
Message-ID: <3ADB4201.2075C1B7@sybase.com>
Date: Mon, 16 Apr 2001 13:03:30 -0600
From: Bret Halford <bret@sybase.com>
Organization: Sybase, Inc.
X-Mailer: Mozilla 4.5 [en]C-CCK-MCD (WinNT; I)
X-Accept-Language: en
MIME-Version: 1.0
Subject: Re: Kill Command
References: <A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums> <3Fu7jzTwAHA.165@forums.sybase.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.sqlserver.nt
Lines: 31
NNTP-Posting-Host: bret-pc.sybase.com 157.133.80.211
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:947
Article PK: 1087554

One can, however, create an open-client program that uses the SA login (or
some other login with the appropriate roles) and and can only kill
commands (the spid being a parameter to the program, for instance).

-bret

Rob Verschoor wrote:

> <Scott> wrote in message
> news:A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums...
> > Is there anyway that you can give permison to somebody to kill
> processes
> > without the user being an SA, ie creating a new role?
>
> Unfortunately, no, this isn't possible. This has actually shown up as
> an ISUG enhancement request, so if you're an ISUG member, I suggest
> you go to www.isug.com and vote for it...
>
> HTH,
>
> Rob
> ----------------------------------------------------------------------
> Rob Verschoor
>
> Certified Sybase Professional DBA for ASE 12.0/11.5/11.0
>
> Author of "The Complete Sybase ASE Quick Reference Guide"
> Online orders accepted at http://www.sypron.nl/qr
>
> email mailto:rob@sypron.nl.*No*Spam*Please*
> WWW http://www.sypron.nl
> snail Sypron B.V., P.O.Box 10695, 2501HR Den Haag, The Netherlands
> ----------------------------------------------------------------------


David Owen Posted on 2001-04-10 18:22:54.0Z
Sender: dowen@n-utsire.midsomer.org
Subject: Re: Kill Command
References: <A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums> <3Fu7jzTwAHA.165@forums.sybase.com>
From: David Owen <dowen@midsomer.org>
Organization: Midsomer Consultants Inc.
Date: 10 Apr 2001 12:22:54 -0600
Message-ID: <m3k84sbon5.fsf@n-utsire.midsomer.org>
Lines: 18
User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Newsgroups: sybase.public.sqlserver.nt
NNTP-Posting-Host: h24-65-229-16.cg.shawcable.net 24.65.229.16
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:968
Article PK: 1087576

>>>>> "Rob" == Rob Verschoor <rob@sypron.nl> writes:

Rob> <Scott> wrote in message

Rob> news:A415D9B9B8D948F9006B50C485256A29.006B50D285256A29@webforums...
>> Is there anyway that you can give permison to somebody to kill
Rob> processes
>> without the user being an SA, ie creating a new role?

Rob> Unfortunately, no, this isn't possible. This has actually shown up
Rob> as an ISUG enhancement request, so if you're an ISUG member, I
Rob> suggest you go to www.isug.com and vote for it...

I believe even non-members can vote on requests.

dowen
--
David Owen Midsomer Consultants Inc. dowen@midsomer.org
Maintainer of the Sybase FAQ: http://www.isug.com/Sybase_FAQ