Found solution. I've changed the library and functions to open and read sockets.
Using base package I wrote: msg3<-"function=subscribe|item=MI.EQCON.1|schema=last_price;ask;bid" msg4<-"function=unsubscribe" #open socket connection socketPointer<-socketConnection('localhost', port=5333, server=FALSE) #subscribe writeLines(msg3, socketPointer) #read data from file readLines(con=socketPointer,n=1,ok=TRUE,warn=TRUE,encoding='UTF-8') #unsubscribe writeLines(msg4, socketPointer) #close socket close(socketPointer) Now it works fine. -- View this message in context: http://r.789695.n4.nabble.com/read-socket-utils-package-something-is-going-wrong-tp4531374p4531764.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.