मेरे पास JSON डेटा है जो मैं कई फ़ील्ड के साथ डेटा फ्रेम में पढ़ रहा हूं, इसे दो स्तंभों के आधार पर दोबारा विभाजित कर रहा हूं, और पांडों में परिवर्तित हो रहा हूं।Pyspark सरल पुन: विभाजन और toPandas() केवल 600,000+ पंक्तियों को खत्म करने में विफल रहता है
यह नौकरी कुछ अस्पष्ट त्रुटियों के साथ डेटा की 600,000 पंक्तियों पर ईएमआर पर विफल रहता है। मैंने स्पार्क ड्राइवर की मेमोरी सेटिंग्स भी बढ़ा दी है, और अभी भी कोई रिज़ॉल्यूशन नहीं दिख रहा है।
यहाँ मेरी pyspark कोड है:
conf = SparkConf().setAppName('myapp1')
conf.set('spark.yarn.executor.memoryOverhead', 8192)
conf.set('spark.executor.memory', 8192)
conf.set('spark.driver.memory', 8192)
sc = SparkContext(conf=conf)
त्रुटियों मैं कर रहे हैं::
16/10/01 19:57:56 ERROR executor.CoarseGrainedExecutorBackend: Driver 172.31.58.76:37973 disassociated! Shutting down.
16/10/01 19:57:11 ERROR executor.CoarseGrainedExecutorBackend: Driver 172.31.58.76:42167 disassociated! Shutting down.
16/10/01 19:57:56 ERROR executor.CoarseGrainedExecutorBackend: Driver 172.31.58.76:37973 disassociated! Shutting down.
log4j:ERROR Could not read configuration file from URL [file:/etc/spark/conf/log4j.properties].
log4j:ERROR Ignoring configuration file [file:/etc/spark/conf/log4j.properties].
16/10/01 19:57:11 ERROR ApplicationMaster: RECEIVED SIGNAL 15: SIGTERM
16/10/01 19:57:11 ERROR ApplicationMaster: User application exited with status 143
log4j:ERROR Could not read configuration file from URL [file:/etc/spark/conf/log4j.properties].
log4j:ERROR Ignoring configuration file [file:/etc/spark/conf/log4j.properties].
16/10/01 19:57:56 ERROR ApplicationMaster: RECEIVED SIGNAL 15: SIGTERM
16/10/01 19:57:56 ERROR ApplicationMaster: User application exited with status 143
16/10/01 19:57:11 ERROR executor.CoarseGrainedExecutorBackend: Driver 172.31.58.76:42167 disassociated! Shutting down.
16/10/01 19:57:56 ERROR executor.CoarseGrainedExecutorBackend: Driver 172.31.58.76:37973 disassociated! Shutting down.
कोड ठीक पर काम करता है
enhDataDf = (
sqlContext
.read.json(sys.argv[1])
)
enhDataDf = (
enhDataDf
.repartition('column1', 'column2')
.toPandas()
)
enhDataDf = sqlContext.createDataFrame(enhDataDf)
enhDataDf = (
enhDataDf
.toJSON()
.saveAsTextFile(sys.argv[2])
)
मेरे चिंगारी सेटिंग्स इस प्रकार हैं लगभग 600,000 JSON लाइनों तक - भले ही स्मृति उपलब्ध है। फिर, यह असफल रहता है।
क्या हो रहा है और इस समस्या को कैसे डिबग/ठीक करने के बारे में कोई विचार है?
यह अभी भी मदद नहीं करता है। एक ही त्रुटि संदेशों के साथ विफलताओं को जारी रखें। मैं सचमुच 32 जीबी मेमोरी और ऊपर प्रति सेटिंग्स के साथ एम 4.2xlarge उदाहरणों पर चल रहा हूँ। बहुत परेशान है कि यह सिर्फ इन गुप्त त्रुटियों को देता है और अंधेरे गुना में विफल रहता है। – Gopala
हम्म मैं आपसे @ गोपाला से भी ऊपर नहीं हूं, इसका मतलब है कि मेरा जवाब खराब है, क्या मुझे इसे हटाना चाहिए? – gsamaras
मुझे नहीं लगता कि उत्तर खराब है। इसमें कुछ अंतर्दृष्टि और उपयोगी लिंक हैं। सिर्फ यह कि मेरी समस्या का समाधान नहीं हुआ और मैं अभी भी यह देखने का इंतजार कर रहा हूं कि आगे की मदद है या नहीं। – Gopala