Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to load local file #35

Open
tobegit3hub opened this issue Sep 5, 2015 · 2 comments
Open

Fail to load local file #35

tobegit3hub opened this issue Sep 5, 2015 · 2 comments

Comments

@tobegit3hub
Copy link

I was tryging to read local file with sc.textFile("./README.md") in spark container. But if fails and throw exception to file hdfs://README.md which is really not what we want.

@kakoni
Copy link

kakoni commented Mar 21, 2016

You need to explicitly specify URI schema
sc.textFile("file:///.README.md").

Using simple form sc.textFile("./README.md") ends up reading fs.defaultFS parameter from Hadoop conf, which is usually set to "hdfs://"

@tobegit3hub
Copy link
Author

Well, thanks for your help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants