Project

General

Profile

Actions

Bug #11583

closed

[crunch-run] Fix excessive memory use

Added by Tom Clegg almost 7 years ago. Updated almost 6 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
-
Category:
-
Target version:
Story points:
-
Release:
Release relationship:
Auto

Description

The crunch-run test suite seems to have started leaking memory in #9132. RSS climbs steadily with each test case. Leaking memory on each docker invocation wouldn't be a big problem in real life, since each crunch-run process only invokes one container. However, this could be a clue about the second leak.

Even in versions before #9132, TestWriteLogsLarge consumes multiple gigabytes of memory. The test loop itself doesn't seem to allocate a significant amount of memory. If the problem is that crunch-run tries to buffer everything up to the next newline in memory regardless of length, an errant job could (e.g., with a progress bar) cause crunch-run to allocate an arbitrary amount of memory, too.

    for i := 0; i < 2000000; i++ {
        cr.CrunchLog.Printf("Hello %d", i)
    }

Related issues

Related to Arvados - Bug #12447: crunch-run memory leakResolvedPeter Amstutz10/13/2017Actions
Related to Arvados - Bug #13100: [crunch-run] Replace custom manifest-writing code with collectionFSResolvedTom Clegg03/15/2018Actions
Actions #1

Updated by Tom Clegg almost 7 years ago

  • Description updated (diff)
Actions #2

Updated by Tom Clegg almost 7 years ago

Adding \n to the TestWriteLogsLarge Printf format doesn't seem to make any difference, suggesting this isn't just about long lines.

Actions #3

Updated by Tom Morris over 6 years ago

  • Target version set to Arvados Future Sprints
Actions #4

Updated by Tom Clegg about 6 years ago

  • Related to Bug #13100: [crunch-run] Replace custom manifest-writing code with collectionFS added
Actions #5

Updated by Tom Clegg about 6 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 100
Actions #6

Updated by Tom Morris about 6 years ago

  • Target version changed from Arvados Future Sprints to 2018-04-25 Sprint
Actions #7

Updated by Tom Morris almost 6 years ago

  • Release set to 13
Actions

Also available in: Atom PDF