
Explanation:

Explanation
* Set-AzureDataDisk
Sets the host-cache mode on an existing data disk object.
* Example:
This command gets the "MyVM" virtual machine running on the "myservice" cloud service, and then sets the data disk at LUN 2 of the virtual machine to use Nonehost caching.
Windows PowerShell
C:\PS>Get-AzureVM "myservice" -name "MyVM" | Set-AzureDataDisk -LUN 2 -
HostCachingNone| Update-AzureVM
* Set-AzureDataDisk Parameter: -HostCaching<String>
Sets the host level caching settings of the disk. Possible values are: None, ReadOnly and
ReadWrite ().
When you setup a data disk on a virtual machine, you get three host caching choices:
The purpose of a cache is to cache data to be read as reading from a cache is faster than reading from a disk.
There is no performance benefit in caching the log files as these will not be re-read by the application. Therefore, we need the logs to be written directly to disks rather than being written to cache first then disk (Read) or written to the cache only (Read/Write).