Old:Bugs 3.5-Apollo: Stop bat: Difference between revisions

From The Uniform Server Wiki
Jump to navigation Jump to search
(New page: {{Uc nav 3.5 bugs}} '''''Stop.bat''''' == Enhancement == File: '''Stop.bat'''<br> Location: '''*\Uniform Server''' '''''Enhancement'':''' Enclose batch commands between '''pushd %~dp0'''...)
 
m (BobS moved page Bugs 3.5-Apollo: Stop bat to Old:Bugs 3.5-Apollo: Stop bat without leaving a redirect)
 
(One intermediate revision by the same user not shown)
Line 6: Line 6:
Location: '''*\Uniform Server'''
Location: '''*\Uniform Server'''


'''''Enhancement'':''' Enclose batch commands between '''pushd %~dp0''' and '''popd''' forces current working directory to the folder a batch file is located in. On completion restores original calling working directory. Allows remote processes to stop servers.
'''''Enhancement'':''' Enclose batch commands between '''pushd %~dp0''' and '''popd'''. This forces current working directory to the folder where a batch file is located in. On completion, it restores original calling working directory. This aAllows remote processes to stop servers.


'''''Proposed changes:'''''
'''''Proposed changes:'''''
Line 51: Line 51:
'''''Note'':''' Technically for stopping a single process the above enhancement is not required however if you wish to stop additional processes the structure is in place.  
'''''Note'':''' Technically for stopping a single process the above enhancement is not required however if you wish to stop additional processes the structure is in place.  
   
   
'''''[[#top | Top]]'''''


----
----
Line 61: Line 59:




[[Category: UniCenter]]
[[Category: Archive]]
[[Category: Support]]
[[Category: Patches]]
[[Category: Troubleshooting]]

Latest revision as of 12:24, 21 June 2013

Uniform Server 3.5-Apollo known bugs or issues.

Stop.bat

Enhancement

File: Stop.bat
Location: *\Uniform Server

Enhancement: Enclose batch commands between pushd %~dp0 and popd. This forces current working directory to the folder where a batch file is located in. On completion, it restores original calling working directory. This aAllows remote processes to stop servers.

Proposed changes:

rem Name: Stop Server File
rem Created By: The Uniform Server Development Team
rem Edited Last By: Olajide Olaolorun (empirex)
rem Comment: Tara's new syetm of shutting down the server
rem To Developers: Implemented a new system of server shutdown
rem Proposed enhancement MPG 3-7-08

@echo off
rem working directory current folder 
pushd %~dp0

rem Stop Apache indirectly stops MySQL
udrive\home\admin\program\pskill.exe Apache.exe c

rem ### Check for system error jump to Pause allows error message to be displayed.
if errorlevel 2 goto :PAUSE
goto :END
:PAUSE
echo .
pause

:END
rem restore original working directory
popd

Download

Download this file Stop.bat.txt save as Stop.bat and copy to the folder Uniform Server.

Allow it to overwrite the existing file.

Forum reference

Additional information or background can be found on these forum pages.

None

Proposed solution

See above.

Note: Technically for stopping a single process the above enhancement is not required however if you wish to stop additional processes the structure is in place.



Ric