I'm running SQL Server (2012) on a Hyper-V instance. It has plenty of resources and 25% reserved of the total resources, the VHD is placed on a very fast SSD drive for quick response times.
Every now and then when the applications that use the SQL Server haven't been accessed for a while they get the error "The wait operation timed out". When reloading or retrying to access the database it seems to have been "waken up" and is as fast as ever.
Is there any way to ensure that this soft sleep mode doesn't occur on this kind of environment?
Added
Exception Details: System.ComponentModel.Win32Exception: The wait operation timed out
Best Answer
Try to execute this command:
It, incredibly, resolved the problem.
The code above its the error before the command has been executed.