Hello @Pookat, Sanal (MBHC 21) ,
Thanks for reaching out to Microsoft Q&A.
To identify Ephemeral vs Non-Ephemeral VMs you can use the attribute called "Ephemeral Os disk".
If the VM is ephemeral : Ephemeral OS Disk attribute value will be "OS Cache"
If the VM is non-ephemeral: Ephemeral OS Disk attribute value will be "N/A"
Ephemeral VM:
Non-Ephemeral VM:
////////////////////////////////////////////
Using Azure PowerShell how to differentiate Ephemeral vs Non-Ephemeral
For Ephemeral:
(Get-AzureRmVM -ResourceGroupName ephemeraldemo -Name ephemeralvm).StorageProfile.OsDisk.Caching
Output: ReadOnly
For Non-Ephemeral
(Get-AzureRmVM -ResourceGroupName ephemeralnondemo -Name ephemeralnondemo).StorageProfile.OsDisk.Caching
Output: ReadWrite
For Ephemeral
(Get-AzureRmVM -ResourceGroupName ephemeraldemo -Name ephemeralvm).StorageProfile.OsDisk.DiffDiskSettings
Output: Local
For Non-Ephemeral
(Get-AzureRmVM -ResourceGroupName ephemeralnondemo -Name ephemeralnondemo ).StorageProfile.OsDisk.DiffDiskSettings
Output: N/A
/////////////////////////////
Additional details:
https://learn.microsoft.com/en-us/azure/virtual-machines/ephemeral-os-disks
Kindly let us know if you have additional queries.