DEFINITIONS

Definitions More Info.
Definition ID608
TitleSQL
CategoryNOTES
DefinitionTempDb de sorun MDAC ile cozulen
Definition Descriptionhttps://social.msdn.microsoft.com/forums/sqlserver/en-US/8ceb82fd-fc56-4a99-9317-590cca683f2b/sql-server-not-starting-tempdb-path-updated-to-wrong-path Aşağıda DAC user ile izlediğimiz yöntemin hem ingilizce açıklması hem de türkçesi bulunmaktadır. Öncelikle SQL Server single user mode da DAC açmak istiyorsak Windows a mutlaka MSSQLSERVER service log on verisi ile giriş yapmalıyız. sqlserver configuration manager dan MSSQLSERVER servisini açıp, oradan LOG ON tabın'ndaki log on bilgisine bakın. Sonra o log on user ile Windows a bağlanın ve 2.3 steplerdeki aşamalara geçin.Management stüdyada sadece queryanalyzer açıp tempdb yerlerini belirleyin. One important point the user who is admin user always connecting as DAC admin user; is mssqlserver service user,because its the first user which is connectting at the first time;from the sqlserver configuration manager,check the mssqlserver service log on user,then you should log on windows with the same service user name account which is already admin!!! Otherwise you cannot connect with any other systemadmin user as DAC Tempdb is a system db which SQL will always attempt to recover. The first thing you have to do is specify trace flag 3608 to bypass recovery on this db, otherwise you won't actually be able to log in to make any modifications. I would advise against modifying the service startup properties. 1. Start SQL Server from a DOS session with minimal config and trace flag to bypass system db recovery (other than master): NET START MSSQLSERVER /f /T3608 If your SQL instance is not the default instance, replace MSSQLSERVER with MSSQL$ where is the instance name. When the SQL Server is started, you'll see the following: The SQL Server () service is starting. The SQL Server () service was started successfully. Then bring up the SQL Server error log and look for the following: 2007-10-04 14:20:18.92 Server Dedicated admin connection support was established for listening locally on port 2168. 2. Connect locally from the DOS prompt using the dedicated admin connection (DAC): sqlcmd -S tcp:127.0.0.1, where is the port number for the dedicated admin connection. If you connect the prompt changes to: 1> 3. Then run the alter commands to modify the location of tempdb: ALTER DATABASE tempdb MODIFY FILE ( NAME = 'tempdev' , FILENAME = 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\tempdb.mdf' ) GO ALTER DATABASE tempdb MODIFY FILE ( NAME = 'templog' , FILENAME = 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\tempdb.ldf' ) GO Change the paths etc as appropriate if your locations are different. Hit return after each alter statement. Then type GO and hit return. You should get a message like the following after each change (after executing the GO command): The file "templog" has been modified in the system catalog. The new path will be used the next time the database is started. Then type EXIT and hit return to quit sqlcmd. 4. Stop SQL Server: NET STOP MSSQLSERVER Change the service name as described in point 1. if necessary. 5. Start SQL Server normally.
RecordBycunay
Record Date20-12-2014 07:03:34
Düzenle
Kopyala
Sil