startup.bat

@echo off


if "%1"=="h" goto begin
start mshta vbscript:createobject("wscript.shell").run("""%~nx0"" h",0)(window.close)&&exit
:begin

for /f "usebackq skip=1 tokens=*" %%I in (`wmic process where "name = 'java.exe' and commandline like '%%bzgt.jar%%'" get processid 2^>null`) do (
    echo %%I
    if %%I GTR 1 (
        echo processid is: %%I
        set pid=%%I
        goto break1
    )
)

:break1

if defined pid (
    echo pid = %pid%
    echo taskkill /f /pid %pid%
    taskkill /f /pid %pid%
    echo Succeeded in killing the bzgt.jar process.
) else echo The  bzgt.jar process does not exit.

start java  -Xms2g -Xmx2g -Xmn1g -Xloggc:D:\servers\logs\bzgt_gc.log -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10 -XX:GCLogFileSize=100M -jar D:\servers\bzgt.jar > D:\servers\logs\bzgt.log 2>&1 &

for /f "usebackq skip=1 tokens=*" %%I in (`wmic process where "name = 'java.exe' and commandline like '%%dailyliq.jar%%'" get processid 2^>null`) do (
    echo %%I
    if %%I GTR 1 (
        echo processid is: %%I
        set pid=%%I
        goto break2
    )
)

:break2

if defined pid (
    echo pid = %pid%
    echo taskkill /f /pid %pid%
    taskkill /f /pid %pid%
    echo Succeeded in killing the dailyliq.jar process.
) else echo The  dailyliq.jar process does not exit.

start java  -Xms16g -Xmx16g -Xmn8g -Xloggc:D:\servers\logs\dailyliq_gc.log -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10 -XX:GCLogFileSize=100M -jar D:\servers\dailyliq.jar > D:\servers\logs\dailyliq.log 2>&1 &

for /f "usebackq skip=1 tokens=*" %%I in (`wmic process where "name = 'java.exe' and commandline like '%%liqx.jar%%'" get processid 2^>null`) do (
    echo %%I
    if %%I GTR 1 (
        echo processid is: %%I
        set pid=%%I
        goto break3
    )
)

:break3

if defined pid (
    echo pid = %pid%
    echo taskkill /f /pid %pid%
    taskkill /f /pid %pid%
    echo Succeeded in killing the liqx.jar process.
) else echo The  liqx.jar process does not exit.

start java  -Xms2g -Xmx2g -Xmn1g -Xloggc:D:\servers\logs\liqx_gc.log -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10 -XX:GCLogFileSize=100M -jar D:\servers\liqx.jar > D:\servers\logs\liqx.log 2>&1 &

pause
 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值