Jenkins – Server Maintenance

The following are some of the basic activities you will carry out, some of which are best practices for Jenkins server maintenance

URL Options

The following commands when appended to the Jenkins instance URL will carry out the relevant actions on the Jenkins instance.

http://localhost:8080/jenkins/exit − shutdown Jenkins

http://localhost:8080/jenkins/restart − restart Jenkins

http://localhost:8080/jenkins/reload − to reload the configuration

Backup Jenkins Home

The Jenkins Home directory is nothing but the location on your drive where Jenkins stores all information for the jobs, builds, etc. The location of your home directory can be seen when you click on the Manage Jenkins → Configure system.

Set up Jenkins on the partition that has the freest disk space – Since Jenkins would be taking source code for the various jobs defined and doing continuous builds, always ensure that Jenkins is set up on a drive that has enough hard disk space. If your hard disk runs out of space, then all builds on the Jenkins instance will start failing.

Another best practice is to write cron jobs or maintenance tasks that can carry out clean-up operations to avoid the disk where Jenkins is set up from becoming full.

Leave a Reply