question

JamesN-7426 avatar image
0 Votes"
JamesN-7426 asked JamesN-7426 edited

DC cannot ping its client computer by Hostname but it can ping by IP address

I have limited experience with Windows server and Domain controller, so thank you for being patient with me.
I search on this forum but not quite find the correct answer to my case either. Here is my sitution:

1/ Windows Server 2019 Std version, running Domain controller and DNS server name DC-01 in the Office on 192.168.100.0/24 network
2/ A desktop (name DSKT-01) running Windows 10 Pro at Home-Office on 10.10.100.0/24 network
3/ The Office and Home is Site-to-Site VPNed.
4/ The DSKT-01 joined the DC-01 all good.

Few days ago, I needed to reinstall the Desktop, then name it the same as previously (DSKT-01). But somehow it has lost the connection to DC-01. I then removed the "previous" DKST-01 computer from DC-01 Active Directory; Created the new computer and name it the same DSKT-01. Then from the DSKT-01, I can rejoined the DC-01 successfully.

However, from the DC-01, I can't ping the Desktop using its hostname as DKST-01 (was OK before the reinstallation). I can however, ping the DSKT-01 by its IP address. Everything else works except pinging the name. It said host (DSKT-01) cannot be found.

A/ What I have done:

A.1/ Delete the dns cache (ipconfig /flushdns) from both DC-01 and DSKT-01
A.2/ Update policy (gpupdate /force) on both machines
A.3/ Delete the contain of host file on DC-01 and DSKT-01


B/ Other notes:

B.1/ When I checked in the DNS server, in the Forward lookup zone, there is a record of the DSKT-01's IP address which is automatically created when joining the DKST-01 to the DC-01. But still, I cannot ping the client PC by its hostname. This bug me the most, especially it was working previously and after the reinstall, it stops

B.2/ DC-01 can ping other client computers in the same network using their Hostname.

B.3 / Other client computers in the same network with the DC-01 can ping the DSKT-01 by it hostname.


Why the DC-01 cannot ping its client "DSKT-01" by its hostname?

Anyone have any idea what I may be missing?

Thank you very much

windows-serverwindows-active-directory
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JamesN-7426 avatar image
0 Votes"
JamesN-7426 answered JamesN-7426 edited

This solve the problem:
- Delete the computer in the Domain controller and make sure no record was left behind in the DNS forward lookup zone. Restart DC
- Disjoin the client to the domain, restart the client
- Join the client to DC again.
- Check the DNS setting in the DC: If virtualization is employed, under the the virtual NIC (created by Hyper-V) where applicable to your DC/AD, one of the DNS server will have to be the DC itself (either IP address or loopback address 127.0.0.1) so that it will resolve the internal computer hostnames. The other DNS could point to other DNS server (to PiHole server in our case).
- So, DNS1: the DC
- DNS 2: Pi-hole server

Now it works again!





5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

DSPatrick avatar image
0 Votes"
DSPatrick answered

Please run;

Dcdiag /v /c /d /e /s:%computername% >c:\dcdiag.log
repadmin /showrepl >C:\repl.txt
ipconfig /all > C:\dc1.txt
ipconfig /all > C:\dc2.txt
ipconfig /all > C:\problemworkstation.txt

then put unzipped text files up on OneDrive and share a link.





5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JamesN-7426 avatar image
0 Votes"
JamesN-7426 answered JamesN-7426 edited

@DSPatrick: Do you want me to run these commands in the Windows Server 2019 or in the client computer?

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

DSPatrick avatar image
0 Votes"
DSPatrick answered

Each domain controller and the problem member.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JamesN-7426 avatar image
0 Votes"
JamesN-7426 answered

@DSPatrick:
ipconfig /all > C:\dc1.txt
ipconfig /all > C:\dc2.txt
Are they the same?

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

DSPatrick avatar image
0 Votes"
DSPatrick answered

One for each domain controller.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JamesN-7426 avatar image
0 Votes"
JamesN-7426 answered JamesN-7426 edited

@DSPatrick:
Please find the files per your request
We have only 1 Domain controller though
We have a PiHole DNS at 192.168.100.115
The DC is using the PiHole as DNS Forwarder

https://1drv.ms/u/s!Ak8byH0Hx08AhF9CnX5VxC2r8YPI?e=98bvb4

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

SunnyQi-MSFT avatar image
0 Votes"
SunnyQi-MSFT answered SunnyQi-MSFT commented

Hi,

Thanks for posting in Q&A platform.

Please try the following detailed steps to see if the issue can be resolved:

  1. Delete the problematic machine in AD UC

  2. Delete the corresponded resource record of this machine in DNS server zone

  3. Then, from the client side, please disjoin the domain and rejoin into the domain.

Best Regards,
Sunny


If the Answer is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@SunnyQi-MSFT:
I would do this again to ensure I didn't miss anything. Before I proceed, please confirm with me the following
1/ In the DC > Active Directory, User & Computer: Delete the client computer. Do I need to re-create this computer again in advance? Or, when I use the client to join the domain, the domain controller will automatically create the client?
2/ In the DNS server, delete this computer record in the forward lookup zone
3/ Disjoin and Rejoin the client to the Domain.

Thank you for your helps

0 Votes 0 ·

Hi,

Thank for your update. As for question 1, we don't need to recreate this computer again in DC.

Best Regards,
Sunny

0 Votes 0 ·
DSPatrick avatar image
0 Votes"
DSPatrick answered

DC-01 is multi-homed which will always cause no end to grief for active directory DNS. I did not bother to look at other files because of this. Do not install active directory domain services on hyper-v host, standup a dedicated virtual machine for this. After making corrections if problems persist then put up a new set of files to look at.

--please don't forget to Accept as answer if the reply is helpful--


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JamesN-7426 avatar image
0 Votes"
JamesN-7426 answered

@DSPatrick:
The Windows Server 2019 (AD and DNS) is installed on bare-metal server. Then, we installed Hyper-V and as a result, you see there are some virtual network card.
But the Windows server is the main OS for this server

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.