Я недавно обновил версию своей искры от 1.5 до 2.0.1. Сценарии python перестают работать.не удалось создать sparkcontext в sparkversion 2.0.1
код в 1.5, который работал
sc=SparkContext(appName="YOGI")
код изменен в искрой 2.0.1
sc =SparkContext().master("spark://107.110.74.58:7077").appName("Python Spark SQL basic example").getOrCreate()
File "/home/yogendra.s/codebase/processRawData.py", line 56, in <module>
sc =SparkContext().master("spark://107.110.74.58:7077").appName("Python Spark SQL basic example").getOrCreate()
File "/home/yogendra.s/.spark_update/spark_hadoop2_7/python/lib/pyspark.zip/pyspark/context.py", line 115, in __init__
File "/home/yogendra.s/.spark_update/spark_hadoop2_7/python/lib/pyspark.zip/pyspark/context.py", line 174, in _do_init
File "/home/yogendra.s/.spark_update/spark_hadoop2_7/python/lib/pyspark.zip/pyspark/accumulators.py", line 259, in _start_update_server
File "/usr/lib/python2.7/SocketServer.py", line 420, in __init__
self.server_bind()
File "/usr/lib/python2.7/SocketServer.py", line 434, in server_bind
self.socket.bind(self.server_address)
File "/usr/lib/python2.7/socket.py", line 224, in meth
return getattr(self._sock,name)(*args)
socket.gaierror: [Errno -2] Name or service not known
Content of my default.xml
spark.master spark://107.110.74.58:7077
spark.driver.memory 20g
spark.executor.memory 20g