Hello,
You do not mention which type of activation you are using. I suspect KMS?
since you mention 170 days it appears to be AD, Token or KMS.
This info is in the Event logs see the following link. (Time to expiration in minutes should show this) https://learn.microsoft.com/en-us/windows-server/get-started/activation-troubleshoot-kms-general
There may be WMI methods to query as well.
you can query the days remaining by using: cscript slmgr.vbs /xpr >act.txt
But if this KMS why are the machines not automatically activating?
If it's not KMS activation what type of activation is it?
Darrell