[arvados] updated: 2.7.0-6016-gcfb1970c0c

git repository hosting git at public.arvados.org
Fri Feb 23 19:42:31 UTC 2024


Summary of changes:
 .../crunchstat_summary/summarizer.py               | 50 ++++++++++++++--------
 1 file changed, 33 insertions(+), 17 deletions(-)

       via  cfb1970c0ca562c7adddc32eb7b1ff85e410289e (commit)
      from  282c677a7f39fe4186085c2705472bff9658a012 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit cfb1970c0ca562c7adddc32eb7b1ff85e410289e
Author: Peter Amstutz <peter.amstutz at curii.com>
Date:   Fri Feb 23 14:22:25 2024 -0500

    19744: Adjust some of the recommendations
    
    Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>

diff --git a/tools/crunchstat-summary/crunchstat_summary/summarizer.py b/tools/crunchstat-summary/crunchstat_summary/summarizer.py
index 03ce9d6c26..e03e6bb461 100644
--- a/tools/crunchstat-summary/crunchstat_summary/summarizer.py
+++ b/tools/crunchstat-summary/crunchstat_summary/summarizer.py
@@ -492,39 +492,55 @@ class Summarizer(object):
                 recommend_mib)
 
     def _recommend_keep_cache(self, recommendformat):
-        """Recommend increasing keep cache if utilization < 80%"""
+        """Recommend increasing keep cache if utilization < 50%.
+
+        This means the amount of data returned to the program is less
+        than 50% of the amount of data actually downloaded by
+        arv-mount.
+        """
+
         constraint_key = self._map_runtime_constraint('keep_cache_ram')
         if self.job_tot['net:keep0']['rx'] == 0:
             return
         utilization = (float(self.job_tot['blkio:0:0']['read']) /
                        float(self.job_tot['net:keep0']['rx']))
         # FIXME: the default on this get won't work correctly
-        asked_cache = self.existing_constraints.get(constraint_key, 256) * self._runtime_constraint_mem_unit()
+        asked_cache = self.existing_constraints.get('keep_cache_ram') or self.existing_constraints.get('keep_cache_disk')
 
-        if utilization < 0.8:
+        if utilization < 0.5:
             yield recommendformat(
                 '{} Keep cache utilization was {:.2f}% -- '
-                'try doubling runtime_constraints to "{}":{} (or more)'
+                'try increasing keep_cache to {} MB'
             ).format(
                 self.label,
                 utilization * 100.0,
-                constraint_key,
-                math.ceil(asked_cache * 2 / self._runtime_constraint_mem_unit()))
+                math.ceil((asked_cache * 2) / (1024*1024)))
 
 
     def _recommend_temp_disk(self, recommendformat):
-        """Recommend decreasing temp disk if utilization < 50%"""
-        total = float(self.job_tot['statfs']['total'])
-        utilization = (float(self.job_tot['statfs']['used']) / total) if total > 0 else 0.0
+        """Recommend decreasing temp disk if utilization < 50%.
+
+        This recommendation is disabled for the time being.  It uses
+        the total disk on the node and not the amount of disk
+        requested, so it triggers a false positive basically every
+        time.  To get the amount of disk requested we need to fish it
+        out of the mounts, which is extra work I don't want do right
+        now.
+        """
 
-        if utilization < 50.8 and total > 0:
-            yield recommendformat(
-                '{} max temp disk utilization was {:.0f}% of {:.0f} MiB -- '
-                'consider reducing "tmpdirMin" and/or "outdirMin"'
-            ).format(
-                self.label,
-                utilization * 100.0,
-                total / MB)
+        return []
+
+        # total = float(self.job_tot['statfs']['total'])
+        # utilization = (float(self.job_tot['statfs']['used']) / total) if total > 0 else 0.0
+
+        # if utilization < 50.0 and total > 0:
+        #     yield recommendformat(
+        #         '{} max temp disk utilization was {:.0f}% of {:.0f} MiB -- '
+        #         'consider reducing "tmpdirMin" and/or "outdirMin"'
+        #     ).format(
+        #         self.label,
+        #         utilization * 100.0,
+        #         total / MB)
 
 
     def _format(self, val):

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list