Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 SQL Server Administration (2008)
 Space Statistics

Author  Topic 

arvind_ramugade
Starting Member

30 Posts

Posted - 2011-12-16 : 06:05:59
How to gather space statistics [Free/Available space] on a server side ?


ramugade

pnash
Starting Member

26 Posts

Posted - 2011-12-16 : 07:48:17
If I am getting you correct, to get free space of drives.

Exec Xp_fixeddrives
Go to Top of Page

lappin
Posting Yak Master

182 Posts

Posted - 2011-12-16 : 07:50:00
Do you mean space in database files (sp_spaceused) or disk space: http://www.sqlservercentral.com/articles/Administration/monitoringdiskspaceandsendingalertswithtsql/1114/
Go to Top of Page

arvind_ramugade
Starting Member

30 Posts

Posted - 2011-12-16 : 08:19:53
I got below error when I tried executing it against 'admin' database

Exec Xp_fixeddrives

18:27:03.407 DBMS dzwas1035 -- The server principal "arvinr" is not able to access the database "admin" under the current security context.(HY024,916)

ramugade
Go to Top of Page

Bustaz Kool
Master Smack Fu Yak Hacker

1834 Posts

Posted - 2011-12-16 : 11:42:34
Does your Login account have access to that database? Are you accessing other databases (e.g., Reading from one but logging to another)?

=======================================
Faced with the choice between changing one's mind and proving that there is no need to do so, almost everyone gets busy on the proof. -John Kenneth Galbraith
Go to Top of Page

pnash
Starting Member

26 Posts

Posted - 2011-12-18 : 10:12:19
Try executing this and its required a sysadmin privileges to your login.
Exec master..xp_fixeddrives

Go to Top of Page

arvind_ramugade
Starting Member

30 Posts

Posted - 2011-12-21 : 04:30:44
Thanks !

ramugade
Go to Top of Page
   

- Advertisement -