Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

yarn + usercache + size of local folder increasing in spite yarn.nodemanager.localizer.cache.target-size-mb configured

Solved Go to solution

yarn + usercache + size of local folder increasing in spite yarn.nodemanager.localizer.cache.target-size-mb configured

hi all

we noticed about the following problem:

under the folder ( DATANODE machine )

/var/hadoop/yarn/local/usercache

size is 140G

in spite we set the following configuration that should avoid this case

yarn.nodemanager.localizer.cache.target-size-mb = 10240
yarn.nodemanager.localizer.cache.cleanup.interval-ms = 300000

this configuration from my understanding should delete the the folder/files in case size is more then 10G

so how it can be current size is 140G?

reference:

https://community.hortonworks.com/questions/201820/yarn-usercache-folder-became-with-huge-size.html

  • yarn.nodemanager.localizer.cache.target-size-mb: This decides the maximum disk space to be used for localizing resources. (At present there is no individual limit for PRIVATE / APPLICATION / PUBLIC cache. YARN-882). Once the total disk size of the cache exceeds this then Deletion service will try to remove files which are not used by any running containers. At present there is no limit (quota) for user cache / public cache / private cache. This limit is applicable to all the disks as a total and is not based on per disk basis.
  • yarn.nodemanager.localizer.cache.cleanup.interval-ms: After this interval resource localization service will try to delete the unused resources if total cache size exceeds the configured max-size. Unused resources are those resources which are not referenced by any running container. Every time container requests a resource, container is added into the resources’ reference list. It will remain there until container finishes avoiding accidental deletion of this resource. As a part of container resource cleanup (when container finishes) container will be removed from resources’ reference list. That is why when reference count drops to zero it is an ideal candidate for deletion. The resources will be deleted on LRU basis until current cache size drops below target size.
Michael-Bronson
1 ACCEPTED SOLUTION

Accepted Solutions

Re: yarn + usercache + size of local folder increasing in spite yarn.nodemanager.localizer.cache.target-size-mb configured

Expert Contributor

@Michael Bronson

As for automatic clean up not getting triggered, well it may be due to (or at-least related to) this unresolved bug reported on Yarn.
https://issues.apache.org/jira/browse/YARN-4540

1 REPLY 1

Re: yarn + usercache + size of local folder increasing in spite yarn.nodemanager.localizer.cache.target-size-mb configured

Expert Contributor

@Michael Bronson

As for automatic clean up not getting triggered, well it may be due to (or at-least related to) this unresolved bug reported on Yarn.
https://issues.apache.org/jira/browse/YARN-4540

Don't have an account?
Coming from Hortonworks? Activate your account here