Closed grasmax closed 12 months ago
Problem: cpu_percent() and getloadavg() were called in a construktor of a model class and stored to a static member. Solution: the result of cpu_percent() and getloadavg() are stored in a member variable of an instance of the model class.
Summary
Description
If I call a python script like
a few times within in a putty session, it shows different values:
If cpu_percent() is called from a apache/django/mvt python script, than it returns the correct value only once. All further calls always return the same value. I need to restart the Apache service to get new values.