Created redmine issue http://projects.theforeman.org/issues/17756 from this bug
I spoke with jcalla and the command worked in a host with 12k hosts, besides it took 2 hours to complete due to the high number of hosts. So I am moving this bug to VERIFIED.
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. https://access.redhat.com/errata/RHSA-2018:0336