You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@mesos.apache.org by "Paul Brett (JIRA)" <ji...@apache.org> on 2015/07/10 19:29:04 UTC
[jira] [Created] (MESOS-3029) Stout os::release returns unsortable
version
Paul Brett created MESOS-3029:
---------------------------------
Summary: Stout os::release returns unsortable version
Key: MESOS-3029
URL: https://issues.apache.org/jira/browse/MESOS-3029
Project: Mesos
Issue Type: Bug
Reporter: Paul Brett
Priority: Minor
When the Linux kernel version was incremented from 2.6.39 to 3.0.0 it was discovered that a few applications could not process kernel versions starting with anything but 2.x. For compatibility, Red Hat and others mapped kernel version 3.n to 2.6.n+40.
This introduces the interesting property that kernel 2.6.50 is later that kernel 3.9 but Version(2, 60, 50) is not greater that Version(3, 9, 0). Since we want to be able to order kernel versions, we need to undo this mapping.
The following function is proposed for use in linux/perf.cpp to address this issue:
Version canonicalLinuxRelease(const Version& v) {
if((v > Version(2, 6, 39)) && (v < Version(3, 0, 0))) {
return Version(3, v.patchVersion-40, 0);
}
return v;
}
We could either add this to stout/os.hpp or add a custom sort order to Version (which we might need later when we generalize it).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)