2

バックエンドの一部をローカルで実行し、ローカル コンピューターから EC2 インスタンスにリクエストを送信する環境をセットアップしようとしています。CDH 4.5 をセットアップしましたが、問題なく動作します。次のリクエストを実行すると

curl --negotiate -i -L -u:hdfs http://ec2-xx-xx-xx-xx.eu-west-1.compute.amazonaws.com:50070/webhdfs/v1/tmp/test.txt?op=OPEN

これは、そのリージョン内の任意の EC2 インスタンスから機能しますが、それ以外では機能しません。ローカルで試すと、次のエラーが返されます

curl: (6) Could not resolve host: ip-xx-xx-xx-xx.eu-west-1.compute.internal

通話をこのようにリダイレクトしないように設定できる場所がわかりませんか?

どうもありがとう

4

1 に答える 1

2

The easiest and fastest way to solve this problem is to configure your client hosts file to map the internal address to the external address.

WebHDFS uses the host name configured in hdfs-site.xml which is configured automatically by the Cloudera agent on that datanode. I don't know of a way to override the configured hostname for each datanode in CDH.

于 2014-04-29T16:15:46.600 に答える