Sometimes we experience an unexpected shutdown in our VMs in Azure, to troubleshoot that I recommend these steps.
Open the event viewer
and filter the System Windows Log for these events number
6005,6006,6008,6009, 1074, 1076
the current event ids show you all the VM reboots, the service restarts (6…) and the shutdown types (1074)
When you have the message then check the shutdown reason code in the description and in the site below you can find the description
https://msdn.microsoft.com/en-us/library/aa376885%28VS.85%29.aspx?f=255&MSPPError=-2147217396
When you have the exact time, you can check the Application and the other Windows logs for specific errors.
Sometime the restart is due by the Window Update service and the best way to check this is looking in the Windows update logs.
You can find this log into C:\Windows\WindowsUpdate.log
In this log you will find any operation performed by the update service, even the restarted.
If you like to disable the automatic restart, you can do that opening the Local Group Policy Editor.
Search for Edit group policy
Navigate into:
Computer Configuration\Administrator Templates\Windows Components\Windows Update
Enable the No auto-restart policy as below.