Installing Spacewalk Server on RHEL/CentOS/SL 7

This is my method for installing Spacewalk server on RHEL7 -- this works for CentOS7 and Scientific7. Spacewalk is a system management and automation server for RHEL based systems.

Learn from my mistakes:

If you're installing Spacewalk in a VM, make sure you give it at least 25GB of space to be safe. I left it on the default 10GB, and the 6GB left-over after installing SL7 wasn't enough space to initialize the Postgres database.

Install Spacewalk

Spacewalk depends on several EPEL packages, including OpenJDK, so we'll make sure the EPEL repository is installed:
# yum install epel-release

Now, we'll install the Spacewalk repository:
# rpm -Uvh

Update the system:
# yum clean metadata && yum update

Spacewalk requires a database backend. By default, it can configure and install PostgreSQL:
# yum install spacewalk-setup-postgresql

Finally, install Spacewalk with the Postgres backend (this one will take a while):
# yum install spacewalk-postgresql

Configure the Firewall

Spacewalk uses HTTP/S to communicate with the client machines. Port 5222 is also opened. This allows the Spacewalk server to push instant commands to the client machines over a tunnel.

Enable HTTPS:
# firewall-cmd --add-service=https --permanent

Enable HTTP:
# firewall-cmd --add-service=http --permanent

Enable Port 5222:
# firewall-cmd --add-port=5222/tcp --permanent
# firewall-cmd --add-port=5222/udp --permanent

Reload the Firewall:
# firewall-cmd --reload

Configure Spacewalk

Spacewalk requires a FQDN for the server to function properly. If you're working in an environment with a local DNS server, set it up that way. If you're not, modify the /etc/hosts file to include the following, or similar to your environment:	spacewalk.glmdev.local	spacewalk

Now, run the Spacewalk configuration command:

You'll need to provide the following:

  • An administrator's email-address
  • Confirmation to configure Apache2 with default SSL settings
  • A CA certificate password for the Spacewalk self-signed certificate
  • Organization and location information for said certificate
  • Confirmation to enable tftp and xinetd

After the wizard completes, we can open the web portal by visiting the FQDN of the host. You'll receive a certificate error because the certificate is self-signed. Add an exception and continue. You'll then be prompted to create an administrative user for your organization. After creating the user, you'll be dropped at the Spacewalk portal!

No Comments
Back to top