当前位置:网站首页>ADDS:使用 PowerShell 创建 OU 结构
ADDS:使用 PowerShell 创建 OU 结构
2022-07-29 10:23:00 【生活在香樟园里】
1、技术背景:
1)客户新开设一家事务所,需要在 AD 中创建单独的 OU 容器。
2)在新事务所的 OU 中,含该事务所的用户、计算机、服务器、用户组、服务账户等 AD 对象。
3)同时,也创建一个管理安全组并授予其对新 OU 相应的管理权限。
4)事务所的树形架构规范:
<Country>
-<City>
--Admins
---<City>_admins
---<City>_account_managers
---<City>_wks_admins
--Computers
--Contacts
--Groups
--Servers
--Service Accounts
--Users2、脚本代码:
# Set the containers name
$Country = "CH"
$City = "CD"
$CityFull = "Chengdu"
$DomainDN = (Get-ADDomain).DistinguishedName
$ParentOU = "OU="+$Country+",$DomainDN"
$OUs = @(
"Admins",
"Computers",
"Contacts",
"边栏推荐
猜你喜欢

Two MySQL tables with different codes (utf8, utf8mb4) are joined, resulting in index failure
![[FPGA tutorial case 18] develop low delay open root calculation through ROM](/img/c3/02ce62fafb662d6b13aedde79e21fb.png)
[FPGA tutorial case 18] develop low delay open root calculation through ROM

The latest translated official pytorch easy introduction tutorial (pytorch version 1.0)
![[Yugong series] go teaching course 010 in July 2022 - Boolean and character types of data types](/img/3c/eaadcc105377f012db5ee8852b5e28.png)
[Yugong series] go teaching course 010 in July 2022 - Boolean and character types of data types

这才是开发者神器正确的打开方式

根据给定字符数和字符,打印输出“沙漏”和剩余数

Only simple function test? One article takes you to advanced interface automatic testing technology in 6 steps

English grammar_ Indefinite pronouns - Common Phrases
![[paper reading] i-bert: integer only Bert quantification](/img/2e/4f574b266ec6fc88ffa5dab56f2b8d.png)
[paper reading] i-bert: integer only Bert quantification

Talk about multithreaded concurrent programming from a different perspective without heap concept
随机推荐
Meituan senior technical expert: DDD's practice in the evolution of tourism e-commerce architecture
Where are those test / development programmers in their 30s? a man should be independent at the age of thirty......
Follow teacher Tian to learn practical English Grammar (continuous update)
【日志框架】
HMS Core Discovery第16期回顾|与虎墩一起,玩转AI新“声”态
Consumer electronics, frozen to death in summer
ECCV 2022 | CMU proposes to recurse on the visual transformer without adding parameters, and the amount of calculation is still small
Summer 2022 software innovation laboratory training JDBC
Understanding of Arduino circuit
Shell notes (super complete)
Efficient 7 habit learning notes
[IVI] 17.1 debugging pit FAQ (compilation)
VMWare:使用命令更新或升级 VMWare ESXi 主机
Attachment of text of chenjie Report
[Yugong series] go teaching course 010 in July 2022 - Boolean and character types of data types
Some suggestions for programmers to leave single
跟着李老师学线代——行列式(持续更新)
Comprehensively design an oppe home page -- the bottom of the page
Solve problems intelligently
Dimensionality reduction and mathematical modeling after reading blog!