15.3.2. Attaching and Removing Subscriptions through the Command Line Attaching Subscriptions

Attaching subscriptions to a system requires specifying the individual product or subscription to attach, using the --pool option.
[root@server1 ~]# subscription-manager subscribe --pool=XYZ01234567
The options for the subscribe command are listed in Table 15.3, “subscribe Options”.
The ID of the subscription pool for the purchased product must be specified. The pool ID is listed with the product subscription information, which is available from running the list command:
[root@server1 ~]# subscription-manager list --available

    Available Subscriptions
ProductName:            RHEL for Physical Servers
ProductId:              MKT-rhel-server
PoolId:                 ff8080812bc382e3012bc3845ca000cb
Quantity:               10
Expires:                2011-09-20
Alternatively,the best-fitting subscriptions, as identified by the subscription service, can be attached to the system by using the --auto option (which is analogous to the --autosubscribe option with the register command).
[root@server1 ~]# subscription-manager subscribe --auto

Table 15.3. subscribe Options

Options Description Required
--pool=pool-id Gives the ID for the subscription to attach to the system. Required, unless --auto is used
--auto Automatically attaches the system to the best-match subscription or subscriptions. Optional
--quantity=number Attaches multiple counts of a subscription to the system. This is used to cover subscriptions that define a count limit, like using two 2-socket server subscriptions to cover a 4-socket machine. Optional
--servicelevel=None|Standard|Premium Sets the service level to use for subscriptions on that machine. This is only used with the --auto option. Optional