On the occasion of the spring system administrators complain that the weekly Bacup all servers takes more than a day and asked to clean bakapy. We have more than 20 sql servers, and therefore uninteresting to look manually.
The problem is this:
— find *.bak files are "large" size, which was not updated more than a month
— find instalasi (*.exe, *.zip, etc) large size
find detached database file (mdf / ndf / ldf)
The solution chosen WMI
select * from CIM_DataFile where extension='bak' works
with acceptable speed
but the search
select * from CIM_DataFile where name like '%.bak' and FileSize > 1000000
select * from CIM_DataFile where FileSize > 100000000
select * from CIM_DataFile
the server is not loaded 100%, of visible download processes antivirus.
A Google search led to the article technet.microsoft.com/en-us/library/ee176621.aspx
in which write that the search through the WMI 80,000 files in 6 times more slowly, but it is in Windows 2000.
Environment we have Windows 2003 — 2008 R2.
How to speed up the search and what options still there?