Merge branch 'master' of https://git.schroedercity.com/voltron/Misc-Scripts
This commit is contained in:
@@ -21,9 +21,10 @@ if "%errorlevel%"=="3" (
|
||||
set start=true
|
||||
)
|
||||
|
||||
for /f "tokens=2" %%? in ('sc query type^= service state^= all^|find /i "veeam"^|find /i "service_name"^|find /i /v "sqlagent"^|find /i /v "veeam.archiver"') do net %switch% /y "%%?"
|
||||
postgresql-x64-15
|
||||
for /f "tokens=2" %%? in ('sc query type^= service state^= all^|find /i "veeam"^|find /i "service_name"^|find /i /v "sqlagent"^|find /i /v "postgresql-x64-15"^|find /i /v "veeam.archiver"') do net %switch% /y "%%?"
|
||||
if "%switch%"=="stop" for /f "tokens=3*" %%? in ('tasklist /fo list^|find /i "veeam"^|find /i /v "veeam.archiver"') do taskkill /f /im "%%?"
|
||||
if "%start%"=="true" for /f "tokens=2" %%? in ('sc query type^= service state^= all^|find /i "veeam"^|find /i "service_name"^|find /i /v "sqlagent"^|find /i /v "veeam.archiver"') do net start /y "%%?"
|
||||
if "%start%"=="true" for /f "tokens=2" %%? in ('sc query type^= service state^= all^|find /i "veeam"^|find /i "service_name"^|find /i /v "sqlagent"^|find /i /v "postgresql-x64-15"^|find /i /v "veeam.archiver"') do net start /y "%%?"
|
||||
|
||||
echo ""
|
||||
#pause
|
||||
|
||||
Reference in New Issue
Block a user