Installing SpaceWalk (using a remote database)

Jurjen Bokma

July 2008


RedHat SpaceWalk is the Open Source version of RedHat's satellite software. Two machines are involved in its istallation:

Following the SpaceWalk HowToInstall, I did the following:

Procedure 84.  Installing SpaceWalk
  1. rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-2.noarch.rpm


      
    Retrieving http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-2.noarch.rpm
    warning: /var/tmp/rpm-xfer.Zy9sSY: Header V3 DSA signature: NOKEY, key ID 217521f6
    Preparing...                ########################################### [100%]
    1:epel-release           ########################################### [100%]
      

  2. Edit /etc/yum.repos.d/spacewalk.repo to contain:

    [spacewalk]
    name=Spacewalk
    baseurl=http://spacewalk.redhat.com/yum/rhel/5Server/$basearch/
    gpgkey=http://spacewalk.redhat.com/yum/RPM-GPG-KEY-spacewalk
    enabled=1
    gpgcheck=1
    	

  3. yum install spacewalk


      
    <snip>
    Error: rhns-app conflicts with specspo
    Error: rhns-xp conflicts with specspo
    Error: Missing Dependency: oracle-instantclient-basic = 10.2.0.4 is needed by package oracle-lib-compat
    Error: Missing Dependency: oracle-instantclient-basic is needed by package perl-DBD-Oracle
    Error: Missing Dependency: oracle-instantclient-basic >= 10.2.0 is needed by package rhn-oracle-jdbc
      

  4. rpm -e specspo

    Fetch oracle-instantclient-basic-10.2.0.4-1.i386.rpm from the Oracle website and install it:

    rpm -iv oracle-instantclient-basic-10.2.0.4-1.i386.rpm oracle-instantclient-jdbc-10.2.0.4-1.i386.rpm oracle-instantclient-sqlplus-10.2.0.4-1.i386.rpm oracle-instantclient-devel-10.2.0.4-1.i386.rpm


      
    Preparing packages for installation...
    oracle-instantclient-basic-10.2.0.4-1
    oracle-instantclient-devel-10.2.0.4-1
    oracle-instantclient-jdbc-10.2.0.4-1
    oracle-instantclient-sqlplus-10.2.0.4-1
      

  5. yum install spacewalk


      
    <snip>
    Transaction Summary
    =============================================================================
    Install    227 Package(s)
    Update       0 Package(s)
    Remove       0 Package(s)

    Total download size: 149 M
    Is this ok [y/N]: y
    <snip>
    warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID 430a1c35
    Importing GPG key 0x430A1C35 "Spacewalk <spacewalk-devel@redhat.com>" from http://spacewalk.redhat.com/yum/RPM-GPG-KEY-spacewalk
    Is this ok [y/N]: y
    <snip>
    noarch 0:1.1.3.4.O-2jpp.ep1.1.el5.1
    Complete!
      


  6.   
    export PATH="${PATH}:/usr/lib/oracle/10.2.0.4/client/bin"
    ORACLE_HOME=/usr/lib/oracle/10.2.0.4
    export LD_LIBRARY_PATH=/usr/lib/oracle/10.2.0.4/client/lib
    semanage fcontext -a -t textrel_shlib_t '/usr/lib/oracle/10.2.0/client/lib/*'
    restorecon -R /usr/lib/oracle/10.2.0/client/lib
      


      
    [root@host ~]# spacewalk-setup --disconnected
    * Loading answer file: /usr/share/spacewalk/setup/defaults.conf.
    * Setting up environment and users.
    ** GPG: Initializing GPG and importing RHN key.
    * Setting up database.
    ** Database: Setting up database connection.
    DB User? username
    DB Password?
    DB SID? sid
    DB hostname? db.host.yourdomain.com
    DB port [1521]? 1522
    DB protocol [TCP]?
    ** Database: Testing database connection.
    ** Database: Populating database.
    sh: dbhome: command not found
    *** Progress: #
    * Performing initial configuration.
    * Activating Satellite.
    ** Loading Satellite Certificate.
    ** Verifying certificate locally.
    There was a problem activating the satellite: Certificate expired.
    [root@host ~]# date
    Thu Feb 19 12:24:04 CET 2015
      


  7.   
    ntpdate ip-of-ntp-server
      


      
    28 Jul 11:48:44 ntpdate[15293]: step time server 129.125.60.251 offset -207106607.716361 sec
    [root@host ~]# date
    Mon Jul 28 11:48:48 CEST 2008
      


      
    yum -q install usermode-gtk pyOpenSSL
    cp /usr/share/spacewalk/setup/defaults.conf spacewalk-install-answers-2.conf
    vi !$
    spacewalk-setup --disconnected --answer-file=spacewalk-install-answers-2.conf
      


      
    [root@host ~]# spacewalk-setup --disconnected --answer-file=spacewalk-install-answers-2.conf
    * Loading answer file: spacewalk-install-answers-2.conf.
    * Setting up environment and users.
    ** GPG: Initializing GPG and importing RHN key.
    * Setting up database.
    ** Database: Setting up database connection.
    ** Database: Testing database connection.
    ** Database: Populating database.
    sh: dbhome: command not found
    *** Progress: ##################################################################################
    * Performing initial configuration.
    * Activating Satellite.
    ** Loading Satellite Certificate.
    ** Verifying certificate locally.
    ** Activating Satellite.
    * Enabling Monitoring.
    * Creating SSL certificates.
    Email Address [j.bokma@cs.rug.nl]?
    ** SSL: Generating CA certificate.
    ** SSL: Deploying CA certificate.
    ** SSL: Generating server certificate.
    ** SSL: Storing SSL certificates.
    Use of uninitialized value in chown at /usr/bin/rhn-generate-pem.pl line 57.
    Use of uninitialized value in chown at /usr/bin/rhn-generate-pem.pl line 57.
    * Deploying configuration files.
    * Update configuration in database.
    * Restarting services.
    Installation complete.
    Visit https://host to create the satellite administrator account.
    [root@host ~]#
      

  8. setenforce 0 To temporarily turn off selinux and log in to your https://host.service.domain.com to do the rest of the configuration.