How to restart Jenkins on Windows
Failed to restart Jenkins manually. I have already tried all of the following methods:
-
http://localhost:8080/safeRestart
Error message: Jenkins cannot restart itself as configured at the moment. -
Control Jenkins -> Restart plugin safely.
Error message: Jenkins cannot restart itself as configured at the moment. -
Couldn't find any Jenkins services in
services.msc
. -
Go into
jenkins-cli
CMD modejava -jar jenkins-cli.jar -s http://[jenkins-server]/ restart
See screenshot below for error message:
source to share
Just do one thing. To restart Jenkins manually, you can use one of the following commands on Windows platform.
- Empty the "AppData \ Local \ Temp" folder .
- Looking for Windows types % temp% . then empty the folder.
Then try restarting Jenkins.
- use java -jar jenkins.war --httpPort = 8080 on cmd windows.
- change the port number.
- java -jar jenkins.war --httpPort = 8090
It worked for me!
source to share
On windows go Run-> type "cmd" and navigate to jenkins install path. Then run the following list of commands:
To stop Jenkins:
stop jenkins.exe
To start Jenkins:
running jenkins.exe
To restart Jenkins:
jenkins.exe reboot
Note: if you get an error, run the command as administrator.
Hope this is helpful ..
source to share