The Page 0 of the data file is the file
header page. It holds the various attributes of the database file required for
proper functioning of database. Let’s use the DBCC page command to see what it
contains. I will not be going into the page header section here as we have
already covered that. However would like to mention that m_type is
15 for file header page, which means that the page is of type file
header. We will focus on the actual data in the file header page. Executing DBCC
PAGE against the Page database created previously
use Page
go
DBCC TRACEON (3604)
DBCC PAGE (Page,1,0,3)
DBCC execution completed. If DBCC printed error
messages, contact your system administrator.
PAGE: (1:0)
BUFFER:
BUF @0x0000000084FD3480
bpage = 0x000000008488C000 bhash =
0x0000000000000000 bpageno = (1:0)
bdbid = 7 breferences
= 0 bcputicks = 0
bsampleCount = 0 bUse1 =
40165 bstat = 0xc00009
blog = 0x21432159 bnext =
0x0000000000000000
PAGE HEADER:
Page @0x000000008488C000
m_pageId = (1:0)
m_headerVersion = 1 m_type = 15
m_typeFlagBits = 0x0 m_level =
0 m_flagBits = 0x200
m_objId (AllocUnitId.idObj) = 99 m_indexId
(AllocUnitId.idInd) = 0 Metadata: AllocUnitId = 6488064
Metadata: PartitionId = 0 Metadata:
IndexId = 0 Metadata: ObjectId = 99
m_prevPage = (0:0) m_nextPage =
(0:0) pminlen = 0
m_slotCnt = 1 m_freeCnt =
7018 m_freeData = 1172
m_reservedCnt = 0 m_lsn =
(0:0:1) m_xactReserved = 0
m_xdesId = (0:0)
m_ghostRecCnt = 0 m_tornBits = -1004595054
Allocation Status
GAM (1:2) = ALLOCATED SGAM (1:3) =
NOT ALLOCATED PFS (1:1) = 0x44 ALLOCATED 100_PCT_FULL
DIFF (1:6) = CHANGED ML (1:7) =
NOT MIN_LOGGED
File Header Data:
Record Type = PRIMARY_RECORD Record
Attributes = NULL_BITMAP VARIABLE_COLUMNS
Record Size = 1076
Memory Dump @0x000000000E5CA060
0000000000000000: 30000800 00000000 2f000000
00000000 †0......./.......
0000000000000010: 2e007e00 7e008000 82008600
8a008e00 †..~.~.......
0000000000000020: 92009c00 a600b000 b000b400
b800bc00 †..¦.°.°.´.¸.¼.
0000000000000030: c000ca00 e600f000 fa000401
14011e01 †À.Ê.æ.ð.ú.......
0000000000000040: 2e013201 3c013c01 4e015e01
5e015e01 †..2.<.<.N.^.^.^.
0000000000000050: 5e015e01 5e015e01 6e016e01
6e017801 †^.^.^.^.n.n.n.x.
0000000000000060: 82019e01 a801b801 d401dc01
3404961a †..¨.¸.Ô.Ü.4..
0000000000000070: 7ca40501 9943823f d790566f
93f70100 †|¤...C?×.Vo÷..
0000000000000080: 01008001 00000005 00008000
00000000 †................
0000000000000090: 00000000 00000000 00000000
00000000 †................
00000000000000A0: 00000000 00000000 00000000
00000000 †................
00000000000000B0: 80010000 00000000 ffffffff
00020000 †........ÿÿÿÿ....
00000000000000C0: 00000000 00000000 00000000
00000000 †................
00000000000000D0: 00000000 00000000 00000000
00000000 †................
00000000000000E0: 00000000 00000000 00000000
00000000 †................
00000000000000F0: 00000000 00000000 00000000
00000000 †................
0000000000000100: 00000000 00000000 00000000
00000000 †................
0000000000000110: 00000000 00000000 00000000
00008f5d †...............]
0000000000000120: 0f808878 c3498c98 186bae39
ee440000 †...xÃI..k®9îD..
0000000000000130: 00000000 00000000 00000000
50006100 †............P.a.
0000000000000140: 67006500 5f004400 61007400
61000000 †g.e._.D.a.t.a...
0000000000000150: 00000000 00000000 00000000
00000000 †................
0000000000000160: 00000000 00000000 00000000
00000000 †................
0000000000000170: 00000000 00000000 00000000
00000000 †................
0000000000000180: 00000000 00000000 00000000
00000000 †................
0000000000000190: 00000000 00000000 00000000
00000000 †................
00000000000001A0: 00000000 00000000 00000000
00000000 †................
00000000000001B0: 00000000 00000000 00000000
00000000 †................
00000000000001C0: 00000000 00000000 00000000
00000000 †................
00000000000001D0: 00000000 00000000 00000000
00000000 †................
00000000000001E0: 00000000 00000000 00000000
00000000 †................
00000000000001F0: 00000000 00000000 00000000
00000000 †................
0000000000000200: 00000000 00000000 00000000
00000000 †................
0000000000000210: 00000000 00000000 00000000
00000000 †................
0000000000000220: 00000000 00000000 00000000
00000000 †................
0000000000000230: 00000000 00000000 00000000
00000000 †................
0000000000000240: 00000000 00000000 00000000
00000000 †................
0000000000000250: 00000000 00000000 00000000
00000000 †................
0000000000000260: 00000000 00000000 00000000
00000000 †................
0000000000000270: 00000000 00000000 00000000
00000000 †................
0000000000000280: 00000000 00000000 00000000
00000000 †................
0000000000000290: 00000000 00000000 00000000
00000000 †................
00000000000002A0: 00000000 00000000 00000000
00000000 †................
00000000000002B0: 00000000 00000000 00000000
00000000 †................
00000000000002C0: 00000000 00000000 00000000
00000000 †................
00000000000002D0: 00000000 00000000 00000000
00000000 †................
00000000000002E0: 00000000 00000000 00000000
00000000 †................
00000000000002F0: 00000000 00000000 00000000
00000000 †................
0000000000000300: 00000000 00000000 00000000
00000000 †................
0000000000000310: 00000000 00000000 00000000
00000000 †................
0000000000000320: 00000000 00000000 00000000
00000000 †................
0000000000000330: 00000000 00000000 00000000
00000000 †................
0000000000000340: 00000000 00000000 00000000
00000000 †................
0000000000000350: 00000000 00000000 00000000
00000000 †................
0000000000000360: 00000000 00000000 00000000
00000000 †................
0000000000000370: 00000000 00000000 00000000
00000000 †................
0000000000000380: 00000000 00000000 00000000
00000000 †................
0000000000000390: 00000000 00000000 00000000
00000000 †................
00000000000003A0: 00000000 00000000 00000000
00000000 †................
00000000000003B0: 00000000 00000000 00000000
00000000 †................
00000000000003C0: 00000000 00000000 00000000
00000000 †................
00000000000003D0: 00000000 00000000 00000000
00000000 †................
00000000000003E0: 00000000 00000000 00000000
00000000 †................
00000000000003F0: 00000000 00000000 00000000
00000000 †................
0000000000000400: 00000000 00000000 00000000
00000000 †................
0000000000000410: 00000000 00000000 00000000
00000000 †................
0000000000000420: 00000000 00000000 00000000
00000000 †................
0000000000000430: 00000000
††††††††††††††††††††††††††††....
BindingID =
a47c1a96-0105-4399-823f-d790566f93f7 FileIdProp = 1
FileGroupId = 1 Size =
384 MaxSize = 1280
Growth = 128 Perf =
0 BackupLsn = (0:0:0)
FirstUpdateLsn = (0:0:0)
OldestRestoredLsn = (0:0:0) FirstNonloggedUpdateLsn = [NULL]
MinSize = 384 Status =
0 UserShrinkSize = 65535
SectorSize = 512 MaxLsn =
(0:0:0) FirstLsn = (0:0:0)
CreateLsn = (0:0:0)
DifferentialBaseLsn = (0:0:0)
DifferentialBaseGuid =
00000000-0000-0000-0000-000000000000 FileOfflineLsn = (0:0:0)
FileIdGuid =
800f5d8f-7888-49c3-8c98-186bae39ee44 RestoreStatus =
0
RestoreRedoStartLsn = (0:0:0)
RestoreSourceGuid = 00000000-0000-0000-0000-000000000000
HighestUpdateLsn = [NULL]
ReplTxfTruncationLsn = [NULL] TxfBackupLsn = [NULL]
TxfLogContainerSize = [NULL]
MaxLsnBranchId = 00000000-0000-0000-0000-000000000000
SecondaryRedoStartLsn = [NULL]
SecondaryDifferentialBaseLsn = [NULL]
ReadOnlyLsn = (0:0:0) ReadWriteLsn
= (0:0:0) RestoreDifferentialBaseLsn = (0:0:0)
RestoreDifferentialBaseGuid =
00000000-0000-0000-0000-000000000000
RestorePathOrigin
m_fSeqNo = 0
m_blockOffset = 0 m_slotId = 0
m_guid =
00000000-0000-0000-0000-000000000000
DatabaseEncryptionFileState.m_maxScannedPage =
0 DatabaseEncryptionFileState.m_keyId = 0
FCBFileDEK
m_dbeStatusBits = 0 m_dtCreated
= 1900-01-01 00:00:00.000
m_dtLastRegenerated = 1900-01-01
00:00:00.000
m_dtLastModified = 1900-01-01
00:00:00.000 m_dtLastSet = 1900-01-01
00:00:00.000
m_dtOpened = 1900-01-01 00:00:00.000 m_algId =
0 m_algId = 0
m_dwBitLen = 0
m_cbThumbprint = 0 m_rgbThumbprint = 0x
DBCC execution completed. If DBCC printed
error messages, contact your system administrator.
Some of the important fields to note here
are
BindingID: Is the unique identifier to bind files
to the database. It is my observation that all the files in the database have
the same unique bindingid.
FileGroupId: As the name suggests, this identifies
the filegroup to which this file belongs.
Size: Size of the data file. In this case it is
384 Pages in size. (384 * 8192 (page size) = 3145728 bytes = 3MB).
MaxSize: The maximum size to which file can grow.
In this case 1280 pages = 1280 * 8192 = 10MB. maxSize of -1 means growth is
unlimited.
Growth: The size by which the file will grow from
its initial size of 3MB in case additional space it required. It can only grow
till it reaches 10MB, the maxSize. In this case growth is 128 pages = 128 * 8192
= 1MB
SectorSize: Disk sector size. In our case it is
512.
FileGuid: This is nothing but a unique identifier
assigned to each file.
DifferantialBaseGuid: This is a unique identifier
of the base backup on which a differential backup would be based.
DifferentialBaseLsn: Data extents changed after this LSN will be included in a differential backup.