How to restart Jenkins in Windows

China☆狼群 提交于 2019-12-22 04:48:20

问题


Not able to restart Jenkins manually. Already tried all below ways:

  1. http://localhost:8080/safeRestart
    Error message: Jenkins cannot restart itself as currently configured.

  2. Manage Jenkins → Restart Safely Plugin.
    Error message: Jenkins cannot restart itself as currently configured.

  3. Not able to find any Jenkins Service in services.msc.

  4. Navigate to jenkins-cli directory in CMD mode

    java -jar jenkins-cli.jar -s http://[jenkins-server]/ restart
    

    See below screenshot for error message:


回答1:


Use command line to stop and start

net stop jenkins
net start jenkins



回答2:


Simply just do one thing.To restart Jenkins manually, you can use either of the following commands on Windows platform.

  • Clean the "AppData\Local\Temp" folder.
  • In search of windows type %temp%. then clean the folder.

Then try restarting Jenkins.

  • use java -jar jenkins.war --httpPort=8080 in cmd fo windows.
  • otherwise change the Port number.
  • java -jar jenkins.war --httpPort=8090

It worked for me!




回答3:


1) Click "Start" button 2) Find and right-click Command Prompt. Then choose Run as administrator. 3) Execute the command "net stop jenkins" and "net start jenkins"

This will definitely works.




回答4:


On windows, goto Run-> type "cmd" and navigate to your jenkins installation path. Then perform the following list of commands:

To stop the jenkins:

jenkins.exe stop

To start the jenkins:

jenkins.exe start

To restart the jenkins:

jenkins.exe restart

Note:if you get an error then run the command as administrator..

Hope this will be helpful..



来源:https://stackoverflow.com/questions/44174587/how-to-restart-jenkins-in-windows

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!