Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

socketConnection error in sparkR

Tags:

r

sparkr

I am very new to SparkR. When I ran sparkR, something was wrong.

sc <- sparkR.init(master="local")

error like this:

Error in socketConnection(port = monitorPort) : 
  cannot open the connection
In addition: Warning message:
In socketConnection(port = monitorPort) : localhost:32811 cannot be opened

Somebody told me it's a localhost issue, but it didn't work when I change the localhost to local IP address. Is there really a problem in localhost setting?

like image 475
wesson.Gan Avatar asked Oct 30 '22 17:10

wesson.Gan


1 Answers

Add the following system variable: $EXISTING_SPARKR_BACKEND_PORT to an available port and rerun sparkR.

like image 194
marko Avatar answered Nov 15 '22 06:11

marko