Install Swarm on CentOS/RHEL 7
-
We recommend that the latest point release is used. At the time of this Swarm release, the latest stable CentOS/RHEL 7 release is 7.9.
-
Swarm does not support Helix Core Servers configured to use P4AUTH, see Centralized authentication server (P4AUTH) in the Helix Core Server Administrator Guide.
- Swarm can be connected to Helix Core Servers (P4D) and commit servers.
- Swarm must not be connected to Helix Broker, Helix Proxy, Helix Edge, forwarding replica, or read-only replica servers.
To configure Swarm to connect to more than one Helix Core Server (P4D), see Multiple Helix Core Server instances.
To configure Swarm to connect to a Helix Core Server configured to use commit-edge architecture, see Commit-edge deployment.
Installation
-
Review the runtime dependencies before you install Swarm, see Runtime dependencies.
-
Review the PHP requirements before you upgrade Swarm, see PHP.
- Review the Helix Core Server requirements before you install Swarm, see Helix Core Server requirements.
-
Configure the Perforce package repository, on the server to host Swarm and on the server hosting your Helix Core Server.
ImportantIf the server hosting your Helix Core Server cannot use packages, for example when it is running Windows, skip this step on that server.
As root, create the file
/etc/yum.repos.d/perforce.repo
with the following content:[Perforce]
name=Perforce
baseurl=http://package.perforce.com/yum/rhel/7/x86_64/
enabled=1
gpgcheck=1 -
Import the Perforce package signing key, on the server to host Swarm and the server hosting your Helix Core Server.
ImportantIf the server hosting your Helix Core Server cannot use packages, for example when it is running Windows, skip this step on that server.
Run the following command as root:
rpm --import https://package.perforce.com/perforce.pubkey
For information about how to verify the authenticity of the signing key, see: https://www.perforce.com/perforce-packages
-
Install the main Swarm package on the server to host Swarm (run these commands as root):
- Deploy the epel-release-latest-7.noarch.rpm repository configuration package to give Swarm access to EPEL packages:
- Deploy the Remi repository configuration package to give Swarm access to PHP 7.x (only required the first time you upgrade to PHP 7.x):
- Install the yum-utils package to give access to the yum-config-manager command:
- RHEL only: Enable the optional channel for some dependencies:
- Install the Default/Single version of PHP:
- Disable remi-php*:
- Enable PHP 7.4:
- Run an upgrade for PHP:
yum-config-manager --disable 'remi-php*'
yum-config-manager --enable remi-php74
yum update
- Install Swarm and accept the prompts to import the GPG keys for Remi and EPEL when requested:
yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum install https://rpms.remirepo.net/enterprise/remi-release-7.rpm
TipIf you don't deploy the Remi repository, you will see dependency errors when you do the next steps.
yum install yum-utils
subscription-manager repos --enable=rhel-7-server-optional-rpms
yum install helix-swarm
ImportantWhen the Swarm installation has completed, you are prompted to run the configure-swarm.sh post-installation script.
Do not run this script until you have completed the rest of these Installation instructions. Instructions for running the configure-swarm.sh post-installation script are in the Post-Installation configuration section referenced in the final step of the Installation instructions.
NoteThe firewall configuration may need to be adjusted to allow access to the web server.
sudo firewall-cmd --permanent --add-service=http
sudo systemctl reload firewalldIf you subsequently wish to enable HTTPS, run (as root):
sudo firewall-cmd --permanent --add-service=https
sudo systemctl reload firewalld -
Swarm needs to know about some Helix Core Server events to operate correctly. Use Helix Core Server Extensions (recommended) or Helix Core Server Triggers to notify Swarm about these events. The Swarm Helix Core Server extension can be installed automatically by the Swarm configure-swarm.sh post-installation script, but Triggers must be manually installed. To use Helix Core Server Extensions, ignore this step and skip to the next step.
Trigger installation only (not recommended): Install the Swarm triggers package on the server hosting your Helix Core Server. This might be the server hosting Swarm or elsewhere on your network.
Important-
If the server hosting your Helix Core Server cannot use packages, for example when it is running Windows, you need to copy the appropriate Swarm trigger script from
/opt/perforce/swarm/p4-bin/scripts
to the server hosting your Helix Core Server. Theswarm-trigger.pl
is for both Linux and Windows systems. Once copied, the trigger script needs to be configured. See Installing Triggers for details. -
The package installs a config file at
/opt/perforce/etc/swarm-trigger.conf
that you will need to modify. See Installing Triggers for more details on configuring that file.
Install the Swarm triggers package on the server hosting your Helix Core Server (run this command as root):
yum install helix-swarm-triggers
-
-
Optional: Install the Swarm optional package, on the server hosting Swarm.
While not required, installing this package installs the dependencies required to use the ImageMagick and LibreOffice Swarm modules. These modules provide previews of a variety of image and office documents. Run this command as root:
yum install helix-swarm-optional
-
Complete the Post-installation configuration steps.