When restoring a backup, how do I disconnect all active connections?

后端 未结 10 1072
失恋的感觉
失恋的感觉 2020-12-22 15:26

My SQL Server 2005 doesn\'t restore a backup because of active connections. How can I force it?

10条回答
  •  情深已故
    2020-12-22 16:04

    Restarting SQL server will disconnect users. Easiest way I've found - good also if you want to take the server offline.

    But for some very wierd reason the 'Take Offline' option doesn't do this reliably and can hang or confuse the management console. Restarting then taking offline works

    Sometimes this is an option - if for instance you've stopped a webserver that is the source of the connections.

提交回复
热议问题