Skip to content
This repository was archived by the owner on Jan 9, 2020. It is now read-only.
This repository was archived by the owner on Jan 9, 2020. It is now read-only.

Incorrect GiB -> MB units conversion #467

@ash211

Description

@ash211

If I set spark.driver.memory=6G then the created pod has these resources set on it:

resources:
  limits:
    memory: 6758M
  requests:
    cpu: "2"
    memory: 6144M

That might look correct at first, but a Java Xmx of 6G is in units GiB (per SO) and 6144M is in units MB (per k8s docs). The conversion doesn't match!

The generated request should be 6144Mi not 6144M

Because 6144M is only 5859.375MiB, this means that my pod's containers are under-sized and frequently OOM with this message: Killed process 29970 (java) total-vm:12593416kB, anon-rss:6582248kB, file-rss:0kB, shmem-rss:0kB

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions