Menu & Search
Get Disk Space of a SQL Server

Get Disk Space of a SQL Server


You can quickly check disk space info on a SQL Server host by running the query below. I sometimes find this the quickest way to check available space rather than using PowerShell or the Windows GUI. This SQL Script only work on SQL Server 2008 R2 and above.

The query result will be returned within a blink, and look like this.

SQL Server Disk Space Query Result.

The PowerShell cmdlet below will also get you the information you need. If running on a remote server, use Enter-PSSession to connect to the target server first (requires Local Admin permissions).

PowerShell Get-Volume.