18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
Shutdown sahi.batch
Hi Team,
U have given sahi.batch in sahi installation folder to start sahi server like this how to shutdown sahi server through batch file.
Thanks,
Azhaguvel.A
U have given sahi.batch in sahi installation folder to start sahi server like this how to shutdown sahi server through batch file.
Thanks,
Azhaguvel.A
This discussion has been closed.
Comments
try Ctrl+C in the cmd
We are using ant to drive execution of regression test suite. And here we start and stop sahi server run time while execution of tests.
Don't know exactly how to do it from batch file directly. But in our case we are just using following command in our Build.xml file to stop sahi.
<antcall target="stopsahi"/>
command which directs to :
<target name="stopsahi" description="stop sahi server">
<sahi stop="true" sahihost="localhost" sahiport="9999"/>
</target>
May be there is some code written in ant-sahi.jar used to stop sahi server while invoking above target.
Narayan can give better idea about it. I am also eager to know how it can be done from command prompt without using "Ctrl + C".
There is no commands in windows similar to "lsof -i:9999" of unix. However You can use combination of "TASKKILL" & "NETSTAT" as below to kill a sahi process which is running on port -9999.
netstat -ano | find “9999″
>return :TCP 0.0.0.0:9999 0.0.0.0:0 LISTENING 3140
taskkill /PID 3140
But how ever here we can't use it to execute from batch file as it requires manual intervention....
Please post the solution so that others may benefit.
Thanks,
Narayan