Solved

Port replicator/duplicator

Posted on 2004-04-07
7
803 Views
Last Modified: 2010-05-18
I'm looking for a suitable open source (or similar) tool that will allow me to do port replication.  To explain:


On server A, I want a process to listen on a particular port (say 6666), and when the clients talk to this port, it is intercepted and sent to server B and C (or N number of servers) listening on some other port.

I know there's simple TCP plugs out there, but I'm after something a little smarter that at a minimum will duplicate the stream to any number of upstream servers and optionally be able to alter the packet payload.
0
Comment
Question by:Tintin
7 Comments
 
LVL 48

Author Comment

by:Tintin
ID: 10779718
Alternatively a Perl script using IO::Socket (or any other module that's useful) will be accepted.

I'm going to have a go at writing my own, but not having done socket programming before, I'm not that confident as to how robust it will be.
0
 
LVL 9

Assisted Solution

by:Alf666
Alf666 earned 150 total points
ID: 10780182
What you're looking for is not a "port replicator", but a level 2 switch (load balancer), or a High Availability (HA) solutions.

There are a few projects resolving this kind of issues :

The Linux Virtual Server :
http://www.linux-vs.org/

The Linux High Availability System :
http://linux-ha.org/

0
 
LVL 48

Author Comment

by:Tintin
ID: 10780239
I probably should have used the term "redirector" instead of "replicator'.

Thanks for the info, but HA and Load balancing is definitely not what I want.

I'm pretty confident I can do what I need in around 20 lines of Perl code, so I'll see how I go.
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 48

Author Comment

by:Tintin
ID: 10780423
I've found a solution to my problem.  It involved modifying an existing Perl script and adding a few lines to modify the data and send it on to another host.

However, I'll leave this open for a little while and allocate points based on useful tools that people suggest.
0
 
LVL 4

Assisted Solution

by:oumer
oumer earned 150 total points
ID: 10780903
use iptables
0
 
LVL 45

Accepted Solution

by:
sunnycoder earned 200 total points
ID: 10781274
0
 
LVL 48

Author Comment

by:Tintin
ID: 10818970
While none of the tools mention really do what I require, I'm going to allocate the points out to everyone.

BTW, netpipes is also a useful tool (although not in my case).
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now