AD常用命令

发布时间 : 星期日 文章AD常用命令更新完毕开始阅读

AD Administrative Snap-ins And Tools

常用AD管理组件和工具

一、活动目录的管理插件有如下: Active Directory Users and Computers Active Directory Domains and Trusts Active Directory Sites and Services Active Directory Schema

Active Directory Service Interfaces (ADSI)

二、活动目录修改及查询命令 dsadd命令(创建活动目录对象):用于在AD中创建OU、用户、组、联系人等对象,但是不能对AD中的对象进行修改,下面逐一进行介绍。

1、创建组织单位: 命令格式:dsadd ou [-desc 描述] [{-s 服务器|-d 域}] [-u 用户名] [-p {密码|*}] [-q] [{-uc|-uoc|-uci}]

注意:OU名称应为要创建的OU的LDAP绝对路径(DN,Distinguished Name),如果DN中包含空格,应该在路径两端使用双引号。

例如要在yjx.com域中建立一个名为finance的OU,可以执行以下命令:

C:\\>dsadd ou ou=finance,dc=yjx,dc=com -desc \财务部\

2、创建域用户帐户

命令格式:dsadd user [-samid ] -pwd {|*} –upn UPN

例如要在yjx.com域中建立一个名为mike的用户帐户,该用户将位于sales OU中,其显示名称为“mike yang”,则可以执行以下命令:

C:\\>dsadd user cn=mike,ou=sales,dc=yjx,dc=com -samid mike -pwd benet3.0 -display “mike yang”

3、创建计算机帐户

命令格式:dsadd computer

要在yjx.com域中的sales OU中建立一个名为client-2的计算机帐户,可以执行以下命令:

C:\\>dsadd computer cn=client-2,ou=sales,dc=yjx,dc=com

要在yjx.com域中的sales OU中建立一个名为client-3的计算机帐户,并设置计算机账户的描述信息为“测试工作站”,可以执行以下命令:

C:\\>dsadd computer cn=client-3,ou=sales,dc=yjx,dc=com -desc 测试工作站

4、创建联系人

命令格式:dsadd contact [-fn ] [-mi ] [-ln ] [-display ] [-desc ]

要在yjx.com域中的sales OU中建立一个名为杨建新的联系人,执行以下命令:

C:\\>dsadd contact cn=杨建新,ou=sales,dc=yjx,dc=com -fn jianxin -ln yang -display 杨建新

dsmod命令(修改活动目录对象):用于修改AD对象的属性,可以对OU、用户、组、联系人等对象进行修改。 C:\\>dsmod user /?

描述: 修改目录中现有的用户。

语法: dsmod user [-upn ] [-fn ]

[-mi ] [-ln ] [-display ]

[-fnp ] [-lnp ] [-displayp ]

[-empid ] [-pwd { | *}]

[-desc ] [-office ] [-tel ] [-email ] [-hometel ] [-pager ]

[-mobile ] [-fax ] [-iptel ]

[-webpg ] [-title ] [-dept <Department>] </p><p> [-company <Company>] [-mgr <Manager>] [-hmdir <HomeDir>] </p><p> [-hmdrv <DriveLtr>:] [-profile <ProfilePath>] [-loscr <ScriptPath>] [-mustchpwd {yes | no}] [-canchpwd {yes | no}] [-reversiblepwd {yes | no}] [-pwdneverexpires {yes | no}] </p><p> [-acctexpires <NumDays>] [-disabled {yes | no}] [{-s <Server> | -d <Domain>}] [-u <UserName>] [-p {<Password> | *}] [-c] [-q] [{-uc | -uco | -uci}]] 几个具体用法如下: 重置用户帐户的密码 </p><p>dsmod user UserDN -pwd 新密码 [-mustchpwd {yes | no}] 下次登录时修改此密码 </p><p>启用或禁用账户 </p><p>dsmod user UserDN 可分辨名称 -disabled {yes|no} yes 禁用 no 启用 </p><p>修改计算机帐户属性的格式为: </p><p>dsmod computer ComputerDN ...[-desc Description] [-loc Location] [-disabled {yes | no}] [-reset] [{-s Server | -d Domain}] [-u UserName] [-p {Password | *}] [-c] [-q] [{-uc | -uco | -uci}] </p><p>重设计算机帐户 </p><p>dsmod computer ComputerDN -reset </p><p>启用或禁用计算机帐户 </p><p>dsmod computer ComputerDN 可分辨名称 -disabled {yes|no} </p><p></p><div class="page"><ul><li><a href=lhd_31g6110fml7l7tx2asfy_1.html class="hover" >1</a></li><li><a href=lhd_31g6110fml7l7tx2asfy_2.html>2</a></li><li><a href=lhd_31g6110fml7l7tx2asfy_3.html>3</a></li><li><a href=lhd_31g6110fml7l7tx2asfy_4.html>4</a></li><li><a title=下一页 href=lhd_31g6110fml7l7tx2asfy_2.html>>></a></li><li><a href=lhd_31g6110fml7l7tx2asfy_8.html>8</a></li></ul></div></div> <!--<div style="margin:0 auto;text-align:center;overflow:hidden"><script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>--> <!-- 728 --> <!--<ins class="adsbygoogle" style="display:inline-block;width:728px;height:90px" data-ad-client="ca-pub-8169456067121985" data-ad-slot="2791506239"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script></div>--> <div class="hm-t-main"> <div class="hm-t-header"><h4><a rel="nofollow" target="_blank" href="/mlhdl_31g6110fml7l7tx2asfy.html">下载:AD常用命令.doc</a></h4></div> </div> <!--<script type="text/javascript"> var cpro_id = "u6856886"; </script> <script type="text/javascript" src="//cpro.baidustatic.com/cpro/ui/cm.js"></script>--> <div class="nlt new"><div id="hm_t_19094"><div class="hm-t-container"><div class="hm-t-main"><div class="hm-t-header"><h4>最近浏览</h4></div> <ul class="hm-t-list hm-t-list-txt"> <li><a title="2009年全国外贸业务员考试外贸业务基础理论试卷实务(A)及答案" href=mlhd_9v87o3ha971xep036ofx_1.html>2009年全国外贸业务员考试外贸业务基础理论试卷实务(A)及答案</a></li><li><a title="日字和水字旁的字日本姓名和翻译" href=mlhd_1g0xv7d81f2r4yi9c8hj79c964hjsm00lgs_4.html>日字和水字旁的字日本姓名和翻译</a></li><li><a title="新建项目公司名称" href=mlhd_546uv050au670et7bbfq_6.html>新建项目公司名称</a></li><li><a title="2017中华文化选讲答案单元测试答案-高中课件精选" href=mlhd_348eu476za0sr9z0p01l1xu1x81ds800o3k_2.html>2017中华文化选讲答案单元测试答案-高中课件精选</a></li><li><a title="公文写作格式及范文模板" href=mlhd_0mp7d4r7yw5v45r563ne_1.html>公文写作格式及范文模板</a></li><li><a title="村级事务规范化制度汇编1" href=mlhd_73fq62nsrw175lm25rqs_8.html>村级事务规范化制度汇编1</a></li><li><a title="生物化学期末考试试题及答案" href=mlhd_05j5l89dey83uyx9681999g5n13tgu00uoq_1.html>生物化学期末考试试题及答案</a></li><li><a title="中石油目视化管理方案" href=mlhd_2ye9391xci6bod04q39t7z7sh75lu600ogw_5.html>中石油目视化管理方案</a></li><li><a title="小学5年级奥数题选" href=mlhd_3bv5w1bbd16zh7s4fk1n_1.html>小学5年级奥数题选</a></li><li><a title="(完整版)洪帆《离散数学基础》(第三版)课后习题答案" href=mlhd_852nu3pxqz47hq70zb090vngk58yua010j8_1.html>(完整版)洪帆《离散数学基础》(第三版)课后习题答案</a></li> </ul></div> <div style="margin:0 auto;text-align:center;"><br> </div></div></div></div> <div class="nlt new"><div id="hm_t_19094"><div class="hm-t-container"><div class="hm-t-main"> <div class="hm-t-header"><h4>最新搜索</h4></div> <ul class="hm-t-list hm-t-list-txt"> <li><a title="高职《机械设计基础》螺纹联接与螺旋传动习题含答案 - 图文" href="mlhs_ul4pcc9hmke2kogrlqrkxhdmnr49hnqt6p15pckjolff2qt6k3vfmogbsfhcu54gmjod0klk00w01900wh6mk1z_1.html">高职《机械设计基础》螺纹联接与螺旋传动习题含答案 - 图文</a></li><li><a title="森林公园规划说明书(DOC)" href="mlhs_kq6kgng30h65r7og7mrn8k5qfhi01401w02701v015_1.html">森林公园规划说明书(DOC)</a></li><li><a title="建论 圣灵论概要" href="mlhs_irerlm00wh7nm7prlmkuar5t_1.html">建论 圣灵论概要</a></li><li><a title="固废课设—填埋气" href="mlhs_h6iiovrnirlq6c4hgrhcblck_1.html">固废课设—填埋气</a></li><li><a title="精索静脉曲张各种手术对比(刚做好)" href="mlhs_on2oputw9phlkc2isgglgo25jezkdri61las014g7ufvehod015_1.html">精索静脉曲张各种手术对比(刚做好)</a></li><li><a title="2009年全国外贸业务员考试外贸业务基础理论试卷实务(A)及" href="mlhs_01e01c01c01linog2wh6lhlirw8ffegblgnspabrmdhlirw8ffegblhdmnr4mx2rlmrmdghji3igbl01401t015gju_1.html">2009年全国外贸业务员考试外贸业务基础理论试卷实务(A)及</a></li><li><a title="2016幸福心理学期末答案 97分" href="mlhs_01e01c01d01iinso0fiwzmx2i1ykdbkdnod0klk00w01l01jg7a_1.html">2016幸福心理学期末答案 97分</a></li><li><a title="!!2020年山东省高考模拟语文试卷及答" href="mlhs_00x00x01e01c01e01cinoi9dffgni9ul4pabkypjj3rn1k1zrmdghjgjuod0_1.html">!!2020年山东省高考模拟语文试卷及答</a></li><li><a title="建筑物可靠性鉴定收费标准" href="mlhs_ireocxmllgkvtwgizrsxgi3ejzqrw9kjrg5i_1.html">建筑物可靠性鉴定收费标准</a></li><li><a title="档 案 违 法 案 例" href="mlhs_kmb00wklk00wsf100wlhx00wklk00wfpn_1.html">档 案 违 法 案 例</a></li></ul></div></div></div></div> <div class="search"> <form style="display: inline;" id=f1 name=f1 method="POST" onSubmit="javascript:c();return false;"> <div class="p_searchinputbox"> <div class="p_search_seclet"><h3 id="j_searchType">站内搜索</h3></div><p> <input type="text" autocomplete="off" maxlength="38" name="word" placeholder class="searchinput"></p> <input type="submit" class="searchsubmit" onclick="javascript:c();return false;"></div> </form> </div> <div id="ft"> <a href="javascript:history.go(-1)"><span class="backPrevPage" style=""></span></a> <a href="javascript:pageScroll();"><span id="backTop"></span></a> <div class="bx1"> <span class="pc_ver"> <a href="#" onClick="javascript:setCookie('gotoweb', 'true', 1);window.location.href=window.location.href.replace('//m.','//www.').replace('/m','/')">电脑版</a> </span> <span class="info"> <a href="about.asp?id=3" target="_blank"><strong>关于南京廖华</strong></a> </span> </div> <div class="bx2"><span id=bb></span>联系<a href="http://www.hetong365.com/">合同范文</a>客服:xxxxx#qq.com(#替换为@)</div> </div> <!-- footer End --></div> <script type="text/javascript">function go2(id){window.location.href='http://m.china-audit.com/mlhdl_'+id+'.html';}</script> <script src="css/jquery.min.js"></script> </body></html>