May 22, 2014 at 10:39 pm
SELECT TextData, Duration Duration, Reads, Writes, CPU, StartTime,EndTime into Trace_20140522190546
FROM fn_trace_gettable('E:\Trace\Trace_20140522190546.trc',1)
GO
Msg 568, Level 16, State 18, Line 1
Encountered an error or an unexpected end of trace file 'E:\Trace\Trace_20140522190546.trc'.
The statement has been terminated.
why and how to resolve
May 23, 2014 at 1:22 am
Look s like the trace file is corrupted.
DId you try to open it with profiler?
-- Gianluca Sartori
May 23, 2014 at 2:41 am
I am using express edition so there is no profiler to load the trace file 🙁
May 23, 2014 at 2:59 am
The trace is still running. Stop it first, then load the data.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
May 23, 2014 at 3:09 am
I switched on the trace of 10 hour since the hits are going to small in the database.After 98 MB it automatically stopped i dont know why?
It has passed 10 hours after that only i am reading the trace.
May 23, 2014 at 3:13 am
Check in SQL that the trace is not running. That is exactly the error you get if you try reading a trace file that is still being written to.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
May 23, 2014 at 8:50 am
actually beyond 98 mb the trace stopped.
i mark the trace for 10 hour , it ran only for 7 hours which reached 98 mb after that there is no entry i dont know why it stopped
I followed ur link only Gail
instead of
SET @EndTime = DATEADD(mi,30,getdate())
as
SET @EndTime = DATEADD(mi,600,getdate())
May 23, 2014 at 10:12 am
yuvipoy (5/23/2014)
actually beyond 98 mb the trace stopped.i mark the trace for 10 hour , it ran only for 7 hours which reached 98 mb after that there is no entry i dont know why it stopped
I followed ur link only Gail
instead of
SET @EndTime = DATEADD(mi,30,getdate())
as
SET @EndTime = DATEADD(mi,600,getdate())
The trace may have stopped but you still need to close it in order for it to release your trace file.
May 24, 2014 at 7:05 am
Lynn Pettis (5/23/2014)
The trace may have stopped but you still need to close it in order for it to release your trace file.
Atcually i restarted my pc and also moved the trace file from the place.
May 26, 2014 at 7:16 am
Lynn Pettis (5/23/2014)
The trace may have stopped but you still need to close it in order for it to release your trace file.
How to close the trace in order to release if i have not restarted my PC ?
Atleast i can use this for upcoming traces
May 26, 2014 at 10:02 am
yuvipoy (5/26/2014)
Lynn Pettis (5/23/2014)
The trace may have stopped but you still need to close it in order for it to release your trace file.
How to close the trace in order to release if i have not restarted my PC ?
Atleast i can use this for upcoming traces
Books Online (BOL) is your friend. You may want to learn how to use it.
IIRC, F1 on your keyboard while in SSMS will bring it up.
Viewing 11 posts - 1 through 10 (of 10 total)
You must be logged in to reply to this topic. Login to reply