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.
how to deal with "Firefox is already running, but is not responding"
os:winxp
browser name: firefox 8.0
shai build: v3.5
I'm trying to get a batch of tests to run automatically using the commandline and Firefox but encountering the "Firefox is already running, but is not responding" error.
read through the forum, i know this may need to set MOZ_NO_REMOTE = 1, but where? i set in sahi.bat and dashboard.bat, but still do not work.
@echo off
if exist %SAHI_HOME% goto checkuserdata
set SAHI_HOME=..
set MOZ_NO_REMOTE=1
browser name: firefox 8.0
shai build: v3.5
I'm trying to get a batch of tests to run automatically using the commandline and Firefox but encountering the "Firefox is already running, but is not responding" error.
read through the forum, i know this may need to set MOZ_NO_REMOTE = 1, but where? i set in sahi.bat and dashboard.bat, but still do not work.
@echo off
if exist %SAHI_HOME% goto checkuserdata
set SAHI_HOME=..
set MOZ_NO_REMOTE=1
Comments
You dont have to set MOZ_NO_REMOTE = 1, if you are using the latest version.
Kindly check if there are any instances of firefox running on your system, the controller will not be able to exectute the script. Or check if there is firefox is stuck(look for firefox.exe in the task manager) then that will also block firefox starting.
Regards
Sumitra
no other instance of firefox running, and this prompt very frequently pops up, and i note on the console indicating that sahi use the same profile named sahi0. and i guess this is why sahi cannot kill the firefox timely.
hope you can help me out.
Could you please check the browser option tag for firefox by clicking on Configure on the dashboard is correct.
It should be :<options>-profile "$userDir/browser/ff/profiles/sahi$threadNo" -no-remote</options>
Let me know if this solves your issue.
Regards
Sumitra
<options>-profile "$userDir/browser/ff/profiles/sahi$threadNo" -no-remote</options>
but this is not my solution.
Could you post the contents of browser_types.xml for firefox by navigating to <sahi-home>/userdata/config/browser_types.xml.
Also, could you tell me how are you running the batch of tests?
Regards
Sumitra
<browserType>
<name>firefox</name>
<displayName>Firefox</displayName>
<icon>firefox.png</icon>
<path>$ProgramFiles\Mozilla Firefox\firefox.exe</path>
<options>-profile "$userDir/browser/ff/profiles/sahi$threadNo" -no-remote</options>
<processName>firefox.exe</processName>
<capacity>5</capacity>
</browserType>
<browserType>
<name>firefox4</name>
<displayName>Firefox 4</displayName>
<icon>firefox.png</icon>
<path>$ProgramFiles\Mozilla Firefox 4.0 Beta 7\firefox.exe</path>
<options>-profile "$userDir/browser/ff/profiles/sahi$threadNo" -no-remote</options>
<processName>firefox.exe</processName>
<capacity>5</capacity>
</browserType>
I run the suite with the command as below:
testrunner.bat Baylor/allcases.suite https://bhcs.xxxx.com firefox
and testrunner.bat code as below:
@ECHO OFF
if "%1"=="" goto ERROR
if "%2"=="" goto ERROR
if "%3"=="" goto ERROR
SET SAHI_HOME=..\..
SET USERDATA_DIR=..\
SET SCRIPTS_PATH=scripts
SET START_URL=%2
SET THREADS=1
SET SINGLE_SESSION=false
java -cp %SAHI_HOME%\lib\ant-sahi.jar net.sf.sahi.test.TestRunner -test %SCRIPTS_PATH%/%1 -browserType %3 -baseURL "%START_URL%" -host localhost -port 9999 -threads %THREADS% -useSingleSession %SINGLE_SESSION%
goto :EOF
:ERROR
echo "Usage: %0 <sah file|suite file> <startURL> <browserType>"
echo "File path is relative to userdata/scripts"
echo "Example:"
echo "%0 demo/demo.suite http://sahi.co.in/demo/ firefox"
echo "%0 demo/sahi_demo.sah http://sahi.co.in/demo/ ie"
Cloud you please delete the profiles for ff by navigating to <sahi-home>/userdata/browser/ff/profiles and check if you are still facing the issue.
If the above solution didnot work then we will have a desktop sharing so that i can help you to solve the issue.
Regards
Sumitra
I am also facing the same like above,i am using ant file to run the suite..After deleting the profiles also ,i am unable to run.."Firefox already running.." message is displayed after running the first sah file in the suite.Please, do me the needful
i also experience this problem - the already opened browser doesn't let to begin another suit. And the thing is that no matter if the test went ok or it failed - the browser doesn't close.
Is there any command to close the browser after the test is done?
thanks!
For those who will suffer this: if you on XP - check when starting sahi do you see error message about taskill. If yes:
download PSTOOLS from microsoft. Install them.
Edit sahi\config\os.properties to use PSTOOLS to kill procs.
change in browsers config the process name to firefox (without .exe)
restart and you're back on track!
I am facing similar issue on Linux.
No help yet. I have posted seperate topic for the same.
Regards,
Akshada
I have the same problem, "Firefox is already running, but is not responding" with OS XP, i have installed PSTOOLS but i did't know how to use it in os.properties to kill the procs.
Regards
Ahmed
If your using Ant file to run the suite file, Store the following lines in a batch file and call the batch file in your ant target before you begin your script.
Taskkill /IM firefox.exe /F
Taskkill /IM iexplore.exe /F
Taskkill /IM chrome.exe /F
Taskkill /IM opera.exe /F
Taskkill /IM safari.exe /F