Support Questions

Find answers, ask questions, and share your expertise

Get HDFS quotas via API call




Does anyone know if it's possible to get HDFS quota info via a Cloudera API call? I can get the usernames, size and raw sizes etc from https://host.domain:7183/api/v19/clusters/my_cluster/services/hdfs/reports/hdfsUsageReport  but I can't find any reference to the quotas set in HDFS in the API documentation (unless I'm completely missing it).


EDIT: Trying to get this data in a JSON format.


EDIT: Also looking at the timeseries/tsquery statements, but really just randomly trying things...




New Contributor



Did you find solution for the HDFS quota using CM API?




I have not found a solution. I don't think that you can get that quota info out of CDH (even though it displays it).

Expert Contributor

@getschwifty  Till what i know is Quotas are managed by a set of commands available only to the administrator[like dfsadmin]. Quotas are not exposed via rest api call.


But you can achieve it by other way via "lsr |count -q".

Please check below link for details -


Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.