PRB: Incorrect Log Size Reported in SEM or Performance MonitorID: Q183100
|
After truncating a very full transaction log for a database, log space reporting may be incorrect. This is true whether the log space is checked by means of SQL Enterprise Manager (SEM), Windows NT Performance Monitor, or the sp_spaceused stored procedure.
All space reporting is taken from information in the sysindexes table within the database. In most cases, this information is up to date; however, it is not guaranteed to be. Due to performance reasons, the sysindexes table is not continually updated. Updating this information is the same as updating any table in the database, and must be logged first in the transaction log. When the transaction log becomes full, updates to the sysindexes table are stopped, causing the information reported to be inaccurate.
To work around this problem, issue the following statement in the database
after truncating the log:
DBCC CHECKTABLE (syslogs)
Checking syslogs
The total number of data pages in this table is 1.
The number of data pages in Sysindexes for this table was 4. It has
been corrected to 1.
The number of rows in Sysindexes for this table was 128. It has been
corrected to 12.
*** NOTICE: Space used on the log segment is 0.00 Mbytes, 0.10.
*** NOTICE: Space free on the log segment is 2.05 Mbytes, 99.90.
Table has 12 data rows.
DBCC execution completed. If DBCC printed error messages, see your
System Administrator.
The number of rows in Sysindexes for this table was 128. It has been corrected to 12.
DBCC UPDATEUSAGE (<db_name>)NOTE: Running DBCC UPDATEUSAGE may take a great deal of time, and requires the database to be in single-user mode. DBCC UPDATEUSAGE may take a long time to run because this command updates the dpages value in sysindexes for all the tables in the database, not just the dpages value for syslogs.
Additional query words: winnt dump no_log perfmon entman ent man 1105
Keywords : SSrvAdmin SSrvEntMan
Version : WINNT:6.0,6.5
Platform : winnt
Issue type : kbprb
Last Reviewed: April 13, 1999