2014-10-10 10 views
5

Chcę uruchomić kod Spark na EC2 przeciwko danych przechowywanych w moim wiadrze S3. Zgodnie z Spark EC2 documentation i Amazon S3 documentation, muszę dodać moje AWS_ACCESS_KEY_ID i AWS_SECRET_ACCESS_KEY do pliku core-site.xml. Jednak po powrocie do mojego głównego węzła EC2 widzę kilka plików core-site.xml.Do jakich plików core-site.xml mogę dodać klucze dostępu AWS?

$ 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 

Po kilku eksperymentach, uznałem, że mogę uzyskać dostęp do adresu URL S3N jak s3n://mcneill-scratch/GR.txt od Spark tylko jeśli dodam moje poświadczenia zarówno mapreduce/conf/core-site.xml i iskier/conf/rdzenia miejscu. xml.

Wydaje mi się to niewłaściwe. To nie jest DRY i nie mogę znaleźć niczego w dokumentacji, która mówi, że musisz dodać swoje poświadczenia do wielu plików.

Czy modyfikowanie wielu plików jest prawidłowym sposobem ustawiania referencji s3 za pośrednictwem pliku core-site.xml? Czy istnieje gdzieś dokumentacja, która to tłumaczy?

Odpowiedz

-1

./spark/conf/core-site.xml powinno być odpowiednie miejsce

Powiązane problemy