Bug 1425922

Summary: [RFE] Get system locale setting into cp_consumer_facts
Product: Red Hat Enterprise Linux 7 Reporter: Diego Fernandez <difernan>
Component: subscription-managerAssignee: William Poteat <wpoteat>
Status: CLOSED ERRATA QA Contact: John Sefler <jsefler>
Severity: low Docs Contact:
Priority: high    
Version: 7.4CC: bcourt, egolov, khowell, redakkan, rlandman, skallesh, wpoteat
Target Milestone: rcKeywords: FutureFeature, Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: subscription-manager-1.19.6-1.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-01 19:21:47 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:

Description Diego Fernandez 2017-02-22 18:33:06 UTC
I'm creating independent requests for RHEL 6 and RHEL 7

I'm in the CEE Analytics team and we often get requests about system locales. This data is important in order to know how to prioritize localization efforts. I've done some analysis in the past looking at SOS Reports[1], but this is a very limited data set and is likely to be a skewed representation of our real distributions. If we could have systems report back their locale into the consumer facts, we could get some interesting insight into usage, especially by combining it with the installed products.

[1] https://mojo.redhat.com/docs/DOC-1075747

Comment 5 Rehana 2017-05-09 09:18:58 UTC
Demonstrating that with older subscription-manager versions on RHEL73  the fact "system.default_locale" was not available 

[root@dhcp35-220 ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.21-1
subscription management rules: 5.15.1
subscription-manager: 1.17.15-1.el7
python-rhsm: 1.17.9-1.el7


[root@dhcp35-220 ~]# subscription-manager facts --list | grep system.default_locale

^^ no results found

With latest subscription-manager build for RHEL74 , the fact "system.default_locale" is available and is displaying the correct value

# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.21-1
subscription management rules: 5.15.1
subscription-manager: 1.19.12-1.el7
python-rhsm: 1.19.6-1.el7

# subscription-manager facts --list | grep system.default_locale
system.default_locale: en_US.UTF-8

Based on the above observations, Marking this bug as verified!!

Comment 6 Diego Fernandez 2017-05-15 17:37:08 UTC
Sweet! I already see some data in Candlepin:

SELECT f.element,
       count(DISTINCT f.cp_consumer_id)
FROM cp_consumer_facts f
WHERE mapkey = "system.default_locale"
GROUP BY f.element;

element     |count(DISTINCT f.cp_consumer_id) |
------------|---------------------------------|
en_US.UTF-8 |460                              |
en_GB.UTF-8 |5                                |
en_CA.UTF-8 |2                                |
Unknown     |2                                |
cs_CZ.UTF-8 |1                                |
en_DK.UTF-8 |1                                |
en_IN.UTF-8 |1                                |
es_CL.UTF-8 |1                                |
fr_FR.UTF-8 |1                                |
pt_BR.UTF-8 |1                                |
zh_TW.UTF-8 |1                                |

Comment 7 errata-xmlrpc 2017-08-01 19:21:47 UTC
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/RHBA-2017:2083