Error Restoring SQL Database

● Ian Grieve ●  ● 3 Comments   ● 

I was in the process of building a virtual machine to do a test upgrade of Microsoft Dynamics GP for a client when I got this error message;

Restore failed for Server. (Microsoft.SqlServe.SmoExtended) Additional information - System.Data.SqlClient.SqlError: Directory lookup for file "e:\SQL Server\Data\GPSGPNLDat.mdf" failed with the operating system error 3(failed to retrieve text for this error. Reason 15105). (Microsoft.SqlServer.Smo)

I know things go wrong and I don’t mind error messages telling me that they have gone wrong; in fact, a good error with details is a good thing to see when there is a problem. But I do mind when the error message doesn’t actually tell me anything (one company I worked with produced error code 0 for every single error which everyone hated but it took about five years before the error handler got fixed to return the real error).

I did a little digging and it turned out to be a nice easy fix; when the VM was created the HDD space allocated hadn’t been big enough for the size of the databases being restored to it. I added a new (larger) virtual HDD to the VM and was able to restore the databases without further error.

● Categories: Microsoft, SQL Server ● Tags: , ,  ● Permalink ● Shortlink ●