Bug 840152 - man page for rhn-migrate-classic-to-rhsm needs changes for rhel59
man page for rhn-migrate-classic-to-rhsm needs changes for rhel59
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: subscription-manager (Show other bugs)
5.9
Unspecified Unspecified
unspecified Severity medium
: rc
: ---
Assigned To: William Poteat
Entitlement Bugs
: Documentation
Depends On:
Blocks: 771748
  Show dependency treegraph
 
Reported: 2012-07-13 17:56 EDT by John Sefler
Modified: 2013-01-07 22:57 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
No documentation necessary.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-01-07 22:57:05 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description John Sefler 2012-07-13 17:56:44 EDT
Description of problem:
The man page for rhn-migrate-classic-to-rhsm is now out-of-date since the usage for rhn-migrate-classic-to-rhsm has changed in rhel59.  See the new options below.


Version-Release number of selected component (if applicable):
[root@ibm-x3620m3-01 ~]# rpm -q subscription-manager-migration
subscription-manager-migration-1.0.9-1.el5


Steps to Reproduce:

[root@ibm-x3620m3-01 ~]# rhn-migrate-classic-to-rhsm --help
usage: rhn-migrate-classic-to-rhsm [OPTIONS]

options:
  -f, --force           Ignore channels not available on RHSM
  -g, --gui             Launch the GUI tool to subscribe the system, instead
                        of autosubscribing
  -n, --no-auto         Don't execute the autosubscribe option while
                        registering with subscription manager.
  -s SERVICELEVEL, --servicelevel=SERVICELEVEL
                        Service level to subscribe this system to. For no
                        service level use --service-level=""
  -h, --help            show this help message and exit

The command line options described above are newly re-structured in rhel59.  The man page OPTIONS shown below are out-of-date....

[root@ibm-x3620m3-01 ~]# man -P cat rhn-migrate-classic-to-rhsm | egrep -A25 "O.*P.*T.*I.*O.*N.*S"
OPTIONS
       -h, --help
              Prints the specific help information for the given command.


       -f, --force
              Ignore channels not available on Certificate-based Red Hat  Net-
              work.  The channels in Red Hat Network Classic are mapped to the
              product certificates used by Certificate-based Red Hat  Network.
              However,  not every channel has a certificate mapping, which can
              cause errors during migration. Using this option skips any chan-
              nels  which are not mapped to Certificate-based Red Hat Network.


       -c, --cli-only
              Uses subscription-manager register --autosubscribe to apply  all
              relevant subscriptions from Certificate-based Red Hat Network to
              the system automatically.


       -n, --no-auto
              Unsubscribes the system from Red Hat Network  Classic  but  does
              not  subsequently  register  the system to Certificate-based Red
              Hat Network or subscribe the system to any entitlements.
Comment 1 RHEL Product and Program Management 2012-07-13 17:58:20 EDT
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
Comment 3 RHEL Product and Program Management 2012-07-14 09:08:04 EDT
This request was evaluated by Red Hat Product Management for inclusion
in a Red Hat Enterprise Linux release.  Product Management has
requested further review of this request by Red Hat Engineering, for
potential inclusion in a Red Hat Enterprise Linux release for currently
deployed products.  This request is not yet committed for inclusion in
a release.
Comment 4 Deon Ballard 2012-07-19 13:13:32 EDT
Commited to github, and in the subscription management guide.

commit 621d5482082d60992f54a0446c0718872881e986
Comment 5 Deon Ballard 2012-07-19 13:18:35 EDT
Oh, Will, I just realized I stole your bug. Hope you don't mind; I thought this was in my queue. :-/
Comment 7 Sharath Dwaral 2012-08-02 09:54:20 EDT
Version:
# rpm -qa | egrep "subscription-manager|python-rhsm"
subscription-manager-1.0.11-1.git.10.ac56ecc.el5
subscription-manager-migration-1.0.11-1.git.10.ac56ecc.el5
subscription-manager-firstboot-1.0.11-1.git.10.ac56ecc.el5
subscription-manager-gui-1.0.11-1.git.10.ac56ecc.el5
subscription-manager-migration-data-1.11.2.2-1.git.2.c3c8e22.el5
python-rhsm-1.0.4-1.git.7.47e5112.el5

Verification:

# rhn-migrate-classic-to-rhsm --help
Usage: rhn-migrate-classic-to-rhsm [OPTIONS]

options:
  -f, --force           Ignore channels not available on RHSM
  -g, --gui             Launch the GUI tool to subscribe the system, instead
                        of autosubscribing
  -n, --no-auto         Don't execute the autosubscribe option while
                        registering with subscription manager.
  -s SERVICELEVEL, --servicelevel=SERVICELEVEL
                        Service level to subscribe this system to. For no
                        service level use --service-level=""
  -h, --help            show this help message and exit





# man -P cat rhn-migrate-classic-to-rhsm

rhn-migrate-classic-to-rhsm(8)                  rhn-migrate-classic-to-rhsm(8)



NAME
       rhn-migrate-classic-to-rhsm - Migrates a system profile from Red Hat Network Classic Hosted to Red Hat Network Subscription Management (hosted).


SYNOPSIS
       rhn-migrate-classic-to-rhsm [--force|--gui|--no-auto|--servicelevel=SERVICE_LEVEL|--help]


DESCRIPTION
       rhn-migrate-classic-to-rhsm  migrates  a  system profile which is registered with Red Hat Network Classic to Red Hat Network Subscription Management. This is
       intended for hosted-to-hosted migrations, not for migrating from a Satellite system.


       This script migrates configuration, from a channel-based subscription framework to a certificate-based subscription framework. While the rhn-migrate-classic-
       to-rhsm  script performs the migration operation, the data used to map the channels to the corresponding product certificates is defined in the subscription-
       manager-migration-data package. The subscription-manager-migration-data package must be installed before the rhn-migrate-classic-to-rhsm script  can  be  run
       successfully.


BACKGROUND
       Access  to support and updates for products is determined through subscriptions.  Subscriptions are assigned to a system, which means that the system has the
       right to install and update a product with full support. Subscriptions for an entire organization are tracked through a subscription service, either a  local
       Satellite  or  hosted  Red Hat Network.  The system registers with the subscription service and receives an inventory ID number. When subscriptions are allo-
       cated to a system, it is noted in the subscription service.


       For environments which use a hosted subscription service rather than a local Satellite system, systems were registered with Red Hat Network Classic. Red  Hat
       Network  Classic, however, has been replaced by Red Hat Network Subscription Management. The differences between the two systems are described in this Knowl-
       edgebase article: <https://access.redhat.com/kb/docs/DOC-45987>


       Registering with a subscription service is exclusive. If a system is registered with Red Hat Network Classic, it cannot simultaneously be registered with Red
       Hat  Network  Subscription Management. The rhn-migrate-classic-to-rhsm tool is provided specifically so that there is a way to transition from the deprecated
       Red Hat Network Classic to the new Red Hat Network Subscription Management.


OPTIONS
       -h, --help
              Prints the specific help information for the given command.


       -f, --force
              Ignore channels not available on Red Hat Network Subscription Management. The channels in Red Hat Network Classic are mapped to the  product  certifi-
              cates  used by Red Hat Network Subscription Management. However, not every channel has a certificate mapping, which can cause errors during migration.
              Using this option skips any channels which are not mapped to Red Hat Network Subscription Management.


       -g, --gui
              Opens the Subscription Manager UI so that administrators can manually select which subscriptions to apply to the  system.  Without  this  option,  the
              migration  script automatically runs ’subscription-manager register --autosubscribe’ to register the system to Red Hat Network Subscription Management
              and then apply all relevant subscriptions.


       -n, --no-auto
              Unsubscribes the system from Red Hat Network Classic but does not subsequently register the system to Red Hat Network Subscription Management or  sub-
              scribe the system to any entitlements.


       -s SERVICE_LEVEL, --servicelevel=SERVICE_LEVEL
              Sets  a  preferred  service  level  for the system, such as premium or standard. This service level preference is then used as one of the criteria for
              autosubscribing the system.


USAGE
       The migration process moves the system from the inventory in one subscription service (Red Hat Network Classic) to the new subscription service (Red Hat Net-
       work Subscription Management), and then re-applies the subscriptions to the system. The script runs through these steps:


              1. Authenticate to both Red Hat Network Classic and Red Hat Network Subscription Management to verify the account settings.


              2. Get a channel list for the system.


              3. Match each channel to a corresponding certificate map.


              4. Copy over the product certificates for the old channels.


              5. Unregister from Red Hat Network Classic.


              6. Register with Red Hat Network Subscription Management and auto-subscribe to the best-matched subscriptions. (Alternatively, the --gui option can be
              used to launch the Subscription Manager UI to assign subscriptions manually.)


       After migration, the system facts maintained by Subscription Manager display what script was used for migration and what the previous system ID was.
       [root@server ~]# subscription-manager facts --list | grep migr
       migration.classic_system_id: 09876
       migration.migrated_from: rhn_hosted_classic


   MIGRATION AND AUTOSUBSCRIBE
       The rhn-migrate-classic-to-rhsm tool can autosubscribe the system to the best-matching subscriptions. This allows migrations to be automated.


       The script does prompt for a username and password to use to register the system; this same account is used to authenticate with both Red Hat Network Classic
       and Red Hat Network Subscription Management.


       Optionally,  the  --servicelevel argument sets an SLA preference to use with the system. The SLA associated with a subscription is then evaluated when deter-
       mining what subscriptions to autosubscribe the system to, along with other factors like installed products, existing channel assignments, and architecture.

       [root@server ~]# rhn-migrate-classic-to-rhsm --servicelevel=premium
       RHN Username: jsmith@example.com
       Password:


       Retrieving existing RHN classic subscription information ...
       +----------------------------------+
       System is currently subscribed to:
       +----------------------------------+
       rhel-i386-client-5

       List of channels for which certs are being copied
       rhel-i386-client-5

       Product Certificates copied successfully to /etc/pki/product !!

       Preparing to unregister system from RHN classic ...
       System successfully unregistered from RHN Classic.

       Attempting to register system to RHN ...
       The system has been registered with id: abcd1234
       System ’server.example.com’ successfully registered to RHN.

       Attempting to auto-subscribe to appropriate subscriptions ...
       Installed Product Current Status:
       ProductName:            Red Hat Enterprise Linux Desktop
       Status:                 Subscribed

       Successfully subscribed.

       Please visit https://access.redhat.com/management/consumers/abcd1234 to view the details, and to make changes if necessary.


   MIGRATION AND MANUALLY SELECTING SUBSCRIPTIONS
       The --gui option opens the Subscription Manager GUI so that administrators can assign subscriptions to the system. As with  the  autosubscribe  process,  the
       script prompts for the RHN username and password for the use.

       [root@server ~]# rhn-migrate-classic-to-rhsm --gui
       RHN Username: jsmith@example.com
       Password:

       Retrieving existing RHN classic subscription information ...
       +----------------------------------+
       System is currently subscribed to:
       +----------------------------------+
       rhel-i386-client-5

       List of channels for which certs are being copied
       rhel-i386-client-5

       Product Certificates copied successfully to /etc/pki/product !!

       Preparing to unregister system from RHN classic ...
       System successfully unregistered from RHN Classic.

       Attempting to register system to RHN ...
       The system has been registered with id: abcd1234
       System server.example.com successfully registered to RHN.

       Launching the GUI tool to manually subscribe the system ...


   UNREGISTER FROM RED HAT NETWORK CLASSIC ONLY
       The  rhn-migrate-classic-to-rhsm  tool  can be used simply to unregister a system from Red Hat Network Classic without registering it to Red Hat Network Sub-
       scription Management or assigning subscriptions to the system.

       [root@server ~]# rhn-migrate-classic-to-rhsm --no-auto
       RHN Username: jsmith@example.com
       Password:

       Retrieving existing RHN classic subscription information ...
       +----------------------------------+
       System is currently subscribed to:
       +----------------------------------+
       rhel-i386-client-5

       List of channels for which certs are being copied
       rhel-i386-client-5

       Product Certificates copied successfully to /etc/pki/product !!

       Preparing to unregister system from RHN classic ...
       System successfully unregistered from RHN Classic.



FILES
       /etc/sysconfig/rhn/systemid
              The digital server ID for this machine if the system has been registered with Red Hat Network Classic.  This file does not exist otherwise.


       /etc/sysconfig/rhn/up2date
              The common configuration file used by RHN client programs.


       /var/log/rhsm/rhsm.log
              The Subscription Manager log file. This contains any errors registering the system to Red Hat Network Subscription Management or with subscribing  the
              system to entitlements.


       /etc/rhsm/facts/migration.facts
              The file which contains the migration information. This is displayed as one of the system facts by Subscription Manager.


       subscription-manager-migration-data.rpm
              The package which contains the mappings for the migration script to migrate channels to the appropriate product certificates.


SEE ALSO
       install-num-migrate-to-rhsm(8), subscription-manager(8).



AUTHORS
       Paresh Mutha <pmutha@redhat.com>, Mark Huth <mhuth@redhat.com>, Tasos Papaioannou <tpapaioa@redhat.com>


BUGS
       Report bugs to <http://bugzilla.redhat.com>.


COPYRIGHT
       Copyright © 2011 Red Hat, Inc.


       This is free software; see the source for copying conditions.  There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.



Version 0.4                      July 18, 2012  rhn-migrate-classic-to-rhsm(8)


Moving bug to VERIFIED
Comment 9 errata-xmlrpc 2013-01-07 22:57:05 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2013-0033.html

Note You need to log in before you can comment on or make changes to this bug.