1. Use PowerShell query to specify the creation time of all accounts in the OU \sid\ last modified password time \ Last logon time:Get-aduser-searchbase ' ou=ll,dc=ll,dc=com '-filter *-properties * | Select-object Name,sid, created,passwordlastset,@{n= "lastlogondate"; e={[datetime]::fromfiletime($_.lastlogontimestamp)}} | Export-csv zuihoudenglu.csv-notypeinformation-encoding UTF82. Query ad, default password policy (password complexity to note, lock
1. Use PowerShell query to specify the creation time of all accounts in the OU \sid\ last modified password time \ Last logon time:Get-aduser-searchbase ' ou=ll,dc=ll,dc=com '-filter *-properties * | Select-object Name,sid, created,passwordlastset,@{n= "lastlogondate"; e={[datetime]::fromfiletime($_.lastlogontimestamp)}} | Export-csv zuihoudenglu.csv-notypeinformation-encoding UTF82. Query ad, default password policy (password complexity to note, lock
-----provide ad\exchange\lync\sharepoint\crm\sc\o365 and other Microsoft product implementation and outsourcing, qq:185426445. Phone 18666943750Today, I heard a friend in the group asking to inquire about an ad account that has not been logged in for the last 1 months, we can do this via PowerShell:Requirement 1, query creation time of all accounts in OU \sid\ last modified password time \ Last Login timePowerShell query Specifies the creation time for all accounts in the OU \sid\ last modified
One: Query the creation date of all users in this ad domainGet-aduser-filter *-properties * | Select-object Name,sid, created,passwordlastset,@{n= "Lastlogondate"; E={[datetime]::fromfiletime ($_. lastLogonTimestamp)}} | Export-csv accountlist.csv-notypeinformation-encoding UTF8File Save Address:The effect export file for CSV format requires an Excel table to open the displaySecond, query the user's creation date under the specified OU: This feature c
If you want to know the account usage in the AD, such as when to create, the last logon time is the time, the last password change, and other information, these can be achieved by using PowerShell.
In PowerShell, Get-AdUser can query a lot of information. For more information, see the following article:
Http://social.technet.microsoft.com/wiki/contents/articles/12037.active-directory-get-aduser-default-and-extended-properties.aspx
The following describes how to use PowerShell to query the creati
DemandNeeds to clean up the ad expired accounts, the intention is to clean 90 days not logged in the account can be, the result of leadership and worry if some long-term travel outside of the staff, so add a 30 days after the mailbox decision, if this person 90 days not logged in the domain, and 30 days not logged in the mailbox, it should be clearOperationDirectly on the text, with comments inside#加域AD模块Import-module ActiveDirectory#加载Exchange模块Add-pssnapin Microsoft.Exchange.Management.Powersh
Use the PowerShell command to query Active Directory for a long time without logging on to the computer account. This article takes 60 days as an example, you can modify as needed.The following script is given:# this PowerShell Command would query Active Directory and return the computer accounts which has not logged for the past# days. can easily change the number of days from the number of your choosing. Lastlogondate is a Human# Readable conversion of the
achieved.
PowerShell in the Get-aduser can query a lot of information can refer to the following article:
http://social.technet.microsoft.com/wiki/contents/articles/12037. Active-directory-get-aduser-default-and-extended-properties.aspx
The following describes using PowerShell queries to specify the creation time of all accounts in the OU \sid\ last modified password time \ Last logon time, cmdlet as follows:Get-aduser-searchbase ' ou=user,ou=compay1,dc=domain,dc=com '-filter *-properties *
2003 and Windows NT4. There is no domain-wide activation capability within this level. This mode is only used when the NT4 domain control is upgraded to a Windows2003 domain control
4:windows Server 2003 mode. All domain controllers in the domain can be Windows 2003 and Windows2008 only. The features supported include:
Netdom.exe the domain controller rename feature provided by the
Updates the logon timestamp. The lastLogonTimestamp property is up
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.