Select-AzureSubscription -SubscriptionName “订阅名称"

$serviceName="云服务名称"

$ilbName="内部负载均衡名称"

$subnet=“子网名称"

$IP="IP地址"

Add-AzureInternalLoadBalancer -ServiceName $serviceName -InternalLoadBalancerName $ilbName –SubnetName $subnet –StaticVNetIPAddress $IP

#查看建立的内部负载均衡
# Get-AzureService -ServiceName $serviceName | Get-AzureInternalLoadBalancer

$vmName=“虚拟机名称"

$myVm = Get-AzureVM -ServiceName $serviceName -Name $vmName

$newVMEndpoints =

("LBSetname1","TCP",端口号1),

("LBSetname2","TCP",端口号2),

("LBSetname3","TCP",端口号3)

foreach ($endpointConfig in $newVmEndpoints)

{

$myVm | Add-AzureEndpoint -Name $endpointConfig[0] -Protocol $endpointConfig[1] -LocalPort $endpointConfig[2] -PublicPort $endpointConfig[2]–DefaultProbe -InternalLoadBalancerName $ilbName  -LBSetname $endpointConfig[0]

}
$myVm | Update-AzureVM

@查看建立的内部负载均衡集
# Get-AzureVM –ServiceName $serviceName –Name $vmName | Get-AzureEndpoint | select lbsetname

#2要素sourceIP负载均衡器规则

#–LoadBalancerDistribution 'sourceIP'

#3要素sourceIPProtocol负载均衡器规则

#–LoadBalancerDistribution 'sourceIPProtocol'

#默认的负载均衡器规则

#–LoadBalancerDistribution 'none'

Azure Powershell 创建 Internal Load Balancer的更多相关文章

  1. 在Google的GKE上创建支持Internal Load Balancer的Service

    在Google的Kubernetes Engine上发布service,可以采用除On-Promise相同的Cluster IP和NodePort两种方式外,还可以创建LoadBalaner的Serv ...

  2. 配置Internal Load balancer中VM的外网访问

    当在Azure中部署SQL VM时,处于安全考虑,不会配置VM的Public IP,会禁止外网的进出站访问,只允许从内部VNET,或者特定的内部IP访问.特别是当使用Azure Internal Lo ...

  3. Azure PowerShell (5) 使用Azure PowerShell创建简单的Azure虚拟机和Linux虚拟机

    <Windows Azure Platform 系列文章目录> 本文介绍的是国外的Azure Global.如果是国内由世纪互联运维的Azure China,请参考这篇文档: Azure ...

  4. Azure PowerShell (12) 通过Azure PowerShell创建SSH登录的Linux VM

    <Windows Azure Platform 系列文章目录> 本章将介绍如何使用Azure PowerShell,创建SSH登录的Linux VM 前提要求: 1.安装Azure Pow ...

  5. Azure China (8) 使用Azure PowerShell创建虚拟机,并设置固定Virtual IP Address和Private IP

    <Windows Azure Platform 系列文章目录> 本文介绍的是由世纪互联运维的Windows Azure China. 相比于Global Azure (http://www ...

  6. [New Portal]Windows Azure Virtual Machine (16) 使用Azure PowerShell创建Azure Virtual Machine

    <Windows Azure Platform 系列文章目录> 注:本章内容和之前的[New Portal]Windows Azure Virtual Machine (12) 在本地制作 ...

  7. Azure ARM (22) 使用Azure PowerShell创建Azure RM VM

    <Windows Azure Platform 系列文章目录> 在Azure China获得VM Image,可以执行下面的脚本. Get-AzureRmVMImagePublisher ...

  8. Azure PowerShell 创建虚拟机

    # 指定订阅名称$subscriptionName="订阅名称"# 指定云服务名称$serviceName="云服务名称"# 指定用来保存虚拟机VHD的存储$s ...

  9. Azure Load Balancer : 动态扩展

    笔者在前文<Azure Load Balancer : 支持 IPv6>中介绍了如何通过 PowerShell 脚本创建支持 IPv6 的 Load Balancer.本文我们接着介绍如何 ...

随机推荐

  1. 将UIWebView显示的内容转为图片和PDF

    今天开发MarkEditor时要用到将 UIWebView 中显示的内容转为图片,方便转发到各个社交网络(Twiiter,Facebook,Weibo),这样内容就不受长度限制,类似于长微博. 之前关 ...

  2. 在 MacOS 上编译链接 OpenGL 程序

    几个星期以前开始折腾在我的MBA上写 OpenGL 小程序.我不太熟悉MacOS上的开发工具比如XCode,所以一开始的想法就是用vim来写程序,然后手工编译链接.网上查了一下,MacOS上的Open ...

  3. [原]我的CentOS设置

    [Date]2013-10-06 [Keywords]Linux.CentOS.Fedora [Environment]CentOS 6.3 Final . Wiz [Content]: 1.安装Fl ...

  4. 【暑假】[深入动态规划]UVa 1627 Team them up!

    UVa 1627 Team them up! 题目: Team them up! Time Limit: 3000MS   Memory Limit: Unknown   64bit IO Forma ...

  5. CUDA网格限制

    如图

  6. BNUOJ-26474 Bread Sorting 逆序对

    题目链接:http://www.bnuoj.com/bnuoj/problem_show.php?pid=26474 题意:给一个数列,可以对三个数操作:把最后一个数放到第一个,前两个数后移一位.问最 ...

  7. HDU-4699 Editor 数据结构维护

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4699 题意:开始有一个光标,每次有5中操作:1,光标当前位置插入一个数,2,光标当前位置删除一个,3, ...

  8. HDU-4607 Park Visit bfs | DP | dfs

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4607 首先考虑找一条最长链长度k,如果m<=k+1,那么答案就是m.如果m>k+1,那么最 ...

  9. Project: Individual Project - Word frequency program----11061192zmx

    Description & Requirements http://www.cnblogs.com/jiel/p/3311400.html 项目时间估计 理解项目要求: 1小时 构建项目逻辑: ...

  10. 转载 SharePoint Foundation和SharePoint Server的区别

    SharePoint Server 2010用来取代MOSS 2007,它有标准版和企业版两个版本,使用SQL Server数据库: 早期版本中的STS或WSS在2010中更名为SharePoint ...