Net Stop Net Start CXMD Cognos Express

Post Reply
BigG
Community Contributor
Posts: 211
Joined: Tue Sep 15, 2009 11:13 pm
OLAP Product: IBMPA
Version: PA 2.0 Cloud
Excel Version: 2010

Net Stop Net Start CXMD Cognos Express

Post by BigG »

Hi, I have tried the standard method for restarting Tm1 services but in Cognos Express, so within the CXMD folder (data directory) I put a RESTART.BAT batch file. I try running as administrator and the cxmd services do not stop start, so the EXECUTECOMMAND('RESTART.BAT',0); initiated from eplilog of TI process doesnt either.

We are on 2008R2 server with Cognos express 9.5, is there something I am missing?


Batch file syntax:
NET STOP <cxmd>
sleep 120
NET START <cxmd>

thanks in advance
GG
BigG
Community Contributor
Posts: 211
Joined: Tue Sep 15, 2009 11:13 pm
OLAP Product: IBMPA
Version: PA 2.0 Cloud
Excel Version: 2010

Re: Net Stop Net Start CXMD Cognos Express

Post by BigG »

arh,

for 2008 r2
'RESTART.BAT'>right click>run as adminstrator

NET STOP cxmd
sleep 120
NET START cxmd

but sleep is not recognosed as internal or external command appears briefly on the screen and this is manual so TI is still not working
GG
BigG
Community Contributor
Posts: 211
Joined: Tue Sep 15, 2009 11:13 pm
OLAP Product: IBMPA
Version: PA 2.0 Cloud
Excel Version: 2010

Re: Net Stop Net Start CXMD Cognos Express

Post by BigG »

sorry think this is the answer

In Windows Server 2008 R2, the command to be used is "timeout" which replaces "sleep"

timeout /t 120

http://technet.microsoft.com/en-us/libr ... .10).aspx

to run as administrator it seems ok as a TI process, just have to tidy up all the bits above prior to testing.

So in epilog call 'RESTART.BAT' that is the cxmd data directory EXECUTECOMMAND('RESTART.BAT',0);

Code: Select all

NET STOP cxmd
timeout /t 120
NET START cxmd
GG
Alan Kirk
Site Admin
Posts: 6667
Joined: Sun May 11, 2008 2:30 am
OLAP Product: TM1
Version: PA2.0.9.18 Classic NO PAW!
Excel Version: 2013 and Office 365
Location: Sydney, Australia
Contact:

Re: Net Stop Net Start CXMD Cognos Express

Post by Alan Kirk »

BigG wrote:arh,

for 2008 r2
'RESTART.BAT'>right click>run as adminstrator

NET STOP cxmd
sleep 120
NET START cxmd

but sleep is not recognosed as internal or external command appears briefly on the screen and this is manual so TI is still not working
Ah, I see you've found the answer since I started to type this post. For reference, though, Sleep has never been part of the standard implementation of batch files for reasons that escape me. I guess back then everything was so slow nobody needed it. It could be applied (by installing an exe named, obviously, sleep.exe) to Server 2003 by installing the Windows Server 2003 Resource Kit, but I can't find anything equivalent for Server 2008. Seems that you may have.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
Post Reply