s-u / Rserve

Fast, flexible and powerful server providing access to R from many languages and systems
http://RForge.net/Rserve
Other
282 stars 65 forks source link

##> SOCK_ERROR: bind error #48(address already in use) #168

Closed loisjung closed 3 years ago

loisjung commented 3 years ago

I am connecting R to Tableau so downloaded Rserve but I keep having this error ##> SOCK_ERROR: bind error #48(address already in use) after I run Rserve(args="--no-save")

I rebooted my mac and also tried to terminate the process but this error message keeps occurring.. Could anyone please help me with fixing this error? I appreciate it ahead!

s-u commented 3 years ago

It means you have already Rserve running or something else is already using the port that you are using for Rserve. You may want to contact Tableau support since for all we know it may be Tableau already starting Rserve.

On macOS you can use lsof to check which program is using which ports, so if you are using the default port (6311) then you can check for it using

$ lsof -n | grep LISTEN | grep :6311
Rserve    42107 urbanek    3u     IPv4 0x490c27d4dad07033       0t0                 TCP 127.0.0.1:6311 (LISTEN)

in the above case Rserve is already running so you don't need to start it. You can also stop the above instance using kill -INT 42107