Hadoop: Compile and Run URLCat example code
2013-12-10 08:47
393 查看
[cloud@hdn01 XuClass]$ javac -classpath ../hadoop-core-1.2.1.jar ./URLCat.java
[cloud@hdn01 XuClass]$ ls
URLCat.class URLCat.java
[cloud@hdn01 XuClass]$ cd ..
[cloud@hdn01 hadoop-1.2.1]$ bin/hadoop URLCat hdfs://hdn01:9000/user/cloud/in/file1.txt
Warning: $HADOOP_HOME is deprecated.
13/12/09 16:43:52 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 0 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:53 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 1 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:54 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 2 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:55 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 3 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
^C[cloud@hdn01 hadoop-1.2.1]$ jps
2500 Jps
[cloud@hdn01 hadoop-1.2.1]$ bin/start-all.sh
Warning: $HADOOP_HOME is deprecated.
starting namenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-namenode-hdn01.out
hdd01: datanode running as process 52962. Stop it first.
hdd02: datanode running as process 49872. Stop it first.
hdn02: secondarynamenode running as process 41173. Stop it first.
starting jobtracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-jobtracker-hdn01.out
hdd01: tasktracker running as process 53066. Stop it first.
hdd02: tasktracker running as process 49976. Stop it first.
[cloud@hdn01 hadoop-1.2.1]$ bin/stop-all.sh
Warning: $HADOOP_HOME is deprecated.
stopping jobtracker
hdd01: stopping tasktracker
hdd02: stopping tasktracker
stopping namenode
hdd02: stopping datanode
hdd01: stopping datanode
hdn02: stopping secondarynamenode
[cloud@hdn01 hadoop-1.2.1]$ bin/start-all.sh
Warning: $HADOOP_HOME is deprecated.
starting namenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-namenode-hdn01.out
hdd01: starting datanode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-datanode-hdd01.out
hdd02: starting datanode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-datanode-hdd02.out
hdn02: starting secondarynamenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-secondarynamenode-hdn02.out
starting jobtracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-jobtracker-hdn01.out
hdd01: starting tasktracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-tasktracker-hdd01.out
hdd02: starting tasktracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-tasktracker-hdd02.out
[cloud@hdn01 hadoop-1.2.1]$ bin/hadoop URLCat hdfs://hdn01:9000/user/cloud/in/file1.txt
Warning: $HADOOP_HOME is deprecated.
Hello, world
[cloud@hdn01 hadoop-1.2.1]$
[cloud@hdn01 XuClass]$ ls
URLCat.class URLCat.java
[cloud@hdn01 XuClass]$ cd ..
[cloud@hdn01 hadoop-1.2.1]$ bin/hadoop URLCat hdfs://hdn01:9000/user/cloud/in/file1.txt
Warning: $HADOOP_HOME is deprecated.
13/12/09 16:43:52 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 0 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:53 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 1 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:54 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 2 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
13/12/09 16:43:55 INFO ipc.Client: Retrying connect to server: hdn01/10.1.1.10:9000. Already tried 3 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)
^C[cloud@hdn01 hadoop-1.2.1]$ jps
2500 Jps
[cloud@hdn01 hadoop-1.2.1]$ bin/start-all.sh
Warning: $HADOOP_HOME is deprecated.
starting namenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-namenode-hdn01.out
hdd01: datanode running as process 52962. Stop it first.
hdd02: datanode running as process 49872. Stop it first.
hdn02: secondarynamenode running as process 41173. Stop it first.
starting jobtracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-jobtracker-hdn01.out
hdd01: tasktracker running as process 53066. Stop it first.
hdd02: tasktracker running as process 49976. Stop it first.
[cloud@hdn01 hadoop-1.2.1]$ bin/stop-all.sh
Warning: $HADOOP_HOME is deprecated.
stopping jobtracker
hdd01: stopping tasktracker
hdd02: stopping tasktracker
stopping namenode
hdd02: stopping datanode
hdd01: stopping datanode
hdn02: stopping secondarynamenode
[cloud@hdn01 hadoop-1.2.1]$ bin/start-all.sh
Warning: $HADOOP_HOME is deprecated.
starting namenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-namenode-hdn01.out
hdd01: starting datanode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-datanode-hdd01.out
hdd02: starting datanode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-datanode-hdd02.out
hdn02: starting secondarynamenode, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-secondarynamenode-hdn02.out
starting jobtracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-jobtracker-hdn01.out
hdd01: starting tasktracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-tasktracker-hdd01.out
hdd02: starting tasktracker, logging to /opt/hadoop-1.2.1/libexec/../logs/hadoop-cloud-tasktracker-hdd02.out
[cloud@hdn01 hadoop-1.2.1]$ bin/hadoop URLCat hdfs://hdn01:9000/user/cloud/in/file1.txt
Warning: $HADOOP_HOME is deprecated.
Hello, world
[cloud@hdn01 hadoop-1.2.1]$
相关文章推荐
- Android Kernel Compile And Run (转载http://code.google.com/p/androidteam/wiki/AndroidKernelCompileAndRun)
- c# - Start to compile and run mono c# code
- Compile and build specific Hadoop source code branch using Azure VM
- Install qibuild. Compile and run an example.
- 面试题:What will happen when you attempt to compile and run the following code
- EBS中 ABC编制类型(标准)-编码和描述(Compile Type Code(Creiterion) and Description)。
- Hadoop example program code
- 设计模式之Relating Run-Time and Compile-TimeStructures
- Setup and run a simple nhibernate example
- Android sdk and souce code download & compile
- Tree in Combo Box example code (using HTTPService and XML)
- Combine Web and Windows Services to Run Your ASP.NET Code at Scheduled
- How to compile and debug VLC player source code in eclipse IDE on Ubuntu 10.04 (lucid)
- Dowload and compile android source code implemented by qualcomm
- A real example of vioplot in R (sample data and code attached)
- Why this code compile OK, but throw ClassCastException at run time?
- Can I compile and run Dx11Shader for Maya 2015 on my side?
- Android to the picture plus text and image watermarking example code
- Android sdk and souce code download & compile
- build, debug, compile and run