您的位置:首页 > 运维架构

"hadoop fs -conf " does not work

2013-03-13 22:38 363 查看
<<hadoop:The Definitive guide>> 150L

the following is written.

----------------------------------------------------------------------------------------------------------------------

With this setup, it is easy to use any configuration with the -conf command-line switch.

For example, the following command shows a directory listing on the HDFS server

running in pseudodistributed mode on localhost:

% hadoop fs -conf conf/hadoop-localhost.xml -ls .

Found 2 items

drwxr-xr-x- tom supergroup

0 2009-04-08 10:32 /user/tom/input

drwxr-xr-x- tom supergroup

0 2009-04-08 13:09 /user/tom/output

-----------------------------------------------------------------------------------------------------------------------

But i tested and found that the command " hadoop "fs -conf conf/hadoop-localhost.xml -ls ." cannot work. The following results was gotten.

---------------------------------------------

13/03/13 22:28:41 INFO ipc.Client: Retrying connect to server: localhost/127.0.0.1:8020. Already tried 0 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1 SECONDS)

----------------------------------------------

what's wrong?what's wrong?

I executeed "hadoop fs"

---------------------------------------------

desktop:~$ hadoop fs

Usage: java FsShell

[-ls <path>]

[-lsr <path>]

[-du <path>]

[-dus <path>]

[-count[-q] <path>]

[-mv <src> <dst>]

[-cp <src> <dst>]

[-rm [-skipTrash] <path>]

[-rmr [-skipTrash] <path>]

[-expunge]

[-put <localsrc> ... <dst>]

[-copyFromLocal <localsrc> ... <dst>]

[-moveFromLocal <localsrc> ... <dst>]

[-get [-ignoreCrc] [-crc] <src> <localdst>]

[-getmerge <src> <localdst> [addnl]]

[-cat <src>]

[-text <src>]

[-copyToLocal [-ignoreCrc] [-crc] <src> <localdst>]

[-moveToLocal [-crc] <src> <localdst>]

[-mkdir <path>]

[-setrep [-R] [-w] <rep> <path/file>]

[-touchz <path>]

[-test -[ezd] <path>]

[-stat [format] <path>]

[-tail [-f] <file>]

[-chmod [-R] <MODE[,MODE]... | OCTALMODE> PATH...]

[-chown [-R] [OWNER][:[GROUP]] PATH...]

[-chgrp [-R] GROUP PATH...]

[-help [cmd]]

Generic options supported are

-conf <configuration file> specify an application configuration file

-D <property=value> use value for given property

-fs <local|namenode:port> specify a namenode

-jt <local|jobtracker:port> specify a job tracker

-files <comma separated list of files> specify comma separated files to be copied to the map reduce cluster

-libjars <comma separated list of jars> specify comma separated jar files to include in the classpath.

-archives <comma separated list of archives> specify comma separated archives to be unarchived on the compute machines.

The general command line syntax is

bin/hadoop command [genericOptions] [commandOptions]

----------------------------------------------
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐