Hai all,

I have a small doubt …Will the lock file remains if we restart the system when our IS instance is running…??? If it remains why it is going to remain like that that is if we restart the system the IS is shutting down and no instance is running…

I came across this,that is i have seen the lockfile after i have restarted the system.

Lockfile is generated, when you suddenly terminate the IS, means when you do not let it start completely.
Even if you restart the system, it will be there, until you delete it.
Try to do this again, it will show you a clear picture.


When you start the IS, the server.bat file is executed. If you open this file and scan through the lines of code, you will see an if else logic, where it checks to see if a LOCKFILE already exists.

So when you are restarting, During the shutdown the lockfile is deleted and then recreated while coming back up (check the timestamp of the lockfile, it gets updated).

if exist LOCKFILE (
echo Only one Integration Server instance may be run from a particular
echo installation at a time. Make sure that this server is shutdown
echo before trying to start it. If no server is running, then
echo delete the file
echo and try to start the server again.
goto :EOF
echo. > LOCKFILE

This piece of code inside the server.bat will check if there is already an existing instance of IS is running or not. If you comment this code out then, you can start multiple instances of the IS with no lock file issues. Hope this answers your question.


Hai Thanks for your replay akki and i came to know a new thing from your post, but my question is that

             Why the lock file is existing if i restart my box without shuting down the IS and if do like this the windows will automatiacally shuts down or kill the instance of IS so then the lockfile has to be deleted by that action of windows,but when i do the same the lockfile is still existing in my IS,so that i cant start a new instance of IS,i have delete the file and again i have to start it.... I think now you got a clear picture on my question 

any suggestions please…???

As Akshith pointed out the LOCKFILE if created and removed by the servers startup script. If the server is shut down without stopping SI properly, the script is just killed. Windows does not know anything about the internals of the script, so it does not remove the LOCKFILE. Whenever a box is shutdown, IS (and all other server running as well) should be shut down properly (Maybe it is if it is a service, but I didn’t test this).

The intention of the LOCKFILE is to prevent running two instances of the same IS, and this you should not do. Beside the conflict about the port there will be conflicts in the storage. If you need more than on IS on a box, make an independent installation.

Whenever a box is shutdown, IS (and all other server running as well) should be shut down properly (Maybe it is if it is a service, but I didn’t test this).

Yes, If IS runs as windows service Windows takes care to properly shutdown all the instances of programs running in the machine while shutting down the windows. However this does not apply for the batch programs - windows will try to kill/shutdown the running process but windows does not know the pending tasks in batch script.

If you are shutting down the box without shutting your IS down…then windows will allocate a min amount of time for all process to shut down…if they are not then windows will terminate every process…the default amount time provided by the windows for every process is 20 seconds…this can be seen in windows registery WaitToKillService parameter…

When you shutdown the box, It will kill/terminate all the processes running. But LockFile is not a process running. Its just a file to avoid running of multiple instances of IS at same time.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.