Bug #31810
closedGlobal Registration: Unable to re-register with satellite using the Curl Command
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1919888
Description of problem:
When trying to re-register a system using the generated curl command it throws the error mentioning that the system is already registered and it would need to use the option --force.
Error:
--------
This system is already registered. Use --force to override
---------
When --force option is using the below error is the output.
Error:
================================================================================================
[root@localhost ~]# curl X GET "https://satellite.example.com:9090/register?activation_key=new&hostgroup_id=3&location_id=2&operatingsystem_id=3&organization_id=1" -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjo0LCJpYXQiOjE2MTE1Njk4ODEsImp0aSI6ImUxMzJkOGU1OGQ2MTc4YTc4ODM3ZjU2ZjY0MzJiZmZhYTZjYmI2OWY0ODFmMGFiYmFjNTJkOGZhZWVlN2JjMDMiLCJleHAiOjE2MTE1ODQyODF9.fLNNZqN_7HNYFcCyspX6Usqt6AN3u5oOUA3DIdEB6Pk' | bash --force:--:-- --:--:-- --:--:-- 20017
bash: --force: invalid option
Usage: bash [GNU long option] [option] ...
bash [GNU long option] [option] script-file ...
GNU long options:
--debug
--debugger
--dump-po-strings
--dump-strings
--help
--init-file
--login
--noediting
--noprofile
--norc
--posix
--rcfile
--rpm-requires
--restricted
--verbose
--version
Shell options:
-ilrsD or -c command or -O shopt_option (invocation only)
-abefhkmnptuvxBCHP or -o option
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 10369 100 10369 0 0 20017 0 -
curl: (23) Failed writing body (0 != 10369)
================================================================================================
Version-Release number of selected component (if applicable):
[root@localhost ~]# rpm -qa | grep -i satellite
satellite-6.9.0-0.3.beta.el7sat.noarch
ansiblerole-satellite-receptor-installer-0.6.13-1.el7sat.noarch
satellite-maintain-0.0.1-1.el7sat.noarch
satellite-common-6.9.0-0.3.beta.el7sat.noarch
satellite-installer-6.9.0.6-1.el7sat.noarch
tfm-rubygem-foreman_theme_satellite-7.0.1.4-1.el7sat.noarch
satellite-cli-6.9.0-0.3.beta.el7sat.noarch
How reproducible:
100%
Steps to Reproduce:
1. Register a client system using the generated curl command
2. Do NOT un-register the system and then run the same curl command again. It will ask to use the --force option.
3. Run the same curl command with the --force option.
Actual results:
Do not register the system the second time.
Expected results:
[1] It should use the option or --force
[2] Curl command should process any additional parameters supported for subscription-manager.
Additional info:
Updated by Leos Stejskal almost 4 years ago
- Related to Feature #31240: New Host Registration Form added
Updated by Leos Stejskal almost 4 years ago
- Related to deleted (Feature #31240: New Host Registration Form)
Updated by Leos Stejskal almost 4 years ago
- Related to Feature #31807: Host Registration - UI Form improvements added
Updated by Leos Stejskal almost 4 years ago
- Related to Feature #31820: GR template - add --force option for Sub-man to re-register a host added
Updated by Ian Ballou almost 4 years ago
- Target version set to Katello 3.18.2
- Triaged changed from No to Yes
Will try to get this in 3.18.2, if not it'll get in 3.18.3.
Updated by Leos Stejskal almost 4 years ago
- Status changed from New to Duplicate
Duplicate of https://projects.theforeman.org/issues/31820