大家好,又见面了,我是你们的朋友全栈君。
下载wget http://www.boutell.com/rinetd/http/rinetd.tar.gz
[root@DBA128 ~]tar -xvf rinetd.tar.gz
[root@DBA128 ~]# cd rinetd
[root@DBA128 rinetd]#
查看安装文档README
root@DBA128 rinetd]# more README
rinetd version 0.62, by Thomas Boutell. Released under
the terms of the GNU General Public License, version 2 or later.
This program is used to efficiently redirect connections
from one IP address/port combination to another. It is
useful when operating virtual servers, firewalls
and the like.
A binary for 32-bit Windows (95, 98, NT) is included (see the
file rinetd.exe). Windows 3.1 is not supported.
To build under Unix, check the Makefile for platform-
specific details and then type make. To install, type
“make install” as root.
To build under Windows, use the provided project
files with Microsoft Visual C++. Windows 3.1 is not supported.
For documentation run “make install”, then type
“man rinetd” for details. Or, read index.html in
your browser.
[root@DBA128 rinetd]#
[root@DBA128 rinetd]# make
[root@DBA128 rinetd]# make install
install -m 700 rinetd /usr/sbin
install -m 644 rinetd.8 /usr/man/man8
install: 无法创建普通文件”/usr/man/man8″: 没有那个文件或目录
make: *** [install] 错误 1
[root@DBA128 rinetd]#
此时出现错误
手动出现创建目录
[root@DBA128 rinetd]# mkdir –p /usr/man/man8
[root@DBA128 rinetd]# make install
install -m 700 rinetd /usr/sbin
install -m 644 rinetd.8 /usr/man/man8
[root@DBA128 rinetd]#
[root@DBA128 rinetd]# vim /etc/rinetd.conf
192.168.81.136 40012 10.19.69.106 30012
[root@DBA128 rinetd]# /usr/sbin/rinetd -c /etc/rinetd.conf
[root@DBA128 rinetd]# netstat -an | grep 40012
tcp 0 0 192.168.81.136:40012 0.0.0.0:* LISTEN
[root@DBA128 rinetd]# more /etc/rinetd.conf
可以添加到开机启动
[root@DBA128 rinetd]# vim /etc/rc.d/rc.local
/usr/sbin/rinetd -c /etc/rinetd.conf
转载于:https://my.oschina.net/ulink/blog/701132
发布者:全栈程序员-用户IM,转载请注明出处:https://javaforall.cn/126357.html原文链接:https://javaforall.cn
【正版授权,激活自己账号】: Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛
【官方授权 正版激活】: 官方授权 正版激活 支持Jetbrains家族下所有IDE 使用个人JB账号...