We are running much SQL Servers with different located ErrorLogs. Sometimes its usefull to find quick the Location from the Logs. I did a Command that gives me the Errorlog location to the Commandpromt, so i can copy them on my Client and open it in my lovely Editplus for furter troubleshooting.
Find the Location of the SQL Server Errorlog SQL Server 2005
logparser “select strcat(strcat(‘\\\\’,strcat(computername, ‘\\’)),REPLACE_CHR(REPLACE_STR(value, ‘-e’, ”), ‘:’, ‘$’)) from ‘\\MYServer\HKLM\SOFTWARE\Microsoft\Microsoft SQL Server’ where value like ‘%errorlog%’” -i:REG -recurse:10
Find the Location of the SQL Server Errorlog SQL Server 2000
logparser “select strcat(strcat(‘\\\\’,strcat(computername, ‘\\’)),REPLACE_CHR(REPLACE_STR(value, ‘-e’, ”), ‘:’, ‘$’)) from ‘\\MYServer\HKLM\SOFTWARE\Microsoft\MSSQLServer’ where value like ‘%errorlog%’” -i:REG -recurse:10

April 28th, 2009
ivolooser 




Posted in
Tags: 

