prollerweg 发表于 2018-7-20 07:54:32

映射-外网访问内网服务-ngrok和cisco路由做映射

  一:软件解决
  软件下载地址:
  https://ngrok.com/download
  ngrok-stable-windows-amd64.zip
  使用:
  cmd ---CD..切换到软件目录
  ngrok.exe
  在弹出框输入:ngrok http 80   (80或者其他端口号,根据实际情况)
  二:cisco路由做映射
  步骤如下

[*]  登陆cisco
[*]  en ,config
[*]  查看配置   show run
[*]  固定IP:
  ip nat inside source static tcp 10.10.1.253 8080 101.81.232.101 8080
[*]  动态IP:访问内网IP(10.10.1.155:8081interface Dialer1为外网动态IP)
  ip nat inside source static tcp 10.10.1.155 8081 interface Dialer1 8081
  注:Dialer1 需要在设备上查看,以实际为准,上面对内网10.10.1.155 8081端口做的映射,然后通过IP:8081即可访问内网服务器
[*]  命令show ip nat translations可以查看nat转换情况
  注:无法在内网访问服务器,如需内网访问需要做设置
页: [1]
查看完整版本: 映射-外网访问内网服务-ngrok和cisco路由做映射