Wednesday, 8 October 2014

Hadoop copyFromLocal: `/user/hduser/ ': No such file or directory 找不到路徑的問題

Preface

當安裝好Hadoop之後,想要簡單的測試一下字數統計(WordCount)的MapReduce,必定要先準備好資料,放到Hadoop的HDFS裡面,第一次進行將檔案放到HDFS的時候卻遇到了"copyFromLocal: `/user/hduser/gutenberg': No such file or directory"。發生這個問題是因為HDFS並沒有你當前使用帳戶的資料夾,所以你要先執行一個指令,為你當前使用的帳戶新增

Solution

這非常的簡單,執行以下指令即可
#若你所使用的帳戶不是hduser,請自行修改指令  $ hdfs fs -mkdir -p /user/hduser

Related Posts:

  • SSH 設定 config 使用不同的 Key 對應不同的 Server Preface 在工作的時候常常會遇到公司的 codebase 要設定 SSH 之後才能把自己的程式碼 commit 上去,可是這時候又會遇到自己的常常在使用的 codebase 可能是 Github, Gitlab......等等其他的服務。如果需要常常將 SSH key 作切換的話蠻麻煩的。… Read More
  • Git 合併分支 Merge feature branch to develop branch or master branch Preface 根據 Git Flow 開發流程,這裡記錄的是最後一步,功能開發完成後要將 feature branch 合併回 develop branch 或 master branch。這裡將合併的指令操作流程記錄下來。 Tutorial 首先,確認要合併 feature branch… Read More
  • Git 回復 commit 為 staging Preface 先前已經有介紹過 Git flow 開發流程,Git 的開發過程中會經常地使用 commit 的這個動作。如此一來一定會很常遇到要把最近一次的 commit 回復到 staging 進行重新修改,以利於把這一系列有相關的修改統整為一次的 commit。便於 code review… Read More
  • Git 設定個人資訊 Preface 當使用 Git 進行版本控制時,完成 local commit 後,需要將 commit push 到 remote repository 的時候需要將個人的 profile 一同 push 到 remote repository 前,需要先設定個人的 profile。 Tut… Read More
  • Git 使用 stash 功能來暫存目前修改的狀態 Preface 目前個人使用 Git 遇到會需要使用 stash 功能情境為,目前的 feature branch 開發到一半,但是有一個臨時的 hotfix 需要先進行修改。手邊目前的 feature branch 功能也還沒有完成到適合 commit 的狀態。想要在不進行 commit 的狀… Read More

0 comments:

Post a Comment