15.3.2.2. Removing Subscriptions from the Command Line
A system can be attached to multiple subscriptions and products. Similarly, a single subscription or all subscriptions can be removed from the system.
Running the
unsubscribe command with the --all option removes every product subscription and subscription pool that is currently attached to the system.
subscription-manager unsubscribe --all
[root@server1 ~]# subscription-manager unsubscribe --all
It is also possible to remove a single product subscription. Each product has an identifying X.509 certificate installed with it. The product subscription to remove is identified in the
unsubscribe command by referencing the ID number of that X.509 certificate.
- Get the serial number for the product certificate, if you are removing a single product subscription. The serial number can be obtained from the subscription#
.pemfile (for example,392729555585697907.pem) or by using thelistcommand. For example:Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Run the subscription-manager tool with the
--serialoption to specify the certificate.subscription-manager unsubscribe --serial=11287514358600162
[root@server1 ~]# subscription-manager unsubscribe --serial=11287514358600162Copy to Clipboard Copied! Toggle word wrap Toggle overflow