April 18, 2023, 7:55pm
In Jenkins 2.361.1 on Redhat I am wanting to change the Home Directory. I have performed the following steps with no success:
Stopped jenkins service
Made new home directory
Copied all data from old home directory to new directory and updated permissions.
sudo usermod -d /new/home/directory/jenkins_home jenkins
Update Jenkins config where JENKINS_HOME variable is set in /etc/sysconfig/jenkins
Start Jenkins service
When I open Jenkins application it shows the Home directory as the default (var/lib/jenkins)
What am I missing?
April 18, 2023, 8:46pm
Jenkins 2.332.1 switched Jenkins from using System V init to use systemd with its Linux package installers for Debian, Ubuntu, Red Hat, Alma, openSUSE, Rocky, and more. The
LTS Upgrade Guide describes that transition and how to adapt your environment to the transition.
There is a
blog post about it as well at
There is also a
video introduction for RPM based distributions like Red Hat Enterprise Linux, Alma Linux, Rocky Linux, Oracle Linux, and Amazon Linux.
There is also a
video introduction for deb based distributions like Debian and Ubuntu
April 19, 2023, 3:48pm
Thank you! This is great information and I appreciate your quick reply!
Looks like I need to do the following, correct?
sudo systemctl edit jenkins
Change the ENVIRONMENT=“JENKINS_HOME=/new/home/directory/jenkins_home”
Do I also need to change the
April 19, 2023, 4:37pm
That sounds right. I havn’t messed with systemd files in a while, so i can’t be 100%
April 20, 2023, 7:38pm
That worked so thank you for your help!!!