Bug 1284679
| Summary: | record number of hosts per compute resource type in foreman-debug for statistical purposes | ||
|---|---|---|---|
| Product: | Red Hat Satellite | Reporter: | Jan Hutař <jhutar> |
| Component: | Foreman Debug | Assignee: | Lukas Zapletal <lzap> |
| Status: | CLOSED WONTFIX | QA Contact: | |
| Severity: | low | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | Nightly | CC: | bbuckingham, bkearney, lzap, xdmoon, zhunting |
| Target Milestone: | Unspecified | Keywords: | EasyFix, Triaged |
| Target Release: | Unused | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2017-01-13 20:58:08 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 1115190 | ||
Jan, why don't you simply create a pull request? https://github.com/theforeman/foreman/blob/develop/script/foreman-debug There is a bug I am working on (https://bugzilla.redhat.com/show_bug.cgi?id=1305089) that will add list of hosts. I can keep the compute_resource_id column, is it enough for you? Create a pull request: https://github.com/theforeman/foreman/pull/3196 (depends on Lukas's branch lzap:debug-db-13703) lzap, can this be closed as a dupe of https://bugzilla.redhat.com/show_bug.cgi?id=1305089 It's actually something different, but we will build this on of the other bug which was rescheduled to 6.3. Doing so. Per 6.3 planning, moving out non acked bugs to the backlog This should be implemented as a CSV exporter as part of https://bugzilla.redhat.com/show_bug.cgi?id=1305089 This is an older bug which I do not envision being addressed in the near term. I am closing this out. If you believe doing so is an issue, please feel free to re-open and provide additional business information. Thank you. |
Description of problem: When we want to learn which compute resources are most used, we have to collect these data somewhere. Maybe foreman-debug can be used? Version-Release number of selected component (if applicable): foreman-debug-1.7.2.46-1.el6_6sat.noarch How reproducible: always Steps to Reproduce: 1. Attempt to estimate which compute resources are used at most Actual results: There are no such data available Expected results: Maybe foreman debug can collect hosts counts per compute resource types (no customer internal info like concrete hosts or compute resource names) Additional info: Maybe something like this could be added to foreman-debug? # diff -u `type -p foreman-debug `{.ORIG,} --- /usr/sbin/foreman-debug.ORIG 2015-11-23 16:06:15.646949752 -0500 +++ /usr/sbin/foreman-debug 2015-11-23 16:28:59.070276247 -0500 @@ -270,6 +270,7 @@ add_files /var/log/{httpd,apache2}/foreman-ssl_access_ssl.log* add_cmd "echo \"select id,name,value from settings where name not similar to '%(pass|key|secret)'\" | su postgres -c 'psql foreman'" "foreman_settings_table" add_cmd "echo 'select type,name,host,port,account,base_dn,attr_login,onthefly_register,tls from auth_sources' | su postgres -c 'psql foreman'" "foreman_auth_table" +add_cmd "echo 'select count(hosts.name), compute_resources.type from hosts, compute_resources where hosts.compute_resource_id = compute_resources.id group by compute_resources.type;' | su postgres -c 'psql foreman'" "foreman_compute_resources_host_counts" add_cmd "foreman-selinux-relabel -nv" "foreman_filecontexts" add_files /etc/{sysconfig,default}/foreman