public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug runtime/10848] New: enforcement of memory limits
@ 2009-10-26 16:17 fche at redhat dot com
  2009-11-05 13:57 ` [Bug runtime/10848] " fche at redhat dot com
  2009-12-09 16:42 ` dsmith at redhat dot com
  0 siblings, 2 replies; 3+ messages in thread
From: fche at redhat dot com @ 2009-10-26 16:17 UTC (permalink / raw)
  To: systemtap

It would be useful for a sysadmin to assert that a stap module
(especially in unprivileged mode) not be allowed to consume more
than some give MB of memory.

This sort of thing could involve:

- checking the .ko file at -p4 or -p5 time for ELF stats about .text/.data/.bss
  sizes, and comparing them to limits
- perhaps teaching staprun to "create" free kernel memory (such as by creating
  a short-lived process that touches/consumes enough memory, then killing it
  just before the module_insert)
- extending the _stp_*alloc functions to prematurely reject requests if limits
  are about to be exceeded
- checking that every other use of kernel allocations go through _stp_alloc*
- checking that all kernel-side memory allocations use __GFP_NORETRY or such
  to preclude triggering OOM handling elsewhere

-- 
           Summary: enforcement of memory limits
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: runtime
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: fche at redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=10848

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug runtime/10848] enforcement of memory limits
  2009-10-26 16:17 [Bug runtime/10848] New: enforcement of memory limits fche at redhat dot com
@ 2009-11-05 13:57 ` fche at redhat dot com
  2009-12-09 16:42 ` dsmith at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: fche at redhat dot com @ 2009-11-05 13:57 UTC (permalink / raw)
  To: systemtap



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|                            |10907
              nThis|                            |


http://sourceware.org/bugzilla/show_bug.cgi?id=10848

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug runtime/10848] enforcement of memory limits
  2009-10-26 16:17 [Bug runtime/10848] New: enforcement of memory limits fche at redhat dot com
  2009-11-05 13:57 ` [Bug runtime/10848] " fche at redhat dot com
@ 2009-12-09 16:42 ` dsmith at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: dsmith at redhat dot com @ 2009-12-09 16:42 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From dsmith at redhat dot com  2009-12-09 16:42 -------
(In reply to comment #0)
> - checking that every other use of kernel allocations go through _stp_alloc*
> - checking that all kernel-side memory allocations use __GFP_NORETRY or such
>   to preclude triggering OOM handling elsewhere

Commit 965b658 makes sure all kernel-side memory allocations go through the
_stp_alloc* functions (except for uprobes).  The _stp_alloc* functions already
used __GFP_NOTRETRY everywhere.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|systemtap at sources dot    |dsmith at redhat dot com
                   |redhat dot com              |
             Status|NEW                         |ASSIGNED


http://sourceware.org/bugzilla/show_bug.cgi?id=10848

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-12-09 16:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-26 16:17 [Bug runtime/10848] New: enforcement of memory limits fche at redhat dot com
2009-11-05 13:57 ` [Bug runtime/10848] " fche at redhat dot com
2009-12-09 16:42 ` dsmith at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).