sql server - Finding available drive space of databases stored on a LUN -


We have several databases whose files are stored in their own individual mount points in the drive

 ( E.g., z: \ dbname_db \ ​​dbname_db.mdf and Z: \ dbname_log \ dbname_log.ldf) 

I am searching for a way to find the available free space of the mount point.

 EXEC xp_cmdshell 'fsutil volume diskfree Z: \ dbname_db' 

but service is not running as administrator so fsutil will not work.

How do I do this, is a stored procedure the most effective way to do this?

xp_fixeddrives will not show mount points for information, only normal fixed drives.

The CLL process in the following link will use a display counter to return the capacity of the mount point and the empty space.


Comments