Forum Discussion
PuneetAg_
May 15, 2023Copper Contributor
How to use Log Analytics Workspace to identify Personal VM's which are not in use from last 30d
We want to identify and delete personal VM's which do not have any logins from their assigned users
JasonMasten
Microsoft
May 16, 2023Hi PuneetAg_. This isn't exactly what you asked for but figured it could help. I wrote a solution to help a customer remove session hosts in a personal host pool automatically based on their desired expiration in days: https://github.com/jamasten/RemoveExpiredAvdPersonalSessionHosts/tree/main
Be sure to test the code on test host pool and validate the results before implementing in production. If you run into any problems, please post an issue on my repo.
Be sure to test the code on test host pool and validate the results before implementing in production. If you run into any problems, please post an issue on my repo.