NAT穿透服务器STUN Server 的安装使用

咱们用SIP 客户端呼叫的时候,常常遇到复杂的网络NAT环境,这个时候须要咱们安装STUN Server / Turn Server 作穿透用。
这里简单记录下 STUN Server的安装启动步骤:git

yum -y install gcc
yum -y install make
yum -y install boost # For Boost
yum -y install openssl
# For OpenSSL网络

wget http://www.stunprotocol.org/stunserver-1.2.3.tgzide

tar zxvf stunserver-1.2.3.tgzui

cd stunserver
makecode

检查环境 是否OK
./stuntestcodeserver

nohup /usr/local/stunserver/stunserver --mode basic --primaryinterface 172.31.78.132 &ssl

nohup ./stunserver --mode full --primaryinterface eth0 --altinterface eth0 &文档

全功能模式 须要2个IP get

./stunserver --mode full --primaryinterface 47.52.229.136 --altinterface 172.31.78.132 openssl

nohup ./stunserver --mode basic --primaryinterface 172.31.78.132

基本模式 1个IP

./stunserver --mode basic --primaryinterface 47.52.229.136 --altinterface 172.31.78.132

./stunserver --help 查看 参数说明!

文档:http://zengqf.gitee.io/ifreeswitchgui/

相关文章
相关标签/搜索