cross clmn

Thursday, 19 November 2015

Killing  Sessions on Netezza

To kill all active sessions on Netezza, to restart a test.

You can use nzsession to list to session id’s, and nzsession abort to kill them manually, but I wanted a means to do it in one.

To Kill All session 

for ses in `nzsession | grep ADMIN | awk ‘{print $1}’`
do
nzsession abort -id ${ses} -force
done
========================================================================


To Kill any single session 

Nzsession -show

then

nzsession abort -id ""session"


========================================================================

Important Note:-

Don't not kill any session using Kill-9 "pid" ever, It may restart your your NPS.

No comments:

Post a Comment