I'm using foreman for my infrastructure and it's time to upgrade it from v3.0 to v3.1. When checking the documentation, I've found the documentation at the official site to be missing a few steps for the full upgrade path. Although they can arguably be gathered from the install documentation and some from older documentation. I would recommend executing all of these commands in a tmux session so that your session will remain on the server in case anything happens to your workstation.
First, check for running tasks that would prohibit an update:
[root@katello01 ~]# foreman-rake katello:upgrade_check
Next, update the katello host and reboot it if yum tells you to
[root@katello01 ~]# yum -d 2 -y update
[root@katello01 ~]# yum -d 2 needs-restarting -r
When the katello service is reachable again, upgrade the repository
[root@katello01 ~]# yum -d 2 -y install https://yum.theforeman.org/releases/3.1/el7/x86_64/foreman-release.rpm
[root@katello01 ~]# yum -d 2 -y install https://yum.theforeman.org/katello/4.3/katello/el7/x86_64/katello-repos-latest.rpm
[root@katello01 ~]# yum -d 2 -y install centos-release-scl-rh
Clear the yum cache before proceeding with the upgrade
[root@katello01 ~]# yum -d 2 clean all
[root@katello01 ~]# rm -rf /var/cache/yum
Update the system:
[root@katello01 ~]# yum -d 2 -y update
When the update is done, stop the foreman-services
[root@katello01 ~]# foreman-maintain service stop
After the foreman services have been stopped, re-run the installer to ensure consistency:
[root@katello01 ~]# foreman-install --scenario katello
Once that is done, foreman / katello should be updated to the latest version of foreman-3.1 and katello-4.3.
Feel free to comment and / or suggest a topic.
Comments
Post a Comment