Monday, March 12, 2012

Examining event logs hangs Enterprise Manager

Anyone know a reason why trying to read the event logs hangs Enterprise Manager?
Do I have to read them threw Enterprise Manager?
Thanks,
Bryan HughesCheck to see how large your logs are. If they are too big, it may just be taking a while for them to open up. You can also open them up in notepad.|||Originally posted by Pigeon
Check to see how large your logs are. If they are too big, it may just be taking a while for them to open up. You can also open them up in notepad.

Now for the $60,000 question, where do I find the SQL Server event logs...|||Probably the best thing to do is to start a new event log. This should allow your old log to open more quickly, or you can open and edit it through another application.

Normally a new event log is started only when you stop and restart SQL Server, but there is an SQL command that will do it as well. I make the command part of my weekly maintenance so that the log never grows to big.

No, I can't remember the command right now, but if you can't find it and nobody else posts it I'll look it up at my office tomorrow.

blindman|||Originally posted by blindman
Probably the best thing to do is to start a new event log. This should allow your old log to open more quickly, or you can open and edit it through another application.

Normally a new event log is started only when you stop and restart SQL Server, but there is an SQL command that will do it as well. I make the command part of my weekly maintenance so that the log never grows to big.

No, I can't remember the command right now, but if you can't find it and nobody else posts it I'll look it up at my office tomorrow.

blindman

The command is : sp_cycle_errorlog

Default path where you would find the logs is the Logs directory in your MS SQL installation folder|||Were you talking about the event logs or the sql server logs ? If your sql server log is really big then will experience the "hang". If you don't know the location, just do a quick search on ERRORLOG.|||Thanks Enigma. Did you consult the Holy Book? ;)

blindman :cool:|||Nope .. but did see the code for sp_cycle_errorlog.
And found out an undocumented dbcc command (not there in the Holy Book)

dbcc errorlog|||Well, what does it do?

...and dude, I gotta tell ya... your Icon is FREAKIN ME OUT!

blindman|||Both cycle the log.|||Originally posted by blindman
Well, what does it do?

...and dude, I gotta tell ya... your Icon is FREAKIN ME OUT!

blindman
Well .. the code for the stored proc sp_cycle_errorlog is :

create procedure sp_cycle_errorlog -- 1997/06/24
as
if (not (is_srvrolemember('sysadmin') = 1)) -- Make sure that it is the SA executing this.
begin
raiserror(15247,-1,-1)
return(1)
end

dbcc errorlog
return (0)

So ultimately its dbcc errorlog that is recycling the logs|||Thanks for the help! You guys rock...|||Originally posted by blindman
Well, what does it do?

...and dude, I gotta tell ya... your Icon is FREAKIN ME OUT!

blindman

How can you see it if you're a blindman?

I thought you were answer questions from a brail monitor or something...

and DUDE...where's the dark planet?|||My seeing eye dog translates text from the screen into a series of binary woofs indicating the ASCII codes of the characters. And ever since Enigma changed his Icon, Fido keeps trying to bury my monitor in the back yard.

Bad DOG!

blindman|||The Dark Planet is a dark corner of the Milky Way Galaxy.

LOL :GRIN:

BTW if you want to know where I am from ... I am from Mumbai , India|||To paraphrase Churchill, do you contain a riddle wrapped in a mystery?|||Only thing I would say .. I am a puzzle in myself...

No comments:

Post a Comment