Difference between revisions of "SUSE Manager/Register RedHat traditional clients"

From MicroFocusInternationalWiki
Jump to: navigation, search
(Working with the ISO)
(Traditionally managed clients (rhn stack))
Line 49: Line 49:
 
* After the end of the synchronization, you will be able to manipulate this channel as a regular SUSE Manager channel.
 
* After the end of the synchronization, you will be able to manipulate this channel as a regular SUSE Manager channel.
  
 +
NOTE: If you are using RH Native parent/child channels, you can simply clone the base media channel into the res7 (rhel-x86_64-server-7) parent.  The next step requires that res7 parent and children.
  
 +
5. Create the res7 bootstrap repository - once all is synced - with this command:
  
 +
  mgr-create-bootstrap-repo --with-custom-channels rhel-x86_64-server-7
  
  
 
+
6. Create/edit your bootstrap script to correctly reflect the following:
 
+
 
+
 
+
 
+
 
+
Create/edit your bootstrap script to correctly reflect the following:
+
  
 
  <nowiki># can be edited, but probably correct (unless created during initial install):
 
  <nowiki># can be edited, but probably correct (unless created during initial install):
Line 65: Line 62:
 
# NOTE: ACTIVATION_KEYS *must* be used to bootstrap a client machine.
 
# NOTE: ACTIVATION_KEYS *must* be used to bootstrap a client machine.
  
ACTIVATION_KEYS=1-centos7
+
ACTIVATION_KEYS=1-rh7
  
ORG_GPG_KEY=res.key,RPM-GPG-KEY-CentOS-6,suse-307E3D54.key,suse-9C800ACA.key,RPM-GPG-KEY-spacewalk-2015
+
ORG_GPG_KEY=res.key,RPM-GPG-KEY-redhat-release,,suse-307E3D54.key,suse-9C800ACA.key,RPM-GPG-KEY-spacewalk-2015
  
  
Line 80: Line 77:
  
 
  <nowiki># This section is for commands to be executed after registration
 
  <nowiki># This section is for commands to be executed after registration
mv /etc/yum.repos.d/Cent* /root/
 
yum clean all
 
 
chkconfig rhnsd on
 
chkconfig rhnsd on
 
chkconfig osad on
 
chkconfig osad on
Line 87: Line 82:
 
service osad restart
 
service osad restart
 
</nowiki>
 
</nowiki>
 +
 +
7. Bootstrap your rh7 client and it should register and be manageable.

Revision as of 16:50, 23 August 2017

Traditionally managed clients (rhn stack)

SUSE Manager Main Page

In order to register RedHat (traditional/RHN clients) the following steps are necessary. These instructions are for RHEL 7, but can be adjusted/repeated to accommodate RHEL 6.

1. Be sure to copy any and all relevant GPG keys to /srv/www/htdocs/pub. This includes the Spacewalk key, SUSE keys and the Red Hat keys. By copying them there, you can reference them in a comma-delimited list in your bootstrap script (see example below)

 Spacewalk key: http://spacewalk.redhat.com/yum/RPM-GPG-KEY-spacewalk-2015
 Red Hat keys: http://www.redhat.com/contact/security-response-team/gpg-keys.html

3. Mirror the res7 SUSE Manager tools repository. This will work whether patches come from SCC or from RH native CDN. SUSE Manager subscriptions include mirroring permissions for the res7 SUSE Manager tools channel. Add it to be sync'd from the SUSE Manager command line like this:

 mgr-sync add channels rhel-x86_64-server-7 rhel-x86_64-server-7

4. Once the tools sync is complete, you will need to ensure RHEL base media is there as a custom child channel under this parent as well. If you are using the Expanded Support channels,

On the SUSE Manager Web UI:

  • Create the channel in SUSE Manager

Go to "Channels" -> "Manage Software Channels" - > "Create channel" and fill the basic channel details.

Best practice is to make it a child channel to the corresponding RH distribution/architecture channel from Customer Center. The parent channel (rhel-x86_64-server-7) will have zero packages.

On the CLI of SUSE Manager as root:

  • Copy the ISO to your SUSE Manager server in /tmp
  • Create a directory:
   # mkdir -p /srv/www/htdocs/pub/rhel
  • mount the iso:
   # mount -o loop /tmp/name_of_iso /srv/www/htdocs/pub/rhel
  • Start spacewalk-repo-sync:
   # spacewalk-repo-sync -c your_channel_name -u https://127.0.0.1/pub/rhel/
   ## Note you may need to use http://suma_server_fqdn/pub/rhel
Repo URL: https://127.0.0.1/pub/rhel/Server/
Packages in repo:              3690
Packages already synced:          0
Packages to sync:              3690
1/3690 : texlive-latex-2007-57.el6_2-0.x86_64
2/3690 : boost-filesystem-1.41.0-18.el6-0.i686
3/3690 : policycoreutils-newrole-2.0.83-19.39.el6-0.x86_64
[...]
  • After the end of the synchronization, you will be able to manipulate this channel as a regular SUSE Manager channel.

NOTE: If you are using RH Native parent/child channels, you can simply clone the base media channel into the res7 (rhel-x86_64-server-7) parent. The next step requires that res7 parent and children.

5. Create the res7 bootstrap repository - once all is synced - with this command:

 mgr-create-bootstrap-repo --with-custom-channels rhel-x86_64-server-7


6. Create/edit your bootstrap script to correctly reflect the following:

# can be edited, but probably correct (unless created during initial install):

# NOTE: ACTIVATION_KEYS *must* be used to bootstrap a client machine.

ACTIVATION_KEYS=1-rh7

ORG_GPG_KEY=res.key,RPM-GPG-KEY-redhat-release,,suse-307E3D54.key,suse-9C800ACA.key,RPM-GPG-KEY-spacewalk-2015


FULLY_UPDATE_THIS_BOX=0

yum clean all
# Install the prerequisites
yum -y install yum-rhn-plugin rhn-setup 

Add these lines to the very bottom of your script, (just before echo “-bootstrap complete -” )

# This section is for commands to be executed after registration
chkconfig rhnsd on
chkconfig osad on
service rhnsd restart
service osad restart

7. Bootstrap your rh7 client and it should register and be manageable.