首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >我应该将我的AWS访问密钥添加到哪个core-site.xml?

我应该将我的AWS访问密钥添加到哪个core-site.xml?
EN

Stack Overflow用户
提问于 2014-10-11 01:20:03
回答 1查看 889关注 0票数 5

我想对存储在我的S3存储桶中的数据在EC2上运行Spark代码。根据Spark EC2 documentationAmazon S3 documentation,我必须将AWS_ACCESS_KEY_ID和AWS_SECRET_ACCESS_KEY添加到core-site.xml文件中。然而,当我进入我的主节点时,我看到了几个EC2 -site.xml文件。

代码语言:javascript
复制
$ find . -name core-site.xml
./mapreduce/conf/core-site.xml
./persistent-hdfs/share/hadoop/templates/conf/core-site.xml
./persistent-hdfs/src/packages/templates/conf/core-site.xml
./persistent-hdfs/src/contrib/test/core-site.xml
./persistent-hdfs/src/test/core-site.xml
./persistent-hdfs/src/c++/libhdfs/tests/conf/core-site.xml
./persistent-hdfs/conf/core-site.xml
./ephemeral-hdfs/share/hadoop/templates/conf/core-site.xml
./ephemeral-hdfs/src/packages/templates/conf/core-site.xml
./ephemeral-hdfs/src/contrib/test/core-site.xml
./ephemeral-hdfs/src/test/core-site.xml
./ephemeral-hdfs/src/c++/libhdfs/tests/conf/core-site.xml
./ephemeral-hdfs/conf/core-site.xml
./spark-ec2/templates/root/mapreduce/conf/core-site.xml
./spark-ec2/templates/root/persistent-hdfs/conf/core-site.xml
./spark-ec2/templates/root/ephemeral-hdfs/conf/core-site.xml
./spark-ec2/templates/root/spark/conf/core-site.xml
./spark/conf/core-site.xml

经过一些实验后,我决定只有在mapreduce/conf/core-site.xml和Spark /conf/ s3n -site.xml中都添加了我的凭证时,我才能从spark访问像s3n://mcneill-scratch/GR.txt这样的核心url。

在我看来这是不对的。它不是DRY,我在文档中找不到任何关于您必须将凭据添加到多个文件的内容。

修改多个文件是通过s3 -site.xml设置核心凭证的正确方式吗?有没有什么文档可以解释这一点?

EN

回答 1

Stack Overflow用户

发布于 2016-05-27 23:12:47

./spark/conf/core-site.xml应该是正确的地方

票数 -1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/26304770

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档