Find duplicate VM UUID’s

As I created a script to gather all VM-s and their UUID, the purpose was to find all the duplicate UUID’s if there where any.
While my script was running I remembered something to find out the duplicates.
Before I forget I tought to put it here so it’s easily to find again

import-csv file.csv | Group-Object -Property UUID -noelement | ?{$_.Count -gt 1}?{$_.Count -gt 1}

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.