Spark context (sc) not found

0 votes

I start spark using spark-shell. 

But I am getting "sc not found " error . I have set the SPARK_MASTER_ID in spark-env.sh. stopped the service and started again using the following commands, still the same error.

sudo service hadoop-master stop
sudo service hadoop-master start hadoop dfsadmin -safemode leave
Feb 13 in Apache Spark by Loki
71 views

1 answer to this question.

0 votes

Maybe the hadoop service didn't start properly. Try restarting the services:

cd /usr/lib/spark-2.1.1-bin-hadoop2.7

./sbin/stop-all.sh

and then, start it again:

./sbin/start-all.sh

And then run your command

answered Feb 13 by John

Related Questions In Apache Spark

–1 vote
1 answer

Not able to use sc in spark shell

Seems like master and worker are not ...READ MORE

answered Jan 3 in Apache Spark by Omkar
• 67,660 points
179 views
–1 vote
1 answer

Deciding number of spark context objects

How many spark context objects you should ...READ MORE

answered Jan 16 in Apache Spark by Omkar
• 67,660 points
45 views
0 votes
1 answer

where can i get spark-terasort.jar and not .scala file, to do spark terasort in windows.

Hi! I found 2 links on github where ...READ MORE

answered Feb 13 in Apache Spark by Omkar
• 67,660 points
142 views
0 votes
1 answer

Not able to preserve shuffle files in Spark

You lose the files because by default, ...READ MORE

answered Feb 23 in Apache Spark by Rana
54 views
0 votes
1 answer
0 votes
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,730 points
3,371 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,730 points
405 views
0 votes
10 answers

hadoop fs -put command?

put syntax: put <localSrc> <dest> copy syntax: copyFr ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Aditya
16,737 views
0 votes
1 answer

How can I write a text file in HDFS not from an RDD, in Spark program?

Yes, you can go ahead and write ...READ MORE

answered May 29, 2018 in Apache Spark by Shubham
• 13,310 points
1,577 views
0 votes
1 answer

Spark-shell not working

First, reboot the system. And after reboot, ...READ MORE

answered Jul 15 in Apache Spark by Mahesh
110 views