Qlik Community

Qlik Sense Enterprise Documents & Videos

Documents & videos about Qlik Sense.

Qlik Sense services stop start batch files v2.1.1 onwards (including June 2017)

richbyard
New Contributor III

Qlik Sense services stop start batch files v2.1.1 onwards (including June 2017)

I have attached a very simple set of batch files that I regularly use to manage Qlik Sense Server instances (v2.1.1 through to v3.1 to date), I typically place these files on the desktop of the Qlik Sense Server box.

They are useful when you are required to stop and restart the services, such as upgrades and for other maintenance tasks. Personally I find stopping each task individually a little time consuming so the attached batch files allow you stop all services and start all services with just two clicks (the additional click as you need to run them as the administrator). These Qlik Sense batch files will work on version v2.1.1 onwards (including June 2017) and can easily be updated as new services come online in future releases.

Note: make sure you right click on the batch file to 'run as administrator' in order for it to function correctly and start the services.

For a QlikView version of these files click here.

Attachments
Comments
rospigliosi
Contributor

Tested on 2.2.4, simple and usefull!

dvasseur
Contributor II

My own version with 10s delay between stop and start, just to be sure services are really stopped:

set stop=0

net stop "QlikSenseProxyService"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSensePrintingService"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSenseSchedulerService"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSenseEngineService"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSenseServiceDispatcher"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSenseRepositoryService"
IF %ERRORLEVEL% NEQ 0 set stop=4
net stop "QlikSenseRepositoryDatabase"
IF %ERRORLEVEL% NEQ 0 set stop=4

rem cause a ~10 seconds sleep before checking the service state
ping 127.0.0.1 -n 10 -w 1000 > nul

net start "QlikSenseRepositoryDatabase"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSenseRepositoryService"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSenseServiceDispatcher"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSenseEngineService"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSenseSchedulerService"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSensePrintingService"
IF %ERRORLEVEL% NEQ 0 set stop=5
net start "QlikSenseProxyService"
IF %ERRORLEVEL% NEQ 0 set stop=5

exit %stop%
richbyard
New Contributor III

Hi David, a good addition to ensure things are given time to star and stop successfully. I've never run into an issue without this but each environment has it's own characteristics. Thanks.

acumenjonfoote
New Contributor II

Hey Richard

Have you ever done this on an NPrinting server, I'm trying to do it now but the simple

Net Stop [QlikService]

does not seem to work.

Is it affected by the 'Log On As' account on the service. I'm thinking you may need to pass the user and password somehow.

any Ideas?

Cheers Jon

richbyard
New Contributor III

Hey Jon. long time since we spoke last... Interesting finding, I have an install of both Sense and NP on one machine (although it's not really a supported config) and don't have that issue. I do run these .bat files by right clicking and running as administrator so check this... Otherwise tell me what versions you have installed and I'll check it out. Cheers

acumenjonfoote
New Contributor II

Thanks Rich, Has been a while, I sent you a message in LinkedIn recently.

Worked when I run as Administrator (easy solution) and also when it was run as a task in Task Scheduler. Didn't solve my issue but at least it worked.

Cheers Jon

Version history
Revision #:
1 of 1
Last update:
‎12-07-2015 11:57 PM
Updated by: