美文网首页
bat一键启动/停止微服务

bat一键启动/停止微服务

作者: 阿尼奥赛哟 | 来源:发表于2020-08-13 09:47 被阅读0次

@echo off

start 1--pig-eureka-start1.bat

TIMEOUT /T 30

start 2--pig-config-start2.bat

TIMEOUT /T 50

start 3--pig-auth-start3.bat

TIMEOUT /T 50

start 4--pig-gateway-start4.bat

TIMEOUT /T 50

start 5--pig-upms-service-start5.bat

@echo off

set port=1025

for /f "tokens=1-5" %%i in ('netstat -ano^|findstr ":%port%"') do (

    echo kill the process %%m who use the port

    taskkill /pid %%m -t -f

    goto q

)

:q

set port=3000

for /f "tokens=1-5" %%i in ('netstat -ano^|findstr ":%port%"') do (

    echo kill the process %%m who use the port

    taskkill /pid %%m -t -f

    goto q

)

:q

set port=4001

for /f "tokens=1-5" %%i in ('netstat -ano^|findstr ":%port%"') do (

    echo kill the process %%m who use the port

    taskkill /pid %%m -t -f

    goto q

)

:q

set port=9999

for /f "tokens=1-5" %%i in ('netstat -ano^|findstr ":%port%"') do (

    echo kill the process %%m who use the port

    taskkill /pid %%m -t -f

    goto q

)

:q

set port=8078

for /f "tokens=1-5" %%i in ('netstat -ano^|findstr ":%port%"') do (

    echo kill the process %%m who use the port

    taskkill /pid %%m -t -f

    goto q

)

:q

title 1 pig-eureka

%1 mshta vbscript:CreateObject("WScript.Shell").Run("%~s0 ::",0,FALSE)(window.close)&&exit

java -jar -Xms128m -Xmx256m -XX:PermSize=64M -XX:MaxPermSize=128m D:\CityFlood\jar\pig-eureka.jar

相关文章

  • bat一键启动/停止微服务

    @echo offstart 1--pig-eureka-start1.batTIMEOUT /T 30start...

  • 创建VMware的BAT文件

    本文介绍如何创建批处理文件(BAT)实现对VMware Workstation启动服务和程序、关闭程序和服务的一键...

  • 初涉MySQL

    启动/停止/重启MySQL服务 启动MySQL服务: mysql.server start 停止MySQL服务:...

  • Android服务Service

    一、普通服务 1 . 定义服务 2 . 启动和停止服务 启动服务 停止服务stopService (servic...

  • 2020-08-11Mysql数据库软件

    MySQL配置 启动和停止服务net start mysql:启动服务net stop mysql:停止服务 my...

  • Mac中启动、停止、重启MySql服务

    Mac中启动、停止、重启MySql服务 启动MySql服务: 停止MySql服务: 重启MySql服务: 数据库服...

  • 01.MySQL命令行基本操作

    开启/停止MySQL服务 可以在服务中停止或启动MySQL服务 可以使用命令行启动或停止MySQL服务以管理员身份...

  • FORCEIO发布!

    2019年1月16日,FORCEIO一键启动公有链服务正式上线。在FORCEIO一键启链服务中,启动团队可以自行选...

  • CentOS7中firewall的基本操作

    1、firewall服务的启动停止 启动服务: 关闭服务: 运行状态: 禁止开启启动: 开机启动: 查看启动失败的...

  • MySQL常用一些命令

    MySQL管理服务的命令(启动、停止、重启) 启动 service mysql start 停止 service ...

网友评论

      本文标题:bat一键启动/停止微服务

      本文链接:https://www.haomeiwen.com/subject/yzfbdktx.html