Drive size and free space

  • Is there any way to get the size and space available on a server's drives without using CLR or the OA extended stored procs?

    I know it's possible with the CLR, but currently the CLR is not enabled and I don't know when that will be changing.

    Thanks

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • space available: xp_fixeddrives


    * Noel

  • Thanks. Forgot about that one.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • xp_fixeddrives can only give out the free space of each drive. How to get the drives' capacity(total space)?. I know using sp_OACreate 'Scripting.FileSystemObject' can get that info, but I don't want to enable the sp_OA...stuff in SQL 2005. Anyone knows another way to do it without using CLR?

    Thanks!

  • Do you have to use SQL Server. If the server is windows 2003, you can use srvinfo.exe (you can download @ http://www.microsoft.com/downloads/details.aspx?FamilyID=9D467A69-57FF-4AE7-96EE-B18C4790CFFD&displaylang=en). this will give you many information about server including hard drive space. you can use cmd line to get the info ex: srvinfo  servername >>  diskspace.txt.

  • Great. Thanks a lot.

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply