Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm getting this error

Msg 3201, Level 16, State 1, Server server\instance, Line 1
Cannot open backup device '\\server\share\database.bak'. Device error or device off-line. See the SQL Server error log for more details.
Msg 3013, Level 16, State 1, Server server\instance, Line 1
BACKUP DATABASE is terminating abnormally.
share|improve this question

migrated from stackoverflow.com Jul 25 '11 at 9:02

This question came from our site for professional and enthusiast programmers.

    
I would recommend seeing the SQL Server error log for more details. –  cularis Jul 25 '11 at 7:24
    
I don't think SQL server can cope with paths like \\server, you need to mount the folder on the server as a local drive letter or copy the backup file to the machine sql server is running on. –  Ian Ringrose Jul 25 '11 at 8:50
add comment

1 Answer

SQL Server does happily backup to UNC paths - I backup to UNCs extensively for SQL Server 2000 and later. For SQL Server 2005 or later I use Ola's excellent backup (and db maintenance) scripts (http://ola.hallengren.com/)

I'd suggest the first thing you need to do is verify the device is online (\server) by either pinging it, or browsing to it. Then you need to check the folder is available (\share)

If they are, then you need to check that the SQL Server service account (the database engine) has access to all of that. When you backup or restore, it'll use the service account that SQL Server itself runs under. This is where domain service accounts are far easier to use that Local System or Network - as well as being more secure etc etc

Just off topic, backing up to a network device is typically slower than backing up to "local" discs, whether locally attached or SAN. This means that you restores will be slower too - something to bear in mind, or test at least. A happy compromise might be to backup locally, have a separate process to copy off to somewhere safer, and keep on the server for 24/48 hours or so.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.