[ 
https://issues.apache.org/jira/browse/IMPALA-7941?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16750196#comment-16750196
 ] 

ASF subversion and git services commented on IMPALA-7941:
---------------------------------------------------------

Commit d1f2c1a2269604efb9a498c0a0137bb4ea4eff07 in impala's branch 
refs/heads/master from Tim Armstrong
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=d1f2c1a ]

IMPALA-7941: part 1: detect cgroups memory limit

This adds the logic to detect the cgroups memory limit,
but does not use it to set the process memory limit yet.
The information obtained is logged at startup and accessible
through the Web UI.

The patch boils down to reading from the appropriate
places in the filesystem. The main complication is that paths need to be
translated to point to the right cgroup node inside the container.

This deletes some useless cgroup logic from ProcessStateInfo that
printed whatever happened to be the last cgroup in a file.

Testing:
Added a unit test to check that the code could parse the cgroups
hierarchy ok and return a positive value.

Tested on CentOS6 and CentOS7.

Change-Id: Ic0f5ed0e94511361bf5605822c0874c16c45ffa9
Reviewed-on: http://gerrit.cloudera.org:8080/12120
Reviewed-by: Impala Public Jenkins <[email protected]>
Tested-by: Impala Public Jenkins <[email protected]>


> Determine process memory limit from cgroups limit, if set
> ---------------------------------------------------------
>
>                 Key: IMPALA-7941
>                 URL: https://issues.apache.org/jira/browse/IMPALA-7941
>             Project: IMPALA
>          Issue Type: New Feature
>          Components: Backend
>            Reporter: Tim Armstrong
>            Assignee: Tim Armstrong
>            Priority: Major
>              Labels: admission-control, resource-management
>         Attachments: allocmem.cc
>
>
> We currently take the hardcoded config value, or the system physical memory 
> if that is not set. We could be smarter when running in a container by 
> sniffing out the cgroups setting.
> Java did something along this lines: 
> https://www.opsian.com/blog/java-on-docker/



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to