Announcement

Collapse
No announcement yet.

Running script whenever user hits resources limits

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Running script whenever user hits resources limits

    I was wondering if there would be a way to run a script whenever a user hits the resources limits

  • #2
    Hello!

    I was wondering if theres anyway i can run a script or command line like top -u Username > report.txt whenever a user hits the resources limits?

    Comment


    • #3
      Hi,

      There is no way to trigger anything when user hits a limit. You can run a cronjob to trace if there are any faults with lveinfo --by-faults=any then run script/command however it will not be the same as you want as it will be post factum , ~1 minute after an issue happened.

      Comment


      • #4
        My primary objective is to trace what processes are making the users hit the resources limit. Ive notice that lve-stats2 now has the option to list the processes. I was wondering if this will give me access to the list of processes that were running at the time the user hit the limit.

        Comment


        • #5
          Actually yes, you are right. The snapshots were implemented to lvestats2 specially for this case, to get a list of processes when users hits limits.

          Comment


          • #6
            Ive check the lve-stats2 is it not possible to had a more complex process list? All i get is a pid and the process like "php" or "http", was wondering if theres a way of us getting the full script running like top displays when you do a top -c.

            Comment


            • #7
              Nice suggestion, let me pass this to our developers, we will see if possible to do it.

              Comment

              Working...
              X