[SERVER-31568] Fix Windows version detection Created: 13/Oct/17  Updated: 30/Oct/23  Resolved: 02/Nov/17

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 3.6.0-rc3

Type: Bug Priority: Major - P3
Reporter: Mark Benvenuto Assignee: Mark Benvenuto
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-19158 hostInfo for Windows has incorrect ve... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Platforms 2017-11-13
Participants:

 Description   

Currently due to behavior changes GetVersionEx unless mongod/mongos is manifested to target OS versions after Windows 8, the GetVersionEx function always returns Windows 8. This makes detecting the customer's OS from logs difficult since the logs will get wrong information.

References:
https://msdn.microsoft.com/en-us/library/windows/desktop/dn481241(v=vs.85).aspx
https://stackoverflow.com/questions/27246562/how-to-get-the-os-version-in-win8-1-as-getversion-getversionex-are-deprecated



 Comments   
Comment by Githook User [ 02/Nov/17 ]

Author:

{'name': 'Mark Benvenuto', 'username': 'markbenvenuto', 'email': 'mark.benvenuto@mongodb.com'}

Message: SERVER-31568 Fix Windows Version detection
Branch: master
https://github.com/mongodb/mongo/commit/669935d5a795ec33e1a0d4600a94287fd60ff2b0

Generated at Thu Feb 08 04:27:29 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.