hdfs_user_guide.html 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734
  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 User 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="menupage">
  121. <div class="menupagetitle">HDFS User Guide</div>
  122. </div>
  123. <div class="menuitem">
  124. <a href="hdfs_permissions_guide.html">HDFS Permissions Guide</a>
  125. </div>
  126. <div class="menuitem">
  127. <a href="hdfs_shell.html">FS Shell Guide</a>
  128. </div>
  129. <div class="menuitem">
  130. <a href="mapred_tutorial.html">Map-Reduce Tutorial</a>
  131. </div>
  132. <div class="menuitem">
  133. <a href="native_libraries.html">Native Hadoop Libraries</a>
  134. </div>
  135. <div class="menuitem">
  136. <a href="streaming.html">Streaming</a>
  137. </div>
  138. <div class="menuitem">
  139. <a href="hod.html">Hadoop On Demand</a>
  140. </div>
  141. <div class="menuitem">
  142. <a href="api/index.html">API Docs</a>
  143. </div>
  144. <div class="menuitem">
  145. <a href="http://wiki.apache.org/hadoop/">Wiki</a>
  146. </div>
  147. <div class="menuitem">
  148. <a href="http://wiki.apache.org/hadoop/FAQ">FAQ</a>
  149. </div>
  150. <div class="menuitem">
  151. <a href="http://hadoop.apache.org/core/mailing_lists.html">Mailing Lists</a>
  152. </div>
  153. <div class="menuitem">
  154. <a href="changes.html">Release Notes</a>
  155. </div>
  156. </div>
  157. <div id="credit"></div>
  158. <div id="roundbottom">
  159. <img style="display: none" class="corner" height="15" width="15" alt="" src="skin/images/rc-b-l-15-1body-2menu-3menu.png"></div>
  160. <!--+
  161. |alternative credits
  162. +-->
  163. <div id="credit2"></div>
  164. </div>
  165. <!--+
  166. |end Menu
  167. +-->
  168. <!--+
  169. |start content
  170. +-->
  171. <div id="content">
  172. <div title="Portable Document Format" class="pdflink">
  173. <a class="dida" href="hdfs_user_guide.pdf"><img alt="PDF -icon" src="skin/images/pdfdoc.gif" class="skin"><br>
  174. PDF</a>
  175. </div>
  176. <h1>
  177. Hadoop DFS User Guide
  178. </h1>
  179. <div id="minitoc-area">
  180. <ul class="minitoc">
  181. <li>
  182. <a href="#Purpose">Purpose</a>
  183. </li>
  184. <li>
  185. <a href="#Overview"> Overview </a>
  186. </li>
  187. <li>
  188. <a href="#Pre-requisites"> Pre-requisites </a>
  189. </li>
  190. <li>
  191. <a href="#Web+Interface"> Web Interface </a>
  192. </li>
  193. <li>
  194. <a href="#Shell+Commands">Shell Commands</a>
  195. <ul class="minitoc">
  196. <li>
  197. <a href="#DFSAdmin+Command"> DFSAdmin Command </a>
  198. </li>
  199. </ul>
  200. </li>
  201. <li>
  202. <a href="#Secondary+Namenode"> Secondary Namenode </a>
  203. </li>
  204. <li>
  205. <a href="#Rebalancer"> Rebalancer </a>
  206. </li>
  207. <li>
  208. <a href="#Rack+Awareness"> Rack Awareness </a>
  209. </li>
  210. <li>
  211. <a href="#Safemode"> Safemode </a>
  212. </li>
  213. <li>
  214. <a href="#Fsck"> Fsck </a>
  215. </li>
  216. <li>
  217. <a href="#Upgrade+and+Rollback"> Upgrade and Rollback </a>
  218. </li>
  219. <li>
  220. <a href="#File+Permissions+and+Security"> File Permissions and Security </a>
  221. </li>
  222. <li>
  223. <a href="#Scalability"> Scalability </a>
  224. </li>
  225. <li>
  226. <a href="#Related+Documentation"> Related Documentation </a>
  227. </li>
  228. </ul>
  229. </div>
  230. <a name="N1000D"></a><a name="Purpose"></a>
  231. <h2 class="h3">Purpose</h2>
  232. <div class="section">
  233. <p>
  234. This document aims to be the starting point for users working with
  235. Hadoop Distributed File System (HDFS) either as a part of a
  236. <a href="http://hadoop.apache.org/">Hadoop</a>
  237. cluster or as a stand-alone general purpose distributed file system.
  238. While HDFS is designed to "just-work" in many environments, a working
  239. knowledge of HDFS helps greatly with configuration improvements and
  240. diagnostics on a specific cluster.
  241. </p>
  242. </div>
  243. <a name="N1001B"></a><a name="Overview"></a>
  244. <h2 class="h3"> Overview </h2>
  245. <div class="section">
  246. <p>
  247. HDFS is the primary distributed storage used by Hadoop applications. A
  248. HDFS cluster primarily consists of a <em>NameNode</em> that manages the
  249. filesystem metadata and Datanodes that store the actual data. The
  250. architecture of HDFS is described in detail
  251. <a href="hdfs_design.html">here</a>. This user guide primarily deals with
  252. interaction of users and administrators with HDFS clusters.
  253. The <a href="images/hdfsarchitecture.gif">diagram</a> from
  254. <a href="hdfs_design.html">HDFS architecture</a> depicts
  255. basic interactions among Namenode, Datanodes, and the clients. Eseentially,
  256. clients contact Namenode for file metadata or file modifications and perform
  257. actual file I/O directly with the datanodes.
  258. </p>
  259. <p>
  260. The following are some of the salient features that could be of
  261. interest to many users. The terms in <em>italics</em>
  262. are described in later sections.
  263. </p>
  264. <ul>
  265. <li>
  266. Hadoop, including HDFS, is well suited for distributed storage
  267. and distributed processing using commodity hardware. It is fault
  268. tolerant, scalable, and extremely simple to expand.
  269. <a href="mapred_tutorial.html">Map-Reduce</a>,
  270. well known for its simplicity and applicability for large set of
  271. distributed applications, is an integral part of Hadoop.
  272. </li>
  273. <li>
  274. HDFS is highly configurable with a default configuration well
  275. suited for many installations. Most of the time, configuration
  276. needs to be tuned only for very large clusters.
  277. </li>
  278. <li>
  279. It is written in Java and is supported on all major platforms.
  280. </li>
  281. <li>
  282. Supports <em>shell like commands</em> to interact with HDFS directly.
  283. </li>
  284. <li>
  285. Namenode and Datanodes have built in web servers that makes it
  286. easy to check current status of the cluster.
  287. </li>
  288. <li>
  289. New features and improvements are regularly implemented in HDFS.
  290. The following is a subset of useful features in HDFS:
  291. <ul>
  292. <li>
  293. <em>File permissions and authentication.</em>
  294. </li>
  295. <li>
  296. <em>Rack awareness</em> : to take a node's physical location into
  297. account while scheduling tasks and allocating storage.
  298. </li>
  299. <li>
  300. <em>Safemode</em> : an administrative mode for maintanance.
  301. </li>
  302. <li>
  303. <em>fsck</em> : an utility to diagnose health of the filesystem, to
  304. find missing files or blocks.
  305. </li>
  306. <li>
  307. <em>Rebalancer</em> : tool to balance the cluster when the data is
  308. unevenly distributed among datanodes.
  309. </li>
  310. <li>
  311. <em>Upgrade and Rollback</em> : after a software upgrade,
  312. it is possible to
  313. rollback to HDFS' state before the upgrade in case of unexpected
  314. problems.
  315. </li>
  316. <li>
  317. <em>Secondary Namenode</em> : helps keep the size of file
  318. containing log of HDFS modification with in certain limit at
  319. the Namenode.
  320. </li>
  321. </ul>
  322. </li>
  323. </ul>
  324. </div>
  325. <a name="N10083"></a><a name="Pre-requisites"></a>
  326. <h2 class="h3"> Pre-requisites </h2>
  327. <div class="section">
  328. <p>
  329. The following documents describe installation and set up of a
  330. Hadoop cluster :
  331. </p>
  332. <ul>
  333. <li>
  334. <a href="quickstart.html">Hadoop Quickstart</a>
  335. for first-time users.
  336. </li>
  337. <li>
  338. <a href="cluster_setup.html">Hadoop Cluster Setup</a>
  339. for large, distributed clusters.
  340. </li>
  341. </ul>
  342. <p>
  343. The rest of document assumes the user is able to set up and run a
  344. HDFS with at least one Datanode. For the purpose of this document,
  345. both Namenode and Datanode could be running on the same physical
  346. machine.
  347. </p>
  348. </div>
  349. <a name="N100A1"></a><a name="Web+Interface"></a>
  350. <h2 class="h3"> Web Interface </h2>
  351. <div class="section">
  352. <p>
  353. Namenode and Datanode each run an internal web server in order to
  354. display basic information about the current status of the cluster.
  355. With the default configuration, namenode front page is at
  356. <span class="codefrag">http://namenode:50070/</span> .
  357. It lists the datanodes in the cluster and basic stats of the
  358. cluster. The web interface can also be used to browse the file
  359. system (using "Browse the file system" link on the Namenode front
  360. page).
  361. </p>
  362. </div>
  363. <a name="N100AE"></a><a name="Shell+Commands"></a>
  364. <h2 class="h3">Shell Commands</h2>
  365. <div class="section">
  366. <p>
  367. Hadoop includes various "shell-like" commands that directly
  368. interact with HDFS and other file systems that Hadoop supports.
  369. The command
  370. <span class="codefrag">bin/hadoop fs -help</span>
  371. lists the commands supported by Hadoop
  372. shell. Further,
  373. <span class="codefrag">bin/hadoop fs -help command</span>
  374. displays more detailed help on a command. The commands support
  375. most of the normal filesystem operations like copying files,
  376. changing file permissions, etc. It also supports a few HDFS
  377. specific operations like changing replication of files.
  378. </p>
  379. <a name="N100BD"></a><a name="DFSAdmin+Command"></a>
  380. <h3 class="h4"> DFSAdmin Command </h3>
  381. <p>
  382. <span class="codefrag">'bin/hadoop dfsadmin'</span>
  383. command supports a few HDFS administration related operations.
  384. <span class="codefrag">bin/hadoop dfsadmin -help</span>
  385. lists all the commands currently supported. For e.g.:
  386. </p>
  387. <ul>
  388. <li>
  389. <span class="codefrag">-report</span>
  390. : reports basic stats of HDFS. Some of this information is
  391. also available on the Namenode front page.
  392. </li>
  393. <li>
  394. <span class="codefrag">-safemode</span>
  395. : though usually not required, an administrator can manually enter
  396. or leave <em>safemode</em>.
  397. </li>
  398. <li>
  399. <span class="codefrag">-finalizeUpgrade</span>
  400. : removes previous backup of the cluster made during last upgrade.
  401. </li>
  402. </ul>
  403. </div>
  404. <a name="N100E6"></a><a name="Secondary+Namenode"></a>
  405. <h2 class="h3"> Secondary Namenode </h2>
  406. <div class="section">
  407. <p>
  408. Namenode stores modifications to the filesystem as a log
  409. appended to a native filesystem file (<span class="codefrag">edits</span>).
  410. When a Namenode starts up, it reads HDFS state from an image
  411. file (<span class="codefrag">fsimage</span>) and then applies <em>edits</em> from
  412. edits log file. It then writes new HDFS state to (<span class="codefrag">fsimage</span>)
  413. and starts normal
  414. operation with an empty edits file. Since namenode merges
  415. <span class="codefrag">fsimage</span> and <span class="codefrag">edits</span> files only during start up,
  416. edits file could get very large over time on a large cluster.
  417. Another side effect of larger edits file is that next
  418. restart of Namenade takes longer.
  419. </p>
  420. <p>
  421. The secondary namenode merges fsimage and edits log periodically
  422. and keeps edits log size with in a limit. It is usually run on a
  423. different machine than the primary Namenode since its memory requirements
  424. are on the same order as the primary namemode. The secondary
  425. namenode is started by <span class="codefrag">bin/start-dfs.sh</span> on the nodes
  426. specified in <span class="codefrag">conf/masters</span> file.
  427. </p>
  428. </div>
  429. <a name="N1010B"></a><a name="Rebalancer"></a>
  430. <h2 class="h3"> Rebalancer </h2>
  431. <div class="section">
  432. <p>
  433. HDFS data might not always be be placed uniformly across the
  434. datanode. One common reason is addition of new datanodes to an
  435. existing cluster. While placing new <em>blocks</em> (data for a file is
  436. stored as a series of blocks), Namenode considers various
  437. parameters before choosing the datanodes to receive these blocks.
  438. Some of the considerations are :
  439. </p>
  440. <ul>
  441. <li>
  442. Policy to keep one of the replicas of a block on the same node
  443. as the node that is writing the block.
  444. </li>
  445. <li>
  446. Need to spread different replicas of a block across the racks so
  447. that cluster can survive loss of whole rack.
  448. </li>
  449. <li>
  450. One of the replicas is usually placed on the same rack as the
  451. node writing to the file so that cross-rack network I/O is
  452. reduced.
  453. </li>
  454. <li>
  455. Spread HDFS data uniformly across the datanodes in the cluster.
  456. </li>
  457. </ul>
  458. <p>
  459. Due to multiple competing considerations, data might not be
  460. uniformly placed across the datanodes.
  461. HDFS provides a tool for administrators that analyzes block
  462. placement and relanaces data across the datnodes. A brief
  463. adminstrator's guide for rebalancer as a
  464. <a href="http://issues.apache.org/jira/secure/attachment/12368261/RebalanceDesign6.pdf">PDF</a>
  465. is attached to
  466. <a href="http://issues.apache.org/jira/browse/HADOOP-1652">HADOOP-1652</a>.
  467. </p>
  468. </div>
  469. <a name="N10132"></a><a name="Rack+Awareness"></a>
  470. <h2 class="h3"> Rack Awareness </h2>
  471. <div class="section">
  472. <p>
  473. Typically large Hadoop clusters are arranged in <em>racks</em> and
  474. network traffic between different nodes with in the same rack is
  475. much more desirable than network traffic across the racks. In
  476. addition Namenode tries to place replicas of block on
  477. multiple racks for improved fault tolerance. Hadoop lets the
  478. cluster administrators decide which <em>rack</em> a node belongs to
  479. through configuration variable <span class="codefrag">dfs.network.script</span>. When this
  480. script is configured, each node runs the script to determine its
  481. <em>rackid</em>. A default installation assumes all the nodes belong to
  482. the same rack. This feature and configuration is further described
  483. in <a href="http://issues.apache.org/jira/secure/attachment/12345251/Rack_aware_HDFS_proposal.pdf">PDF</a>
  484. attached to
  485. <a href="http://issues.apache.org/jira/browse/HADOOP-692">HADOOP-692</a>.
  486. </p>
  487. </div>
  488. <a name="N10150"></a><a name="Safemode"></a>
  489. <h2 class="h3"> Safemode </h2>
  490. <div class="section">
  491. <p>
  492. During start up Namenode loads the filesystem state from
  493. <em>fsimage</em> and <em>edits</em> log file. It then waits for datanodes
  494. to report their blocks so that it does not prematurely start
  495. replicating the blocks though enough replicas already exist in the
  496. cluster. During this time Namenode stays in <em>safemode</em>. A
  497. <em>Safemode</em>
  498. for Namenode is essentially a read-only mode for the HDFS cluster,
  499. where it does not allow any modifications to filesystem or blocks.
  500. Normally Namenode gets out of safemode automatically at
  501. the beginning. If required, HDFS could be placed in safemode explicitly
  502. using <span class="codefrag">'bin/hadoop dfsadmin -safemode'</span> command. Namenode front
  503. page shows whether safemode is on or off. A more detailed
  504. description and configuration is maintained as JavaDoc for
  505. <a href="http://hadoop.apache.org/core/docs/current/api/org/apache/hadoop/dfs/NameNode.html#setSafeMode(org.apache.hadoop.dfs.FSConstants.SafeModeAction)"><span class="codefrag">setSafeMode()</span></a>.
  506. </p>
  507. </div>
  508. <a name="N1016E"></a><a name="Fsck"></a>
  509. <h2 class="h3"> Fsck </h2>
  510. <div class="section">
  511. <p>
  512. HDFS supports <span class="codefrag">fsck</span> command to check for various
  513. inconsistencies.
  514. It it is designed for reporting problems with various
  515. files, for e.g. missing blocks for a file or under replicated
  516. blocks. Unlike a traditional fsck utility for native filesystems,
  517. this command does not correct the errors it detects. Normally Namenode
  518. automatically corrects most of the recoverable failures. By default
  519. fsck ignores open files but provides an option to select during reporting.
  520. HDFS' fsck is not a
  521. Hadoop shell command. It can be run as '<span class="codefrag">bin/hadoop fsck</span>'.
  522. Fsck can be run on the whole filesystem or on a subset of files.
  523. </p>
  524. </div>
  525. <a name="N1017E"></a><a name="Upgrade+and+Rollback"></a>
  526. <h2 class="h3"> Upgrade and Rollback </h2>
  527. <div class="section">
  528. <p>
  529. When Hadoop is upgraded on an existing cluster, as with any
  530. software upgrade, it is possible there are new bugs or
  531. incompatible changes that affect existing applications and were
  532. not discovered earlier. In any non-trivial HDFS installation, it
  533. is not an option to loose any data, let alone to restart HDFS from
  534. scratch. HDFS allows administrators to go back to earlier version
  535. of Hadoop and <em>roll back</em> the cluster to the state it was in
  536. before
  537. the upgrade. HDFS upgrade is described in more detail in
  538. <a href="http://wiki.apache.org/hadoop/Hadoop%20Upgrade">upgrade wiki</a>.
  539. HDFS can have one such backup at a time. Before upgrading,
  540. administrators need to remove existing backup using <span class="codefrag">bin/hadoop
  541. dfsadmin -finalizeUpgrade</span> command. The following
  542. briefly describes typical upgrade procedure :
  543. </p>
  544. <ul>
  545. <li>
  546. Before upgrading Hadoop software,
  547. <em>finalize</em> if there an existing backup.
  548. <span class="codefrag">dfsadmin -upgradeProgress status</span>
  549. can tell if the cluster needs to be <em>finalized</em>.
  550. </li>
  551. <li>Stop the cluster and distribute new version of Hadoop.</li>
  552. <li>
  553. Run the new version with <span class="codefrag">-upgrade</span> option
  554. (<span class="codefrag">bin/start-dfs.sh -upgrade</span>).
  555. </li>
  556. <li>
  557. Most of the time, cluster works just fine. Once the new HDFS is
  558. considered working well (may be after a few days of operation),
  559. finalize the upgrade. Note that until the cluster is finalized,
  560. deleting the files that existed before the upgrade does not free
  561. up real disk space on the datanodes.
  562. </li>
  563. <li>
  564. If there is a need to move back to the old version,
  565. <ul>
  566. <li> stop the cluster and distribute earlier version of Hadoop. </li>
  567. <li> start the cluster with rollback option.
  568. (<span class="codefrag">bin/start-dfs.h -rollback</span>).
  569. </li>
  570. </ul>
  571. </li>
  572. </ul>
  573. </div>
  574. <a name="N101BF"></a><a name="File+Permissions+and+Security"></a>
  575. <h2 class="h3"> File Permissions and Security </h2>
  576. <div class="section">
  577. <p>
  578. The file permissions are designed to be similar to file permissions on
  579. other familiar platforms like Linux. Currently, security is limited
  580. to simple file permissions. The user that starts Namenode is
  581. treated as the <em>super user</em> for HDFS. Future versions of HDFS will
  582. support network authentication protocols like Kerberos for user
  583. authentication and encryption of data transfers. The details are discussed in the
  584. <a href="hdfs_permissions_guide.html"><em>Permissions User and Administrator Guide</em></a>.
  585. </p>
  586. </div>
  587. <a name="N101D1"></a><a name="Scalability"></a>
  588. <h2 class="h3"> Scalability </h2>
  589. <div class="section">
  590. <p>
  591. Hadoop currently runs on clusters with thousands of nodes.
  592. <a href="http://wiki.apache.org/hadoop/PoweredBy">PoweredBy Hadoop</a>
  593. lists some of the organizations that deploy Hadoop on large
  594. clusters. HDFS has one Namenode for each cluster. Currently
  595. the total memory available on Namenode is the primary scalability
  596. limitation. On very large clusters, increasing average size of
  597. files stored in HDFS helps with increasing cluster size without
  598. increasing memory requirements on Namenode.
  599. The default configuration may not suite very large clustes.
  600. <a href="http://wiki.apache.org/hadoop/FAQ">Hadoop FAQ</a> page lists
  601. suggested configuration improvements for large Hadoop clusters.
  602. </p>
  603. </div>
  604. <a name="N101E3"></a><a name="Related+Documentation"></a>
  605. <h2 class="h3"> Related Documentation </h2>
  606. <div class="section">
  607. <p>
  608. This user guide is intended to be a good starting point for
  609. working with HDFS. While it continues to improve,
  610. there is a large wealth of documentation about Hadoop and HDFS.
  611. The following lists starting points for further exploration :
  612. </p>
  613. <ul>
  614. <li>
  615. <a href="http://hadoop.apache.org/">Hadoop Home Page</a>
  616. : the start page for everything Hadoop.
  617. </li>
  618. <li>
  619. <a href="http://wiki.apache.org/hadoop/FrontPage">Hadoop Wiki</a>
  620. : Front page for Hadoop Wiki documentation. Unlike this
  621. guide which is part of Hadoop source tree, Hadoop Wiki is
  622. regularly edited by Hadoop Community.
  623. </li>
  624. <li>
  625. <a href="http://wiki.apache.org/hadoop/FAQ">FAQ</a> from Hadoop Wiki.
  626. </li>
  627. <li>
  628. Hadoop <a href="http://hadoop.apache.org/core/docs/current/api/">
  629. JavaDoc API</a>.
  630. </li>
  631. <li>
  632. Hadoop User Mailing List :
  633. <a href="mailto:core-user@hadoop.apache.org">core-user[at]hadoop.apache.org</a>.
  634. </li>
  635. <li>
  636. Explore <span class="codefrag">conf/hadoop-default.xml</span>.
  637. It includes brief
  638. description of most of the configuration variables available.
  639. </li>
  640. </ul>
  641. </div>
  642. </div>
  643. <!--+
  644. |end content
  645. +-->
  646. <div class="clearboth">&nbsp;</div>
  647. </div>
  648. <div id="footer">
  649. <!--+
  650. |start bottomstrip
  651. +-->
  652. <div class="lastmodified">
  653. <script type="text/javascript"><!--
  654. document.write("Last Published: " + document.lastModified);
  655. // --></script>
  656. </div>
  657. <div class="copyright">
  658. Copyright &copy;
  659. 2007 <a href="http://www.apache.org/licenses/">The Apache Software Foundation.</a>
  660. </div>
  661. <!--+
  662. |end bottomstrip
  663. +-->
  664. </div>
  665. </body>
  666. </html>