Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm working with a linux application which needs to talk with a remotely-located serial (rs-232) device. I've worked out how to use socat on the remote end to send the device's serial data over an IP connection, but how do I then convert that IP stream back into a (pseudo) serial device character device (e.g. /dev/fakesocatserial0) on the other side?

share|improve this question

have you tried sshfs? You can simply mount remote:/dev into somewhere like local:/remote/dev and point to the actual character device

share|improve this answer
Well, the remote device is an embedded board with no SSH, so I'm trying to avoid changing its configuration if at all possible. – Alex G May 1 '12 at 17:00
ah, then @mgorven 's socat method is the way to go – platinummonkey May 1 '12 at 17:41

You should be able to use the PIPE address type of socat to create a Unix pipe to connect to, for example (assuming that the device with the real serial device creates the network connection):

socat PIPE:/dev/fakesocatserial0 TCP-LISTEN:1234
share|improve this answer
Maybe something like this? socat PTY,link=/dev/fakeserial0,raw,echo=0,wait-slave TCP4:remote-board:1723 – Alex G May 1 '12 at 17:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.