Actions
Bug #25173
closedenabled_repos_upload plugin is slow
Difficulty:
Triaged:
Yes
Bugzilla link:
Description
In its current state, the enabled_repos_upload yum/dnf plugin imports the yum or dnf Python module and creates an associated object each time _replace_vars() is executed. This can lead to time consuming yum operations if there are a large number of enabled yum repositories.
Example
A server has 13 enabled yum repositories. With yum.YumBase() being executed each time _replace_vars() is called, this is the output from a simple yum check-update:
# time yum check-update
Loaded plugins: enabled_repos_upload, fastestmirror, package_upload, product-id, search-disabled-repos, subscription-manager, tracer_upload
Loading mirror speeds from cached hostfile
Centos_Centos_7_Base
Centos_Centos_7_Extras
Centos_Centos_7_Updates
Centos_Centos_sclo
Centos_Centos_sclo-rh
Datadog_Datadog
EPEL_EPEL_Centos7
Extra_rpm-extra
Katello-agent_agent-3_7
MySQL_Enterprise_MySQL_Enterprise
Puppet_puppet_4
Zabbix_Zabbix_3_2
Uploading Enabled Repositories Report
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
Loaded plugins: fastestmirror, product-id, subscription-manager
real 0m35.492s
user 0m8.330s
sys 0m0.611s
The plugin's output is too long and it takes 35 seconds to report that nothing is available to update.
Updated by Kevin Bowers about 6 years ago
- Pull request https://github.com/Katello/katello-host-tools/pull/78 added
Updated by Kevin Bowers about 6 years ago
- Pull request https://github.com/Katello/katello-host-tools/pull/80 added
- Pull request deleted (
https://github.com/Katello/katello-host-tools/pull/78)
Updated by The Foreman Bot about 6 years ago
- Status changed from New to Ready For Testing
Updated by Jonathon Turel about 6 years ago
- Target version set to Katello 3.10.0
- Found in Releases deleted (
Katello 3.10.0)
Updated by Jonathon Turel about 6 years ago
- Subject changed from Host Tools - enabled_repos_upload plugin is slow to enabled_repos_upload plugin is slow
- Category set to Client/Agent
- Status changed from Ready For Testing to Closed
Actions