-   Linux - Networking (
-   -   serial port network connection (

eantoranz 10-29-2005 07:11 PM

serial port network connection
Is it possible to connect two computers by a serial cable?

I think it's possible with SLIP, but I'm not sure. I just need to provide internet access to another computer, but their link is a serial cable. Is that possible? *-)

I loaded the slip module on the "internet connected" box, but that didn't create another network interface. I had read that I would have a sl0 interface. :confused:

michaelk 10-30-2005 05:04 PM

You can use PPP to establish a connetion between to PCs.

eantoranz 10-31-2005 08:05 AM

Hey.. that looks pretty simple! :-) Thanks for the tip... I'll keep it in mind next time I have to do this.

I ended up solving the problem with slattach.

once you run slattach on a given serial port, there will be a new network interface. sl0 in my case.

I had to do something like this:


slattach /dev/ttyS0 &
ifconfig sl0
route add -host dev sl0
route add default gw

server (not taking care of firewall... just routing to the client):

slattach /dev/ttyS0 &
ifconfig sl0
route add -host dev sl0

By the way.... it is a very good idea to change the speed of the serial ports... to something higher that 9600.. but I can't remember what the command for that was.... anyway, the ppp solution seems a lot easier... so you could simply stick with that one.


All times are GMT -5. The time now is 01:01 PM.