Support Questions
Find answers, ask questions, and share your expertise
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here. Want to know more about what has changed? Check out the Community News blog.

File not Found Exception - Spark 2


File not Found Exception - Spark 2

New Contributor



Running a 3 node CDH cluster with 1 master and 2 slaves. I have a web application written in Java that submits spark job to YARN. Getting the below error now . Web App is deployed with Tomcat which runs as different OS user. 


Application application_1502437323246_0010 failed 2 times due to AM Container for appattempt_1502437323246_0010_000002 exited with exitCode: -1000
For more detailed output, check application tracking page:, click on links to logs of each attempt.
Diagnostics: File file:/home/user/tomcat/apache-tomcat-8.0.38/temp/spark-1692c53f-313a-41c1-9581-e716c244b7c8/ does not exist File file:/home/user/tomcat/apache-tomcat-8.0.38/temp/spark-1692c53f-313a-41c1-9581-e716c244b7c8/ does not exist
at org.apache.hadoop.fs.RawLocalFileSystem.deprecatedGetFileStatus(
at org.apache.hadoop.fs.RawLocalFileSystem.getFileLinkStatusInternal(
at org.apache.hadoop.fs.RawLocalFileSystem.getFileStatus(
at org.apache.hadoop.fs.FilterFileSystem.getFileStatus(
at org.apache.hadoop.yarn.util.FSDownload.copy(
at org.apache.hadoop.yarn.util.FSDownload.access$000(
at org.apache.hadoop.yarn.util.FSDownload$
at org.apache.hadoop.yarn.util.FSDownload$
at Method)
at java.util.concurrent.Executors$
at java.util.concurrent.ThreadPoolExecutor.runWorker(
at java.util.concurrent.ThreadPoolExecutor$
Failing this attempt. Failing the application.
it looks like the worker nodes do not have access to the above file location and those files should ideally be created on HDFS so that workers can access it.
1) what are these files and why are they getting created under the temp folder of tomcat ?
2) Is there configuration that can create these files on HDFS to resolve the above error
3) Any other considerations while running in "Client" deploy mode ?
Any other information will be useful as i am new to Spark and HDFS. I am using the default configuration of CDH 5.12 and along with Spark 2.1.0 distribution