https://www.cnblogs.com/SanMaoSpace/p/4983738.html SharePoint基于windows验证的如何通过组策略实现IE自动以当前域账号登录某站点 1. 在运行中运行MMC,启动“组策略对象编辑器”。 如下图: 2.找到组策略,如下图: 3.找到对应的域,如下图: 4.点右键编辑:
https://www.cnblogs.com/SanMaoSpace/p/4983738.html SharePoint基于windows验证的如何通过组策略实现IE自动以当前域账号登录某站点 1. 在运行中运行MMC,启动“组策略对象编辑器”。 如下图: 2.找到组策略,如下图: 3.找到对应的域,如下图: 4.点右键编辑:
http://woshub.com/group-policy-not-applied-troubleshooting/?utm_source=pocket_mylist In this GPO troubleshooting guide, I’ll try to tell you about the typical reasons why a certain Group Policy Object (GPO) might not apply to an organizational unit (OU) or a specific domain computer/user. I think this article will be useful for both novice and experienced AD Group Policy administrators to understand how Group Policies work and GPO architecture. The article describes potential problems with applying GPOs related to the policy settings at the domain level, as well as troubleshooting GPOs on Windows clients. Almost all settings described in the article are configured using the Group Policy Management Console (GPMC.msc). Contents:
PowerShellの再帰処理と参照渡し引数 https://pswork.jp/powershell/recursive-reference/ PowerShellのメソッドで、参照渡し引数の使い方をつい忘れてしまうことがあるので、再帰処理と併用したコードサンプルを残します。 考え方として、グローバルスコープの変数を使用すれば、わざわざ参照渡しにしなくても済むものですが、メソッド自体の汎用性も無くなってしまい、スクリプトそのものがガチガチになって手を入れにくいものになってしまうので、参照渡し引数を扱えるほうが良いです。 サンプルとして、参照渡しに使用する変数は、ファイルを表す FileInfo クラスを配列として保持する変数にします。 再帰処理としては、フォルダー階層の配下のファイルを列挙するというものにします。 まず、配列変数を宣言しておき、これを参照変数として使います。
不想手动设置PC的IP,又希望在路由器里固定IP,设置长期租约后,强迫症想要马上生效,可以用以下方式清理DHCP分配的IP: 编辑 /tmp/dhcp.leases 文件,删除想清理的IP地址/MAC地址那一行 重启dnsmasq:/etc/init.d/dnsmasq restart PC上:ipconfig /release 或断网重连即可。
from>https://www.digitalcitizen.life/how-reset-looks-command-prompt-or-powershell-window/ ------------保存以下内容到[reset-ps-console-color.reg]后执行即可重置------------ Windows Registry Editor Version 5.00 [-HKEY_CURRENT_USER\Console] ------------------------------------------------------------------------------------------ After you work for a while with the Command Prompt or PowerShell, you are likely to end up customizing the way they look. After all, by default, their looks and colors look quite dull for many. You might change the font, its size, the color of the background, and other things. What do you do if you want to reset PowerShell to its default settings and colors? Can you reset Command Prompt's (cmd) colors and settings? Unfortunately, there's no "Restore console default" button available anywhere! Fortunately, as always, there is something you can do. Read this guide to learn how to reset PowerShell or the Command Prompt to its default settings: NOTE: Before following any of the methods from this guide, you should create a System Restore point. That assures you that you can revert your system to its current settings if you don't like the result. How to reset PowerShell to its default color settings PowerShell's colors and overall console looks are stored in its shortcut file instead of a separate file or registry key. In other words, to reset PowerShell to its default color settings, you need to reset PowerShell's shortcut from the Start Menu. Start by
from > https://stackoverflow.com/questions/20874464/format-table-on-array-of-hash-tables Using Powershell V4: $table = @( @{ColumnA="Able"; ColumnB=1}, @{ColumnA="Baker"; ColumnB=2}, @{ColumnA="Charlie"; ColumnB=3} )
#getBoxFiles.ps1 #created by mikebai 2021/07/15 jpfocus.com $topFolderId = "0" $topFolderName = "BoxTop" # https://developer.box.com/reference/get-folders-id-items/ # https://developer.box.com/reference/resources/file/#param-content_created_at # file info props > https://developer.box.com/reference/get-files-id/#response-example $urlTemplate = "https://api.box.com/2.0/folders/{0}/items?fields=name,id,type,created_by,created_at,modified_at,modified_by&limit=100000" $devToken = "xxxxxxxxxxxxxxx" # you can get dev token id from > https://app.box.com/developers/console $formatter1 = "yyyy_MM_dd" $formatter2 = "yyyy_MM_dd__HH_mm_ss" $formatter3 = "yyyy/MM/dd HH:mm:ss" $scriptFolder = split-path -parent $MyInvocation.MyCommand.Definition $tabTag = "`t" $Headers = @{} $Headers = @{"Authorization" = "Bearer $devToken" } function getFiles { param ( [Parameter(Mandatory = $true)] [ValidateNotNull()] [string]$parentFolderId, [Parameter(Mandatory = $true)] [ValidateNotNull()] [string]$parenFoldertName, [Parameter(Mandatory = $true)] [ValidateNotNull()] [Int32]$layerLevel ) $url = $urlTemplate -f $parentFolderId $fileInfoList = Invoke-RestMethod -Method Get -Uri $url -Headers $Headers if ( $null -eq $fileInfoList -or $null -eq $fileInfoList.entries -or 0 -eq $fileInfoList.entries.Length) {  
NAT NAT(Network Address Translation,网络地址转换)是将IP 数据包头中的IP 地址转换为另一个IP 地址的过程。在实际应用中,NAT 主要用于实现私有网络访问公共网络的功能。这种通过使用少量的公有IP 地址代表较多的私有IP 地址的方式,将有助于减缓可用IP地址空间的枯竭。 DNAT DNAT Destination Network Address Translation 目的网络地址转换 SNAT SNAT Source Network Address Translation 源网络地址转换,其作用是将ip数据包的源地址转换成另外一个地址 区分SNAT和DNAT 从定义来讲它们一个是源地址转换,一个是目标地址转换。都是地址转换的功能,将私有地址转换为公网地址。 要区分这两个功能可以简单的由连接发起者是谁来区分: 内部地址要访问公网上的服务时(如web访问),内部地址会主动发起连接,由路由器或者防火墙上的网关对内部地址做个地址转换,将内部地址的私有IP转换为公网的公有IP,网关的这个地址转换称为SNAT,主要用于内部共享IP访问外部。 当内部需要提供对外服务时(如对外发布web网站),外部地址发起主动连接,由路由器或者防火墙上的网关接收这个连接,然后将连接转换到内部,此过程是由带有公网IP的网关替代内部服务来接收外部的连接,然后在内部做地址转换,此转换称为DNAT,主要用于内部服务对外发布。
In this article we will look at the various load balancing solutions available in Azure and which one should be used in which scenario. Background Load balancer are the essential components when it comes to creating high available web applications. We have all used load balancers with traditional on premise servers where our application is running on N instances and a load balancer is sitting in front of these servers and distributing load to them based on some predefined algorithm and connection affinity settings. Moving to the cloud, we need to understand how we can achieve the same load balancing using Azure components. Load balancing in cloud applications require much more thought that having a simple load balancer in front of some servers as we could have services hosted on PaaS, we could have services running on separate instances for separate tenants and we could also have applications running on multiple servers that are geographically distributed across the world. For this reason itself, there are multiple components available in Azure for load balancing. Each of these components have a different purpose and we need to choose the right component for the scenario to be able to achieve the optimal application architecture. Azure Load Balancing Solutions There are mainly 3 load balancing components available in Azure. Azure Load balancer Azure Application gateway Azure traffic manager Let’s start understanding each of these components one by one and try to understand when to use each component effectively. Azure Load balancer Azure Load Balancer is a Load Balancer in a more classical sense…
Azure 提供的负载均衡服务叫 Load Balancer,它工作在 ISO 七层模型的第四层,通过分析 IP 层及传输层(TCP/UDP)的流量实现基于 "IP + 端口" 的负载均衡。 Azure Load Balancer 的主要功能 负载均衡 基于 ISO 四层的负载均衡,请参考下图(此图来自互联网): 端口转发 通过创建入站 NAT 规则,可以实现端口转发,将来自前端 IP 地址的特定端口的流量转发到虚拟网络中特定后端实例的特定端口。比如我可以映射前端 IP 的 10022 端口到后端 VM1 的 22 端口;映射前端 IP 的 20022 端口到后端 VM2 的 22 端口。 对应用程序透明 协议握手始终在客户端与后端池中的虚机实例之间直接发生。 对入站请求做出的响应始终是来自虚拟机的响应。 当请求抵达虚拟机时,也会保留原始的源 IP 地址。 自动探测后端主机状态 为确定后端池中实例的运行状况,负载均衡器会使用预定义的规则检测后端实例的运行状况。当探测到故障时负载均衡器会停止向该实例发送新连接。 现有连接不受影响,会一直保留到应用程序终止了请求、超时或虚机关闭为止。 注意:基础版的 Load Balancer 只支持 TCP 和 HTTP 协议的探测规则,而标准版还支持 HTTPS 协议的探测规则。 出站连接(SNAT) 从虚拟网络中的私有 IP 地址发往 Internet 上的公共 IP 地址的所有出站流量都被转换为负载均衡器的前端 IP 地址。通过负载均衡规则将前端公共 IP 地址端绑定到后端 VM 后,Azure 会将出站连接设定为自动转换成前端的公共 IP 地址。 内部负载均衡和公共负载均衡 我们可以通过下图来理解内部负载均衡(Internal Load Balancer)和公共负载均衡(Public Load Balancer)的区别(此图来自互联网): 简单的说就是公共负载均衡的前端 IP 是公网 IP,是面向 Internet 的;而内部负载均衡的前端 IP 则是面向私有网络的私有 IP,并不直接与公网交互。 通过 Azure 门户创建 Load Balancer 示例 在 Azure 门户网站中添加 Load Balancer 类型的资源,设置基本信息,比如下图所示: 这里我们创建一个面向 Internet 的具有公共 IP 的的 Load Balancer,因此随 Load Balancer 一起创建的还有一个公共的 IPv4 地址: 在 Load Balancer 创建完成后,我们就可以开始设置其详细的属性了。比较常用的配置有前端 IP、后端池、运行状况探测、负载均衡规则和入站 NAT 规则: 配置前端 IP 前端 IP 是访问负载均衡后端资源的接口,相关的基本配置在我们创建 Load Balancer 已经随之完成了(就是面向公网的一个 IPv4 地址): 配置后端池 所谓的后端池就是藏在 Load Balancer 背后真正干活的主儿,这里我们先去创建两台虚机,然后再把这两台虚机添加到 Load Balancer 的后端池中。 下面是创建虚机时的一些注意事项。 把新建的虚机放入同一个可用性集中(AvailabilitySet) 因为我们创建的是基础版的 Load Balancer,它的后端池只支持在同一个可用性集中的虚机,所以我们要创建一个可用性集,并把所有的虚机加入到这个可用性集中(只有在创建虚机时才能加入可用性集): 不需要入站规则 因为我们的主机是隐藏在 Load Balancer 后面的,所以不需要设置入站端口规则: 也不需要公用 IP 和网络安全组(因为虚机在私有的子网中) 对虚机的访问可用通过配置 Load Balancer 的入站 NAT 规则实现。 新建虚机后就可以把它们加入 Load Balancer 的后端池了,下面是创建虚机的过程中创建出的资源: 添加后端池 新建一个后端池,并把我们创建的可用性集 nicklbavailabilityset 中的虚机加入其中: 添加完成后可以看到后端池中的虚机及其状态: 运行状况探测 Load Balancer 需要通过运行状况探测机制来监控后端池中资源的状态,可以使用运行状况探测来检测后端实例上应用程序的故障。这里我们通过检测后端虚机的 80 号端口来判断其服务的状态: 默认的规则是每隔 5 秒检测一次,如果连续失败两次就认为虚机提供的服务离线。 负载均衡规则 负载均衡规则定义了 Load Balancer 以何种方式把用户的请求分配给后端池中的虚机: