Use these instructions to upgrade Review Board to a latest build.
Before You Begin
  • TeamForge 19.3 supports Review Board 3.0.15 on RHEL/CentOS 7.7 and Review Board 2.5.6.1 on RHEL/CentOS 6.10.
  • This procedure is for those who have Review Board already and are upgrading Review Board to a latest build on RHEL/CentOS 6.10 or 7.7.
  • You may choose to upgrade Review Board on the same server or on a new server.
  • In this scenario, both TeamForge and Review Board use PostgreSQL.
  • To install Review Board successfully, ensure that other repositories such as EPEL (Extra Packages for Enterprise Linux) are disabled apart from the CollabNet and Operating System repositories.
  • Upgrading Review Board needs root privileges. You must log on as root or use a root shell to upgrade Review Board.

Back up and Restore the Review Board Database and Data Directories

If Review Board and TeamForge are co-hosted on the same server, the Review Board database and data directories should have been backed up already when you backed up TeamForge. So, it is not necessary to take a back up of the Review Board database and data directories again. However, you must back up Review Board if you have Review Board on a separate server outside of the TeamForge Application Server.

  1. Back up the /opt/collabnet/teamforge/var/pgsql and /opt/collabnet/teamforge/var/reviewboard/data directories from the Review Board Server that hosts the Review Board database service (reviewboard-database) in case you have Review Board on a separate server outside of the TeamForge Application Server.

    mkdir -p /tmp/backup_dir
    cd /opt/collabnet/teamforge/var
    tar -zcvf /tmp/backup_dir/reviewboard_pgsql.tgz pgsql/9.6
    tar -zcvf /tmp/reviewboard_data.tgz reviewboard
    
  2. Copy the /tmp/reviewboard_pgsql.tgz and reviewboard_data.tgz files to the /tmp directory of the new server if you are upgrading Review Board on a new hardware.

    scp /tmp/reviewboard_pgsql.tgz username@newRBbox:/tmp
    scp /tmp/reviewboard_data.tgz username@newRBbox:/tmp
    

Upgrade Review Board

  1. Make sure that reviewboard, reviewboard-database and reviewboard-adapter identifiers have been added to the SERVICES token of the TeamForge Application Server (server-01).
    server-01:SERVICES=ctfcore ctfcore-database mail search codesearch etl ctfcore-datamart subversion cvs gerrit gerrit-database binary binary-database reviewboard reviewboard-database reviewboard-adapter cliserver
    
    It is assumed that the Review Board is running on the TeamForge Application Server. In case you have a separate Review Board Server, add the reviewboard and reviewboard-database identifiers to the Review Board server’s SERVICES token.
  2. TeamForge Installation Repository Configuration for Sites with Internet Access

    1. Contact the CollabNet Support and download the TeamForge 19.3 installation repository package to /tmp.
    2. Install the repository package.
      yum install -y /tmp/collabnet-teamforge-repo-19.3-0-noarch.rpm
      
    3. Refresh your repository cache.
      yum clean all
      

    TeamForge Installation Repository Configuration for Sites without Internet Access

    1. Contact the CollabNet Support to get the auxiliary installer package for TeamForge 19.3 disconnected installation and save it in /tmp.
      • RHEL/CentOS 6.10 64 bit: CTF-Disconnected-media-19.3.382-652.rhel6.x86_64.rpm
      • RHEL/CentOS 7.7 64 bit: CTF-Disconnected-media-19.3.382-652.rhel7.x86_64.rpm
      • In addition to the above CentOS 7.7 64 bit RPM package, you must get the following CentOS 7.7 compatibility RPM, which is required for TeamForge 19.3 disconnected media installation on CentOS 7.7 profile: compat-ctf-dc-media-1.2-1.el7.centos.noarch.rpm.
    2. Unpack the disconnected installation package.
      rpm -Uvh <package-name>
      
    3. Unpack the compat-ctf-dc-media-1.2-1.el7.centos.noarch.rpm package if you are installing TeamForge 19.3 on CentOS 7.7.
      rpm -ivh compat-ctf-dc-media-1.2-1.el7.centos.noarch.rpm
      
    4. If you are installing TeamForge 19.3 on RHEL/CentOS 6.10, contact the CollabNet Support to get the python-modules-sources-el6.zip file and unzip it to /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources.
         unzip python-modules-sources-el6.zip -d /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources
      

      If you are installing TeamForge 19.3 on RHEL/CentOS 7.7, contact the CollabNet Support to get the python-modules-sources-el7.zip file and unzip it to /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources.

         unzip python-modules-sources-el7.zip -d /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources
      
    5. If not mounted already, mount the RHEL/CentOS installation DVD.

      The DVD contains the necessary software and utilities required for installing TeamForge without internet access. In the following commands, replace “cdrom” with the identifier for your server’s CD/DVD drive, if necessary.

      cd /media/
      mkdir cdrom
      mount /dev/cdrom ./cdrom/
      

      If there are any spaces in the automount, unmount it first and mount it as a filepath, with no spaces.

    6. Create a yum configuration file that points to the RHEL/CentOS installation DVD.
      vi /etc/yum.repos.d/cdrom.repo
      

      Here’s a sample yum configuration file.

      [RHEL-CDROM]
      name=RHEL CDRom 			
      baseurl=file:///media/cdrom/Server/
      gpgfile=file:///media/cdrom/RPM-GPG-KEY-redhat-release 
      enabled=1
      gpgcheck=0
      
    7. Verify your yum configuration files.
      yum list httpd
      yum list apr
      
  3. Upgrade Review Board.
    yum install teamforge
    
  4. Restore the Review Board database and data directories (on the new server where you plan to have the Review Board database).

    cd /opt/collabnet/teamforge/var/
    tar -zxvf /tmp/reviewboard_pgsql.tgz
    tar -zxvf /tmp/reviewboard_data.tgz
    
  5. Do this on sites without internet access.
    1. Contact the CollabNet Support and get the python-modules-sources.zip file.
    2. Unzip the python-modules-sources.zip file to /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources.
      unzip python-modules-sources.zip -d /opt/collabnet/teamforge/service/reviewboard/resources/SOURCES/python-modules-sources
      
  6. Provision services.
    teamforge provision
    
  7. If SCM is installed on a separate box, run the following script to authenticate a scmviewer user against a TeamForge Subversion repository for creating a new review request.
     python ./svn-auth.py --repo-path=https://<scm_domain>/svn/repos/<repo_dir_name>
    

Post Upgrade Tasks

Bootstrap Review Board Post Install or Upgrade

Use the following instructions if you want to bootstrap Review Board (drop Review Board database tables and recreate them again) for some reason post installation or upgrade.

  1. Log on to the server that hosts the Review Board.
  2. Select My Workspace > Admin.
  3. Select Projects > Integrated Apps.
  4. Select Review Board and click Delete.
  5. Stop TeamForge.
    teamforge stop
    
  6. Start the TeamForge database services.
    teamforge start -s postgres
    
  7. Bootstrap the Review Board database.
    teamforge bootstrap -s reviewboard-database-postgres
    
  8. Bootstrap the Review Board.
    teamforge bootstrap -s reviewboard
    
  9. Start TeamForge.
    teamforge start