Monday, July 20, 2015

HDFS frequently used commands

ram@ram:~$ hadoop fsck /
DEPRECATED: Use of this script to execute hdfs command is deprecated.
Instead use the hdfs command for it.

15/07/20 20:30:02 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
Connecting to namenode via http://localhost:50070/fsck?ugi=ram&path=%2F
FSCK started by ram (auth:SIMPLE) from /127.0.0.1 for path / at Mon Jul 20 20:30:04 IST 2015
Status: HEALTHY
 Total size:    0 B
 Total dirs:    2
 Total files:    0
 Total symlinks:        0
 Total blocks (validated):    0
 Minimally replicated blocks:    0
 Over-replicated blocks:    0
 Under-replicated blocks:    0
 Mis-replicated blocks:        0
 Default replication factor:    3
 Average block replication:    0.0
 Corrupt blocks:        0
 Missing replicas:        0
 Number of data-nodes:        1
 Number of racks:        1
FSCK ended at Mon Jul 20 20:30:04 IST 2015 in 3 milliseconds


The filesystem under path '/' is HEALTHY

ram@ram:~$ hadoop fs -copyFromLocal /home/ram/Documents/1.log /user
ram@ram:~$ hadoop fs -ls /userFound 1 items
-rw-r--r--   3 ram supergroup      50270 2015-07-20 20:34 /user/1.log

ram@ram:~$ hadoop fs -copyToLocal /user/1.log ~/15/07/20 20:36:38 WARN hdfs.DFSClient: DFSInputStream has been closed already

ram@ram:~$ ls1.log  Desktop  Documents  Downloads  examples.desktop  Music  Pictures  Public  Templates  Videos  zookeeper

ram@ram:~$ hadoop fs -setrep -w 3 /user/1.logReplication 3 set: /user/1.log

ram@ram:~$ hadoop fs -cat /user/1.log
ram@ram:~$ hadoop fs -du /user
50270  /user/1.log


ram@ram:~$ hadoop fs -ls hdfs://localhost:9000/Found 2 items
drwxrwxr-x   - ram supergroup          0 2015-07-20 21:45 hdfs://localhost:9000/tmp
drwxr-xr-x   - ram supergroup          0 2015-07-20 21:43 hdfs://localhost:9000/user
ram@ram:~$

21 comments:

  1. Managing a business data is not an easy thing, it is very complex process to handle the corporate information both Hadoop and cognos doing this in a easy manner with help of business software suite, thanks for sharing this useful post….
    Regards,
    cognos Training in Chennai|cognos Training Chennai|cognos Training

    ReplyDelete
  2. It’s too informative blog and I am getting conglomerations of info’s. Thanks for sharing; I would like to see your updates regularly so keep blogging. If anyone looking car just get here
    Regards,
    sas training in Chennai|sas course in Chennai|sas institutes in Chennai

    ReplyDelete
  3. Maharashtra Police Patil Recruitment 2016

    Your site so great, thanks for all news post information.....

    ReplyDelete
  4. Excellent article. Very interesting to read. I really love to read such a nice article. Thanks! keep rocking.Hadoop Admin Online Training Bangalore

    ReplyDelete
  5. Were a gaggle of volunteers as well as starting off a brand new gumption within a community. Your blog furnished us precious details to be effective on. You've got completed any amazing work!

    python training in chennai | python training in bangalore

    python online training | python training in pune

    python training in chennai

    ReplyDelete
  6. Really great post, I simply unearthed your site and needed to say that I have truly appreciated perusing your blog entries. I want to say thanks for great sharing.
    java training in omr

    java training in annanagar | java training in chennai

    java training in marathahalli | java training in btm layout

    java training in rajaji nagar | java training in jayanagar

    ReplyDelete
  7. I really like the dear information you offer in your articles. I’m able to bookmark your site and show the kids check out up here generally. Im fairly positive theyre likely to be informed a great deal of new stuff here than anyone
    Python training in marathahalli
    Python training in pune
    AWS Training in chennai

    ReplyDelete
  8. This is very good content you share on this blog. it's very informative and provide me future related information.
    Devops Training in Chennai
    Devops training in sholinganallur

    ReplyDelete
  9. Thank you for sharing such great information with us. I really appreciate everything that you’ve done here and am glad to know that you really care about the world that we live in.
    Angularjs Training in Chennai
    Angular 4 Training in Chennai
    angularjs training center in chennai
    Angularjs Training Chennai
    Angularjs courses in Chennai

    ReplyDelete
  10. Nice post ! Thanks for sharing valuable information with us. Keep sharing. Hadoop Classes in Pune

    ReplyDelete
  11. Were a gaggle of volunteers as well as starting off a brand new gumption within a community. Your blog furnished us precious details to be effective on. You've got completed any amazing work!
    data science training in chennai

    data science training in omr

    android training in chennai

    android training in omr

    devops training in chennai

    devops training in omr

    artificial intelligence training in chennai

    artificial intelligence training in omr

    ReplyDelete

  12. Great post. keep sharing such a worthy information.
    AWS Training institute in Chennai

    ReplyDelete