镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Node >= 12.5 OSX memory spike #28558

Description

@chaffeqa
  • 12.5.0:
  • Darwin Quinns-MacBook-Pro-2.local 18.6.0 Darwin Kernel Version 18.6.0: Thu Apr 25 23:16:27 PDT 2019; root:xnu-4903.261.4~2/RELEASE_X86_64 x86_64:

When running a after.js app (React + babel + webpack) on OSX, can reproduce that switching from 12.4 to 12.5/12.6 that the node process spikes on initial startup in virtual memory and in some cases continues to rise until the process crashes. 12.4 stays consistent.

In looking at bugs + changes, Im suspecting v8 snapshot on osx, but have no way to determine (open to suggestions on debugging).

Including an OSX sample of mem usage on the process

node-12.6-mem-bug.txt

Activity

  1. Trott commented on Jul 5, 2019

    @Trott
    Member

    @nodejs/platform-macos @joyeecheung

  2. joyeecheung commented on Jul 5, 2019

    @joyeecheung
    Member

    Can you capture a core dump and use https://github.com/nodejs/llnode/ to try listing all types of objects with v8 findjsobjects? If the instance becomes too big using ulimit -v to limit the virtual memory allowed should be helpful.

  3. joyeecheung commented on Jul 5, 2019

    @joyeecheung
    Member

    Alternatively, you can try building Node.js with --without-node-snapshot in the configure option, and use that to see if the issue reproduces with a no-snapshot build. The guide on building Node.js is https://github.com/nodejs/node/blob/master/BUILDING.md#building-nodejs-on-supported-platforms

    (which reminds me it should be possible to make this a run-time option)

  4. chaffeqa commented on Aug 5, 2019

    @chaffeqa
    Author

    Sorry I have been slammed with work and havent had time to poke around :(

    I did notice though in a quick glance at 12.7 updates: #27508

    Going to try 12.7 and see if that magically fixes my error, will let you know!

  5. mikehardy commented on Aug 9, 2019

    @mikehardy

    12.7 does not seem to fix it but I believe from #29001 that the PR to update V8 #28918 appears to fix it. That one is in motion at this moment (with comments and CI builds happening) so perhaps 12.9 will be a release with improved behavior. This may be a duplicate of #29001 though

  6. added
    memoryIssues and PRs related to Node.js memory management or memory footprint.
    on Jun 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    memoryIssues and PRs related to Node.js memory management or memory footprint.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions