hdfs_quota_admin_guide.html 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <head>
  4. <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <meta content="Apache Forrest" name="Generator">
  6. <meta name="Forrest-version" content="0.8">
  7. <meta name="Forrest-skin-name" content="pelt">
  8. <title>
  9. Hadoop DFS Name Space Quotas Administrator Guide
  10. </title>
  11. <link type="text/css" href="skin/basic.css" rel="stylesheet">
  12. <link media="screen" type="text/css" href="skin/screen.css" rel="stylesheet">
  13. <link media="print" type="text/css" href="skin/print.css" rel="stylesheet">
  14. <link type="text/css" href="skin/profile.css" rel="stylesheet">
  15. <script src="skin/getBlank.js" language="javascript" type="text/javascript"></script><script src="skin/getMenu.js" language="javascript" type="text/javascript"></script><script src="skin/fontsize.js" language="javascript" type="text/javascript"></script>
  16. <link rel="shortcut icon" href="images/favicon.ico">
  17. </head>
  18. <body onload="init()">
  19. <script type="text/javascript">ndeSetTextSize();</script>
  20. <div id="top">
  21. <!--+
  22. |breadtrail
  23. +-->
  24. <div class="breadtrail">
  25. <a href="http://www.apache.org/">Apache</a> &gt; <a href="http://hadoop.apache.org/">Hadoop</a> &gt; <a href="http://hadoop.apache.org/core/">Core</a><script src="skin/breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
  26. </div>
  27. <!--+
  28. |header
  29. +-->
  30. <div class="header">
  31. <!--+
  32. |start group logo
  33. +-->
  34. <div class="grouplogo">
  35. <a href="http://hadoop.apache.org/"><img class="logoImage" alt="Hadoop" src="images/hadoop-logo.jpg" title="Apache Hadoop"></a>
  36. </div>
  37. <!--+
  38. |end group logo
  39. +-->
  40. <!--+
  41. |start Project Logo
  42. +-->
  43. <div class="projectlogo">
  44. <a href="http://hadoop.apache.org/core/"><img class="logoImage" alt="Hadoop" src="images/core-logo.gif" title="Scalable Computing Platform"></a>
  45. </div>
  46. <!--+
  47. |end Project Logo
  48. +-->
  49. <!--+
  50. |start Search
  51. +-->
  52. <div class="searchbox">
  53. <form action="http://www.google.com/search" method="get" class="roundtopsmall">
  54. <input value="hadoop.apache.org" name="sitesearch" type="hidden"><input onFocus="getBlank (this, 'Search the site with google');" size="25" name="q" id="query" type="text" value="Search the site with google">&nbsp;
  55. <input name="Search" value="Search" type="submit">
  56. </form>
  57. </div>
  58. <!--+
  59. |end search
  60. +-->
  61. <!--+
  62. |start Tabs
  63. +-->
  64. <ul id="tabs">
  65. <li>
  66. <a class="unselected" href="http://hadoop.apache.org/core/">Project</a>
  67. </li>
  68. <li>
  69. <a class="unselected" href="http://wiki.apache.org/hadoop">Wiki</a>
  70. </li>
  71. <li class="current">
  72. <a class="selected" href="index.html">Hadoop 0.18 Documentation</a>
  73. </li>
  74. </ul>
  75. <!--+
  76. |end Tabs
  77. +-->
  78. </div>
  79. </div>
  80. <div id="main">
  81. <div id="publishedStrip">
  82. <!--+
  83. |start Subtabs
  84. +-->
  85. <div id="level2tabs"></div>
  86. <!--+
  87. |end Endtabs
  88. +-->
  89. <script type="text/javascript"><!--
  90. document.write("Last Published: " + document.lastModified);
  91. // --></script>
  92. </div>
  93. <!--+
  94. |breadtrail
  95. +-->
  96. <div class="breadtrail">
  97. &nbsp;
  98. </div>
  99. <!--+
  100. |start Menu, mainarea
  101. +-->
  102. <!--+
  103. |start Menu
  104. +-->
  105. <div id="menu">
  106. <div onclick="SwitchMenu('menu_selected_1.1', 'skin/')" id="menu_selected_1.1Title" class="menutitle" style="background-image: url('skin/images/chapter_open.gif');">Documentation</div>
  107. <div id="menu_selected_1.1" class="selectedmenuitemgroup" style="display: block;">
  108. <div class="menuitem">
  109. <a href="index.html">Overview</a>
  110. </div>
  111. <div class="menuitem">
  112. <a href="quickstart.html">Quickstart</a>
  113. </div>
  114. <div class="menuitem">
  115. <a href="cluster_setup.html">Cluster Setup</a>
  116. </div>
  117. <div class="menuitem">
  118. <a href="hdfs_design.html">HDFS Architecture</a>
  119. </div>
  120. <div class="menuitem">
  121. <a href="hdfs_user_guide.html">HDFS User Guide</a>
  122. </div>
  123. <div class="menuitem">
  124. <a href="hdfs_permissions_guide.html">HDFS Permissions Guide</a>
  125. </div>
  126. <div class="menupage">
  127. <div class="menupagetitle">HDFS Quotas Administrator Guide</div>
  128. </div>
  129. <div class="menuitem">
  130. <a href="hdfs_shell.html">FS Shell Guide</a>
  131. </div>
  132. <div class="menuitem">
  133. <a href="distcp.html">DistCp Guide</a>
  134. </div>
  135. <div class="menuitem">
  136. <a href="mapred_tutorial.html">Map-Reduce Tutorial</a>
  137. </div>
  138. <div class="menuitem">
  139. <a href="native_libraries.html">Native Hadoop Libraries</a>
  140. </div>
  141. <div class="menuitem">
  142. <a href="streaming.html">Streaming</a>
  143. </div>
  144. <div class="menuitem">
  145. <a href="hadoop_archives.html">Hadoop Archives</a>
  146. </div>
  147. <div class="menuitem">
  148. <a href="hod.html">Hadoop On Demand</a>
  149. </div>
  150. <div class="menuitem">
  151. <a href="api/index.html">API Docs</a>
  152. </div>
  153. <div class="menuitem">
  154. <a href="http://wiki.apache.org/hadoop/">Wiki</a>
  155. </div>
  156. <div class="menuitem">
  157. <a href="http://wiki.apache.org/hadoop/FAQ">FAQ</a>
  158. </div>
  159. <div class="menuitem">
  160. <a href="http://hadoop.apache.org/core/mailing_lists.html">Mailing Lists</a>
  161. </div>
  162. <div class="menuitem">
  163. <a href="releasenotes.html">Release Notes</a>
  164. </div>
  165. <div class="menuitem">
  166. <a href="changes.html">All Changes</a>
  167. </div>
  168. </div>
  169. <div id="credit"></div>
  170. <div id="roundbottom">
  171. <img style="display: none" class="corner" height="15" width="15" alt="" src="skin/images/rc-b-l-15-1body-2menu-3menu.png"></div>
  172. <!--+
  173. |alternative credits
  174. +-->
  175. <div id="credit2"></div>
  176. </div>
  177. <!--+
  178. |end Menu
  179. +-->
  180. <!--+
  181. |start content
  182. +-->
  183. <div id="content">
  184. <div title="Portable Document Format" class="pdflink">
  185. <a class="dida" href="hdfs_quota_admin_guide.pdf"><img alt="PDF -icon" src="skin/images/pdfdoc.gif" class="skin"><br>
  186. PDF</a>
  187. </div>
  188. <h1>
  189. Hadoop DFS Name Space Quotas Administrator Guide
  190. </h1>
  191. <p>
  192. HDFS allows the administrator to set quotas on individual directories.
  193. Newly created directories have no associated quota.
  194. The largest quota is Long.Max_Value. A quota of one forces a directory
  195. to remain empty.
  196. </p>
  197. <p>
  198. The directory quota is a hard limit on the number of names in the tree
  199. rooted at that directory. File/directory creations fault if the quota
  200. would be exceeded. Quotas stick to renamed directories; the rename
  201. operation faults if operation would result in a quota violation.
  202. The attempt to set a quota faults if the directory would be in violation
  203. of the new quota.
  204. </p>
  205. <p>
  206. Quotas are persistent with the fsimage. When starting, if the fsimage
  207. is immediately in violation of aquota (perhaps the fsimage was
  208. surreptitiously modified), startup operation fails with an error report.
  209. Setting/removing a quota creates a journal entry.
  210. </p>
  211. <p>
  212. The following new commands or new options are added to support quotas.
  213. The first two are administration commands.
  214. </p>
  215. <ul>
  216. <li>
  217. <strong><em>dfsadmin -setquota &lt;N&gt; &lt;directory&gt;...&lt;directory&gt;</em></strong>
  218. <br>
  219. Set the quota <em></em> for each directory. Best effort for each directory,
  220. with faults reported if <em>N</em> is not a positive long integer,
  221. the directory does not exist or it is a file, or the directory would
  222. immediately exceed the new quota.
  223. </li>
  224. <li>
  225. <strong><em>dfsadmin -clrquota &lt;directory&gt;...&lt;director&gt;</em></strong>
  226. <br>
  227. Remove any quota for each directory. Best effort for each directory,
  228. with faults reported if the directory does not exist or it is a file.
  229. It is not a fault if the directory has no quota.
  230. </li>
  231. <li>
  232. <strong><em>fs -count -q &lt;directory&gt;...&lt;directory&gt;</em></strong>
  233. <br>
  234. With the <em>-q</em> option, also report the quota value set for each
  235. directory, and the available quota remaining. If the directory does not have
  236. a quota set, the reported values are <em>none</em> and <em>inf</em>.
  237. </li>
  238. </ul>
  239. </div>
  240. <!--+
  241. |end content
  242. +-->
  243. <div class="clearboth">&nbsp;</div>
  244. </div>
  245. <div id="footer">
  246. <!--+
  247. |start bottomstrip
  248. +-->
  249. <div class="lastmodified">
  250. <script type="text/javascript"><!--
  251. document.write("Last Published: " + document.lastModified);
  252. // --></script>
  253. </div>
  254. <div class="copyright">
  255. Copyright &copy;
  256. 2007 <a href="http://www.apache.org/licenses/">The Apache Software Foundation.</a>
  257. </div>
  258. <!--+
  259. |end bottomstrip
  260. +-->
  261. </div>
  262. </body>
  263. </html>