Link to home
Start Free TrialLog in
Avatar of brassmonkeyboy
brassmonkeyboy

asked on

Suspect Table, Inaccessible Files?

Hi,

I have a database that works fine on SQL 2000 Server on my web server.  However, when I copy the .MDF and .LDF files to my test server on my personal laptop, the database is labeled 'Suspect', and when I try to access it it gives the following error:

"Database 'msm' cannot be opened due to inaccessibly files or insufficient memory or disk space. See the SQL Server errorlog for details."

I don't understand what's going on...

The following is from the errorlog:

2006-06-13 16:17:55.98 spid51    Starting up database 'msm'.
2006-06-13 16:17:55.98 spid51    udopen: Operating system error 2(The system cannot find the file specified.) during the creation/opening of physical device C:\Inetpub\wwwroot\MSSQL$ORBUSDEV\msm_Data.mdf.
2006-06-13 16:17:55.98 spid51    FCB::Open failed: Could not open device C:\Inetpub\wwwroot\MSSQL$ORBUSDEV\msm_Data.mdf for virtual device number (VDN) 1.

The file is there.  I can see it and I can browse to it.  I tried re-downloading it to my laptop with no change or improvement.

Any ideas?
Avatar of jrb1
jrb1
Flag of United States of America image

Here is some info from another post.  See if you are missing something:

Right click on the database (that you wish to recreate in test env) in the enterprise manager of the prod server.

Note the physical locations of the data files (.mdf,.ndf etc) and also the transaction log (.ldf).

Copy the .mdf and .ldf files (.ndf file also if any) to the test server in the usual location (C:\Program Files\Microsoft SQL Server\MSSQL\data)

Now go to the enterprise manager of the test server. Choose Databases->All Tasks->Attach Database.

In the Attach Database dialog, choose the location of the .MDF file. It automatically pulls up the .LDF file also (provided .ldf file is also in same location as .mdf)

Specify the name of the database in 'Attach as' field.

Also specify the database owner for this database in test server.

The database is now created in test server with all data as in production.
Avatar of brassmonkeyboy
brassmonkeyboy

ASKER

I tried the above, but to no avail.

The first time I did it it seemed to work - but when I looked at the tables, none of the tables were there.  Only the default non-user created tables.

The second time I was particularly careful to use the most updated .MDF file from my server, and it told me that "msm_Data.MDF is not a primary database file"

Any further ideas?
ASKER CERTIFIED SOLUTION
Avatar of Yurich
Yurich
Flag of New Zealand image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I did it through a database backup utilizing Force Overwrite and changing pathnames.
:) glad you got it working :)