Solved

SQL Database Size Report for multiple sql srvers, instances & databases

Posted on 2012-04-02
4
424 Views
Last Modified: 2012-06-27
Hi Friends,
We have multiple sql server boxes used as a back end for a variety of applications such as sharepoint, hyperion, navigon etc.
The question is how best we can collate (a report) which contains list of databases (instace & server names) & the size on disk.
This is just to track database growth for all sql servers from one interface/report.

Have tried out SSMS > Mangement > Management Data warehouse > disk usage reports.
Asking for same as such but for all sql databases, instances & servers in the data centre & report in one instance,database only.

Also, any altenative is most welcome.
In SQL space, we have 2005, 2008, 2008 R2 version.
0
Comment
Question by:Minesh Shah
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 5

Assisted Solution

by:25112
25112 earned 500 total points
ID: 37796236
run the below query from central management server http://msdn.microsoft.com/en-us/library/bb934126.aspx (2008 and up only)
For prior version- put the query in SSIS package with a connection string to each instance desired..

SELECT
   (SELECT 'file_type' =  
   CASE  
       WHEN AF.groupid <> 0 THEN 'data'
       WHEN AF.groupid = 0 THEN 'log'
   END) AS 'file_type'
,  DB.name AS 'db_name'
,  AF.name AS 'logical_file_name'
,  AF.filename AS 'physical_file_name'
,  cast((AF.size * 8 / 1024.) as decimal(18,2))  'File_Size_in_MB'
FROM
   sys.databases DB
JOIN
   sys.sysaltfiles  AF ON
database_id = dbid
0
 
LVL 10

Author Comment

by:Minesh Shah
ID: 37823007
hi team,
sorry for delay.
well, above one works. thanks.
ended up in some script which stores data of all these instances in 1 database centrally.

wondering, can we do anything better! your thoughts..
0
 
LVL 5

Accepted Solution

by:
25112 earned 500 total points
ID: 37847709
>>wondering, can we do anything better!
central management server - is it!
0
 
LVL 10

Author Closing Comment

by:Minesh Shah
ID: 37859977
ok
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question