Besides creating a new database and timing it, is there a simple way to determine whether or not Instant File Initialization is enabled/functioning?
(on Windows Server 2008 Enterprise)
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It only takes a minute to sign up.
Sign up to join this communityBesides creating a new database and timing it, is there a simple way to determine whether or not Instant File Initialization is enabled/functioning?
(on Windows Server 2008 Enterprise)
Using ntrights.exe
, check if the SeManageVolumePrivilege
priviledge is granted. IF you prefer a 'built in' tool, use secedit /export /areas USER_RIGHTS
.
secedit /export /areas USER_RIGHTS /cfg foo.txt
if you need a working example. I did not post that because I found the idea of a command line tool that requires an output file and does not use the stdout quite embarrassing. Pipe into grep
, anyone?
Jan 17, 2012 at 19:24
TokenPrivileges
class shouldn't be too hard...
Jan 17, 2012 at 19:29
See here:
Control Panel->Administration->Local Security Policies->Local Policies->User Rights->Perform Volume Maintenance Tasks
In the past I've used this method by John Sansom: http://www.johnsansom.com/sqlserver-instant-file-initialization/
Simple SQL script involving trace flags.