HiveBrain v1.2.0
Get Started
← Back to all entries
patternsqlMinor

What will be the initial size of my tempdb data file(s) after restart?

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
afterthefiletempdbwhatrestartsizewillinitialdata

Problem

sys.database_files and sys.sysfiles report on size, but that's just the current size of the file. Is there a way to find out what the initial size of the tempdb datafiles will be after it's recreated during a system restart?

Solution

Looks like it's

select name, file_id, size
from sys.master_files
where database_id = 2
and type = 0


(If necessary, the first datafile will be increased to the size of the model database).

Code Snippets

select name, file_id, size
from sys.master_files
where database_id = 2
and type = 0

Context

StackExchange Database Administrators Q#49339, answer score: 5

Revisions (0)

No revisions yet.