Commit ff94bbc2 by Bach Dániel

fix ram usage metric

parent c992fbfb
...@@ -164,8 +164,8 @@ class Client: ...@@ -164,8 +164,8 @@ class Client:
logger.info('New process: %s', process) logger.info('New process: %s', process)
self.processes[entry.pid] = process self.processes[entry.pid] = process
mem_perc = (process.get_memory_percent() mem_perc = (float(process.get_memory_info().rss)
/ 100 * args.memory_size) / (args.memory_size * 1024 ** 2) * 90)
Please register or sign in to reply
metrics.append('vm.%(name)s.memory.usage %(value)f ' metrics.append('vm.%(name)s.memory.usage %(value)f '
'%(time)d' % {'name': args.name, '%(time)d' % {'name': args.name,
'value': mem_perc, 'value': mem_perc,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment