Description of problem: [root@client01-rhel6-beta2 src]# ./subscription-manager-cli register --username=admin --pass=admin54ce8886-1386-4ee7-95e5-aec6e08b92f0 admin [root@client01-rhel6-beta2 src]# ./subscription-manager-cli subscribe --pool=1 [root@client01-rhel6-beta2 src]# ls /etc/pki/entitlement/product/ 10.pem [root@client01-rhel6-beta2 src]# ./subscription-manager-cli reregister 54ce8886-1386-4ee7-95e5-aec6e08b92f0 admin [root@client01-rhel6-beta2 src]# ls /etc/pki/entitlement/product/ 10.pem [root@client01-rhel6-beta2 src]# mv /etc/pki/consumer/ cert.pem key.pem [root@client01-rhel6-beta2 src]# mv /etc/pki/consumer/cert.pem /bak mv: overwrite `/bak/cert.pem'? y [root@client01-rhel6-beta2 src]# ./subscription-manager-cli reregister --username=admin --pass=admin 927899e9-025e-46e9-84e3-d7018c86314a admin [root@client01-rhel6-beta2 src]# ./subscription-manager-cli list --consumed No Consumed subscription pools to list [root@client01-rhel6-beta2 src]# ls /etc/pki/entitlement/product/ [root@client01-rhel6-beta2 src]#
The only way to fix this is to store off the uuid when the register occurs. That way in the event of a corrupt or missing identity certificate, we can register with the old uuid and maintain our subscriptions.
added --consumerid param to reregister fixed by commits: 7e1e0baa02a28aabf19e4394f06a199287ed50c9 d92eaed9bde595c32f09907ab4d442b8d020da12
[root@jsefler-rhel6-client01 ~]# rpm -q subscription-manager subscription-manager-0.75-1.git.29.c3b1d88.fc12.i386 [root@jsefler-rhel6-client01 ~]# subscription-manager-cli unregister This system is currently not registered. [root@jsefler-rhel6-client01 ~]# subscription-manager-cli register --username=admin --pass=admin 7c6d0aac-4cb2-4257-9ea5-748cbc32146d admin [root@jsefler-rhel6-client01 ~]# subscription-manager-cli subscribe --pool=1 [root@jsefler-rhel6-client01 ~]# ls /etc/pki/entitlement/product/ 15.pem [root@jsefler-rhel6-client01 ~]# subscription-manager-cli reregister 7c6d0aac-4cb2-4257-9ea5-748cbc32146d admin [root@jsefler-rhel6-client01 ~]# rm /etc/pki/consumer/cert.pem rm: remove regular file `/etc/pki/consumer/cert.pem'? y [root@jsefler-rhel6-client01 ~]# rm /etc/pki/entitlement/product/*.pem rm: remove regular file `/etc/pki/entitlement/product/15.pem'? y [root@jsefler-rhel6-client01 ~]# subscription-manager-cli reregister --help Usage: subscription-manager-cli reregister [OPTIONS] re-register the client to a Unified Entitlement Platform. Options: -h, --help show this help message and exit --debug=DEBUG debug level --username=USERNAME specify a username --password=PASSWORD specify a password --consumerid=CONSUMERID register to an existing consumer [root@jsefler-rhel6-client01 ~]# subscription-manager-cli reregister --consumerid=7c6d0aac-4cb2-4257-9ea5-748cbc32146d --username=admin --pass=admin 7c6d0aac-4cb2-4257-9ea5-748cbc32146d admin VERIFIED: ^^^ Notice that the reregister with the consumerid option returns the same cert hash Now wait for the rhsmcertd refresh frequency (certFrequency=1) minutes and then... [root@jsefler-rhel6-client01 ~]# ls /etc/pki/entitlement/product/ 15.pem VERIFIED: ^^^ The product cert is re-dropped moving to VERIFIED... Additional Info: See related bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=627685
Group move of VERIFIED Candlepin component bugs to RELEASE_PENDING