新聞中心
當(dāng)SQL Server因系統(tǒng)資源不足,或其它異常導(dǎo)致無法建立數(shù)據(jù)庫連接時, 可以使用系統(tǒng)預(yù)留的DAC連接到數(shù)據(jù)庫,進(jìn)行一些問題診斷和故障排除。DAC只能使用有限的資源。請勿使用DAC運行需要消耗大量資源的查詢,否則可能發(fā)生嚴(yán)重的阻塞??稍诼?lián)機幫助中搜索DAC。

南京網(wǎng)站建設(shè)公司創(chuàng)新互聯(lián),南京網(wǎng)站設(shè)計制作,有大型網(wǎng)站制作公司豐富經(jīng)驗。已為南京近千家提供企業(yè)網(wǎng)站建設(shè)服務(wù)。企業(yè)網(wǎng)站搭建\成都外貿(mào)網(wǎng)站制作要多少錢,請找那個售后服務(wù)好的南京做網(wǎng)站的公司定做!
建議使用命令行下的sqlcmd連接進(jìn)去,因為占用的資源更少,連接方法:開始 --> 運行 --> cmd 輸入SQLCMD -E -SMQLinstance1 -A&(說明,-A即為指定DAC,其它參數(shù)見《聯(lián)機幫助》)。
使用SQL Server Management Studio建立DAC連接時,服務(wù)器一欄輸入:admin:主機名\實例名。
如果連接報錯: “不支持管理員連接”,英文為:"Cannot connect to admin:SQLSERVER2008R2."
原因為:This is because you can't connect to the DAC in object explorer. You can however connect to it from a query window from management studio click
如果連接報錯:A connection was successfully established with the server, but then an error occurred during the login process. (provider: TCP Provider, error: 0 - The specified network name is no longer available.) (Microsoft SQL Server, Error: 64) 已成功與服務(wù)器建立連接,但是在登錄過程中發(fā)生錯誤。
原因為已經(jīng)存在一個活動的DAC連接,不允許建立第二個DAC連接。 這條描述可以在ErrorLog中看到。
檢查當(dāng)前已建立的的DAC連接命令如下:
- SELECT t2.session_id
- FROM sys.tcp_endpoints as t1 JOIN sys.dm_exec_sessions as t2
- ON t1.endpoint_id =t2.endpoint_id
- WHERE t1.name='Dedicated Admin Connection'
- SELECT t2.session_id
- FROM sys.tcp_endpoints as t1 JOIN sys.dm_exec_sessions as t2
- ON t1.endpoint_id = t2.endpoint_id
- WHERE t1.name='Dedicated Admin Connection'
除本地支持DAC連接外,也可以打開遠(yuǎn)程DAC連接功能, 打開命令如下:
- sp_configure 'remote admin connections', 1;
- GO
- RECONFIGURE;
- GO
- sp_configure 'remote admin connections', 1;
- GO
- RECONFIGURE;
- GO
本文就介紹到這里,如果想了解更多關(guān)于SQL Server數(shù)據(jù)庫的文章,可以到這里:http://database./sqlserver/。
網(wǎng)站欄目:淺析SQLServer數(shù)據(jù)庫專用管理員連接DAC的使用
網(wǎng)站路徑:http://m.fisionsoft.com.cn/article/djipcdh.html


咨詢
建站咨詢
