Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

Installation and use of tcpcopy traditional Architecture

Shulou Source: shulou.com Published: 2022-06-03 06:06:36 09月24日 Update

1. Installation and use of traditional architecture 1.1. Schematic diagram

1.2. Installation

Install tcpcopy on-line and test environment machines respectively

Tar-xzvf tcpcopy-0.9.3.tar.gz

Cd tcpcopy-0.9.3

. / configure

Make & & make install

1.3. Run 1.3.1. The test machine is running:

TCPCopy server (root user execution)

1) start the kernel module ip_queue

# modprobe ip_queue

2) set the port to be intercepted, and set the output intercept

# iptables-I OUTPUT-p tcp-- sport-j QUEUE

: resin port

Eg: iptables-I OUTPUT-p tcp-- sport 8001-j QUEUE

3) start intercept

Nohup intercept &

1.3.2. Online machine operation

Tcpcopy-x-test machine ip:

Eg:nohup tcpcopy-x 80-192.168.74.205 purl 8001 &

1.3.3. Check whether it is successful

Check whether the request has been copied through netstat-na, top, or open accesslog.

Tags: Port test machine run test machine check tradition usage method architecture success kernel principle module environment user Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Microsoft OPPO Reno Apple Redmi Shulou Tech Info