JDK-7165755 : OS Information much longer for linux than other platforms
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 7u6
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2012-05-02
  • Updated: 2015-06-04
  • Resolved: 2012-05-26
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7 JDK 8 Other
7u40Fixed 8Fixed hs23.2Fixed
Related Reports
Relates :  
When looking at the info from os::print_os_info() in 
src/os/linux/vm/os_linux.cpp:2024 (and other files for other platforms)
the length of the text is radically longer for linux than other platforms. 

This can make it hard for tool writers to get a summary that look good and similar for multiple platforms (sizing of gui fields, having to parse info in the tool code etc)

Lookin at the code, it's in some serious need of refactoring. It would be nice with a method to get a "brief" os info for these kinds of tools that looks similar on all platforms.

EVALUATION http://hg.openjdk.java.net/lambda/lambda/hotspot/rev/7432b9db36ff

EVALUATION http://hg.openjdk.java.net/hsx/hotspot-main/hotspot/rev/7432b9db36ff

EVALUATION http://hg.openjdk.java.net/hsx/hsx23.2/hotspot/rev/8a074526ffca

EVALUATION http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/7432b9db36ff

PUBLIC COMMENTS If there are a lot of distro specific "release" files then potentially the info could be much longer. But beyond that I think the main difference, compared to Solaris, is printing /proc/meminfo - not sure why that is necessary. I expect that everything that gets printed was added at some point because someone needed it to assist with some specific problem.