Join GitHub today
productname grain missing on Solaris #47690
Description of Issue/Question
The 'productname' grain is missing on Solaris sparc minions. The data is instead put in 'product'.
Additionally, in some cases the product grain is not valid.
This is due to the regexes that are being used to scrape the data out of the prtdiag/prtconf/virtinfo output. The regexes use '\s' to capture whitespace, which includes newlines. This causes prtconf data to be parsed incorrectly.
For example, on a Solaris 11 zone on a S7 server:
prtconf data is returning:
The regex in the grains core.py file is then matching the "Memory size" line (it is expecting the model to be after the sunv4 as in prtdiag output -- which in a non-global zone does not return data).
Solaris 11 running 2017.7
Steps to Reproduce Issue
Install minion and get 'product' grain