HiveBrain v1.2.0
Get Started
← Back to all entries
snippetMajor

How to safe restart Jenkins?

Submitted by: @import:stackexchange-devops··
0
Viewed 0 times
jenkinsrestartsafehow

Problem

I need to make some configuration changes on our Jenkins instance that will involve restarting Jenkins a couple of times. However, our developers are committing frequently enough that I haven't seen Jenkins without jobs running in three days.

Is there a native way (either through the GUI or via command line) to safe-restart Jenkins? IE: wait for current jobs to finish before going down, and keep track of queued jobs to start once Jenkins comes back up.

I know there's a plugin but in order to install it I need to restart Jenkins...

Solution

If you navigate to $YOUR_JENKINS_URL/updateCenter/ you should see the following page:

Here you can check Restart Jenkins when installation is complete and no jobs are running which should be fairly safe.

Context

StackExchange DevOps Q#3104, answer score: 23

Revisions (0)

No revisions yet.