locked
请问如何实现"公网IP"映射到虚拟内中的群集IP上? RRS feed

  • 问题


  • 例如:
    1、一台阿里云机器(系统:win server 2008 r2 ),这台机器是提供外网访问的,有固定公网IP2个(一个是远程访问使用,另一个是提供给群集IP访问);
    公网IP:(111.10.110.15)
    提供群集IP(111.10.110.14)比如
    2、里面安装了3个虚拟机(系统也都是win server 2008)。
       A虚拟机内网IP(192.168.0.11)
       B虚拟机内网IP(192.168.0.12)
       C虚拟机内网IP(192.168.0.13)
    这三个虚拟机做了NLB(网络负载平衡),群集IP是(192.168.0.100)。

    问题:如何实现把(111.10.110.14)IP映射到  群集IP上(192.168.0.100) ?
    期望目的:外网访问(111.10.110.14)时,能够访问到(192.168.0.100)上
    2015年10月3日 2:00

答案

  • 你好,

    在Windows的RRAS中启用NAT,可以实现端口映射。

    Nic2是外网网卡(相当于你的111.10.110.14网卡),然后选择想要映射的服务,点击编辑,就可以输入内网IP(即192.168.0.100)。也可以点击添加,手动输入想要映射的端口。

    Best Regards,

    Leo


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.

    • 已建议为答案 Leo Han 2015年10月20日 3:16
    • 取消建议作为答案 server 126 2015年10月20日 10:21
    • 已建议为答案 Leo Han 2015年11月4日 7:26
    • 已标记为答案 Leo Han 2015年11月6日 6:28
    2015年10月6日 6:07

全部回复

  • 群集IP映射和普通IP映射没什么区别吧,直接加端口映射;
    2015年10月4日 8:37
  • 端口映射不是需要路由器支持吗? 想直接在Windows server2008 上实现,能行吗?就是不借助其他硬件设备
    2015年10月5日 1:21
  • 你好,

    在Windows的RRAS中启用NAT,可以实现端口映射。

    Nic2是外网网卡(相当于你的111.10.110.14网卡),然后选择想要映射的服务,点击编辑,就可以输入内网IP(即192.168.0.100)。也可以点击添加,手动输入想要映射的端口。

    Best Regards,

    Leo


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.

    • 已建议为答案 Leo Han 2015年10月20日 3:16
    • 取消建议作为答案 server 126 2015年10月20日 10:21
    • 已建议为答案 Leo Han 2015年11月4日 7:26
    • 已标记为答案 Leo Han 2015年11月6日 6:28
    2015年10月6日 6:07
  • 非常感谢您的回答,我试一试吧。

    我想应用到我的wcf项目中,想使用这个实现wcf的负载均衡功能,不知道可行不可行。

    2015年10月20日 10:22
  • 你好,

    关于WCF的问题,可以到MSDN查询相关资料。

    https://msdn.microsoft.com/zh-cn/?f=255&MSPPError=-2147217396

    Best Regards,

    Leo


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.

    2015年10月21日 5:53
  • 您好,非常感谢您的回复,您发送的链接地址不正确吧
    2015年10月22日 1:18
  • 你好,

    这是微软开发人员网络,可以在那里查找和询问WCF相关的问题:
    https://msdn.microsoft.com/zh-cn/

    Best Regards,

    Leo


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.

    2015年10月22日 5:57