Windows Server 2008 R2之七使用Ntdsutil删除对象
2009-08-07 08:25
609 查看
Ntdsutil作为活动目录数据库管理的命令行工具,它主要执行数据库的维护、管理和控制操作主机、删除从网络上非正常卸载DC留下的元数据,以及创建应用程序分区等。在以前的实验中,我们曾多次使用这个工具,感受到它强大的功能。
实验环境:
森林中有两台DC,它们同时也时GC,分别是Win2008R2CNDC,WIN2008R2CNDC01.假设由于硬件故障,WIN2008R2CNDC01无法启动,现在我们要删除这个对象。
实验步骤:
以下操作在Win2008R2CNDC这台DC上完成。
1、运行Ntdsutil
2、输入Metadata cleanup (清理不使用的服务器的对象)
Remove selected domain - 删除所选域的 AD DS 对象
Remove selected Naming Context - 为选定的命名上下文删除对象
Remove selected server - 从所选服务器上删除对象
Remove selected server %s - 从所选服务器上删除对象
Remove selected server %s on %s - 从所选服务器上删除对象
Select operation target - 选择的站点,服务器,域,角色和命名上下文
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/3e3b0654e5b9e1b8cd26f67e4668e68d.jpg)
3、输入Connections(连接到一个特定的AD DC或LDS实例)
4、connect to server win2008r2cndc.hbycrsj.com(连接到服务器win2008r2cndc.hbycrsj.com)
5、quit(返回上一层目录,即Metadata cleanup操作命令状态)
6、select operation target(选择操作对象)
在此命令状态,我们通过命令当前域,站点,服务器的情况
List current selections - 列出当前的站点/域/服务器/命名上下文
List domains - 列出所有包含交叉引用的域
List domains in site - 列出所选站点中的域
List Naming Contexts - 列出已知命名上下文
List roles for connected server - 列出已连接的服务器已知的角色
List servers for domain in site - 列出所选域和站点中的服务器
List servers in site - 列出所选站点中的服务器
List sites - 在企业中列出站点
Quit - 返回到上一个菜单
Select domain %d - 将 %d 域定为所选域
Select Naming Context %d - 使命名上下文 %d 为选定的命名上下文
Select server %d - 将 %d 服务器定为所选服务器
Select site %d - 将 %d 站点定为所选站点
7、List sites(在企业中列出站点)
8、select site 0(将 %d 站点定为所选站点)
9、list domains in site(列出所选站点中的服务器)
10、select domain 0(将 %d 域定为所选域)
11、select servers for domain in site(列出所选域和站点中的服务器)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/eda9a863feecfaf3b44a351a9417c359.jpg)
12、select server 1(将 %d 服务器定为所选服务器)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/663b7ef1ea2b2104180eef11b662d37e.jpg)
13、quit
14、remove select server
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/6ad8d2b3b7fb60e55d9d6eabab69e5ba.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/aa81ee5e9e7a822f6277fd51ec68fbc2.jpg)
补充说明:
为了从AD彻底删除这个对象,我们还有必须在DNS服务器删除有关记录。
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/800cd5b73b994eb04531402e77dda0e0.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/92b8606b70d45683e78cafba2b556fb1.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/52e92ce96025ae6cb9c5c2b57b84242f.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/5e8d01fa35ca2f4e7ff04f7006fbf3a7.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/49659688edaaf9f22461ad04a2eb39de.jpg)
本文出自 “从心开始” 博客,请务必保留此出处http://ycrsjxy.blog.51cto.com/618627/203089
实验环境:
森林中有两台DC,它们同时也时GC,分别是Win2008R2CNDC,WIN2008R2CNDC01.假设由于硬件故障,WIN2008R2CNDC01无法启动,现在我们要删除这个对象。
实验步骤:
以下操作在Win2008R2CNDC这台DC上完成。
1、运行Ntdsutil
2、输入Metadata cleanup (清理不使用的服务器的对象)
Remove selected domain - 删除所选域的 AD DS 对象
Remove selected Naming Context - 为选定的命名上下文删除对象
Remove selected server - 从所选服务器上删除对象
Remove selected server %s - 从所选服务器上删除对象
Remove selected server %s on %s - 从所选服务器上删除对象
Select operation target - 选择的站点,服务器,域,角色和命名上下文
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/3e3b0654e5b9e1b8cd26f67e4668e68d.jpg)
3、输入Connections(连接到一个特定的AD DC或LDS实例)
4、connect to server win2008r2cndc.hbycrsj.com(连接到服务器win2008r2cndc.hbycrsj.com)
5、quit(返回上一层目录,即Metadata cleanup操作命令状态)
6、select operation target(选择操作对象)
在此命令状态,我们通过命令当前域,站点,服务器的情况
List current selections - 列出当前的站点/域/服务器/命名上下文
List domains - 列出所有包含交叉引用的域
List domains in site - 列出所选站点中的域
List Naming Contexts - 列出已知命名上下文
List roles for connected server - 列出已连接的服务器已知的角色
List servers for domain in site - 列出所选域和站点中的服务器
List servers in site - 列出所选站点中的服务器
List sites - 在企业中列出站点
Quit - 返回到上一个菜单
Select domain %d - 将 %d 域定为所选域
Select Naming Context %d - 使命名上下文 %d 为选定的命名上下文
Select server %d - 将 %d 服务器定为所选服务器
Select site %d - 将 %d 站点定为所选站点
7、List sites(在企业中列出站点)
8、select site 0(将 %d 站点定为所选站点)
9、list domains in site(列出所选站点中的服务器)
10、select domain 0(将 %d 域定为所选域)
11、select servers for domain in site(列出所选域和站点中的服务器)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/eda9a863feecfaf3b44a351a9417c359.jpg)
12、select server 1(将 %d 服务器定为所选服务器)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/663b7ef1ea2b2104180eef11b662d37e.jpg)
13、quit
14、remove select server
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/6ad8d2b3b7fb60e55d9d6eabab69e5ba.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/aa81ee5e9e7a822f6277fd51ec68fbc2.jpg)
补充说明:
为了从AD彻底删除这个对象,我们还有必须在DNS服务器删除有关记录。
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/800cd5b73b994eb04531402e77dda0e0.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/92b8606b70d45683e78cafba2b556fb1.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/52e92ce96025ae6cb9c5c2b57b84242f.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/5e8d01fa35ca2f4e7ff04f7006fbf3a7.jpg)
![](https://oscdn.geek-share.com/Uploads/Images/Content/202012/08/49659688edaaf9f22461ad04a2eb39de.jpg)
本文出自 “从心开始” 博客,请务必保留此出处http://ycrsjxy.blog.51cto.com/618627/203089
相关文章推荐
- Windows Server 2008 R2使用Ntdsutil删除对象
- windows server 2008 R2 垃圾回收篇(活动目录对象删除与保护深入理解续集) 推荐
- Windows Server 2008 R2使用LDP恢复已删除的用户实战
- Windows Server 2008 R2中使用NTDSUTIL重置目录还原模式密码
- Windows Server 2008 R2 的使用方法
- 使用Windows server 2008 R2 wds 和 MDT2010 部署 Windows7 和 Windows xp时,客户端通过网络启动后,蓝屏或者黑屏,无法进入安装界面。
- 使用Sysinternals工具定时休眠Windows Server 2008 R2
- 无需破解:Windows Server 2008 R2 至少免费使用 900天
- 使用windows server 2008 r2 提供iscsi存储
- Windows Server 2008 R2入门之安装使用
- 使用kvm制作Eucalyptus镜像(Windows Server 2008r2为例)
- 使用U盘启动安装Windows 7 Windows Server 2008 R2
- 开发者使用 Windows Server 2008 R2 系统
- 无需破解:Windows Server 2008 R2 至少免费使用 900天
- 使用Windows Server 2008 R2 AD RMS对Exchange Server 2010进行信息权限管理
- 无需破解:Windows Server 2008 R2 至少免费使用 900天
- 使用Windows Server 2008 R2 Core 架设IIS服务器
- 使用Ntdsutil删除对象
- System x服务器使用ServerGuide引导安装Windows Server 2008 R2
- 不能删除windows server 2008中的对象,提示权限不足