Active Directory, Domain Controller, PowerShell, Windows Server

How to check Active Directory user account created date

Here’s the PowerShell command:

Get-ADUser <UserName> -Properties whenCreated | Format-List Name,whenCreated

or 
Get-ADUser -Filter * -Properties * | Select Name, whenCreated, whenChanged, LastlogonDate

 

In the Active Directory 

Go to account properties > Attribute Editor > check for “whenCreated” attribute.

Domain Controller, Windows Server

Simple Guide : How to Rename Domain Name in Windows Server 2012?

For Server Admin who familiar with Windows Server 2000 & 2003, you may be still remember about RENDOM utility, which is this use to rename Windows 2000 @ 2003 domain name and have to install manually.

But in Windows Server 2012 domain you don’t have to separately install “Rendom” utility.

It gets installed as part of “Active Directory Domain Services” role when you promote a server to the DC role. And It can be found here: %windir%\system32\rendom.exe.

For this time Simple Guide, I will show you all how to rename domain name in Windows Server 2012, the process is straightforward.. but as usual.. backup any necessary information @ Server before you proceed & I always advise especially to my students, please do this exercises in LAB Environment (Hyper-V).  Don’t simply take any risk by doing this is a production environment unless you have to!!.

For this exercises, I’m using MCT courseware from 20410B (Installing and Configuring Windows Server 2012).

The existing domain is ADATUM.COM and I will rename it to CPX.LOCAL.

So, let get started…

1 – Open your System Properties and check your existing domain name, if you see from my Windows Server 2012 system properties, my existing domain name is Adatum.com. This will be changed to cpx.local in the short while.

1

Continue reading “Simple Guide : How to Rename Domain Name in Windows Server 2012?”

Domain Controller, Windows Server

Simple Guide : How to Rename Server 2012 AD Host Name?

1 – Here what I have is a Server 2012 call LON-DC1.adatum.com, and i going to rename it to MIZI01.cpx.local.. this Windows Server 2012 previous domain name was adatum.com and if you want to know how to change domain name, please refer to my last post here

https://gayanstechblog.wordpress.com/2018/08/14/simple-guide-how-to-rename-domain-name-in-windows-server-2012/

 

1

2 – Next, open CMD.. and this is the SYNTAX : netdom computername <currentDC FQDN> /add:<newDCName FQDN> 

— so in your cmd, type netdom computername LON-DC1.adatum.com /add:MIZI01.cpx.local

2

Continue reading “Simple Guide : How to Rename Server 2012 AD Host Name?”

DHCP, Windows Server

How to Migrate DHCP from Windows Server 2012 R2 to Server 2016

Migrating a DHCP from Server 2012 R2 to Server 2016 involves only two commands. The first command is to export the DHCP data and is run on Server 2012 R2. The second command imports the DHCP data and it is run on the Windows 2016 server.

The following steps illustrate how to use those two commands.

Import and Export DHCP Data

1. Log in with an administrator account to the Windows Server 2012 R2 system.

2. Open Powershell and then type in the following command:

Export-DhcpServer -File C:\DHCPdata.xml -Leases -Force -ComputerName old.network.local –Verbose

3. Copy the file C:\DHCPdata.xml the Windows Server 2016 system.

4. Install and configure the DHCP role on Server 2016 (Same Server 2012 R2 installation steps, Check my related article on DHCP Server 2012 R2 for help).
Continue reading “How to Migrate DHCP from Windows Server 2012 R2 to Server 2016”

Frewall, GPO, Remote Desktop, Uncategorized, Utilities, Windows, Windows Server

How do I enable Remote Desktop connections to Windows using Group Policy on a Windows Server domain?

A. With the rename of Terminal Services to Remote Desktop Services in Server, you also have new locations for the Group Policy settings to enable Remote Desktop.

  1. Open the Group Policy Object (GPO) you’ll use for the remote desktop settings.
  2. Navigate to Computer Configuration, Policies, Administrative Templates, Network, Network Connections, Windows Firewall, Domain Profile.
  3. Double-click Windows Firewall: Allow inbound Remote Desktop exceptions.
  4. Set this to Enabled and add the addresses that can connect. This could be * for all IP addresses, specific subnets, or localsubnet for only the local subnet.
  5. Click OK.
  6. Navigate to Computer Configuration, Policies, Administrative Templates, Windows Components, Remote Desktop Services, Remote Desktop Session Host, Connections.
  7. Double-click Allow users to connect remotely using Remote Desktop Services, set it to Enabled, then click OK.
  8. Close the Group Policy object and make sure it’s linked to the required locations.

Below is the report of my GPO that enables Remote Desktop. It will also enable Remote Desktop on Windows XP, Windows Server 2003, and later systems.

GPO to enable Remote Desktop