Finding Size of Instance Database

Mike McCall
Giga Guru

Is there a way to see the size of the database being used for your instance? Before I open a support ticket with this question, I thought I'd check if anyone knew an on-demand method available to administrators.

Obviously, I would appreciate granularity (size per table, etc.), but even just a single number would be great (e.g., "your instance's database is currently 1.2 GB").

1 ACCEPTED SOLUTION

nyancer3
Tera Expert

I realize this is an older thread, but I had a similar question posed to me in regard to sizing an on-prem database for replicating the instance data for reporting usage.

I am not sure exactly what version introduced it, but there is now a count gauge on the Instance Usage > Application Usage Overview page that shows the current total size of the database for your instance. If you edit the widget and go into the code for the counter, you can see the API used to gather the metric: SNC.UsageAnalyticsScriptUtils.getCount('Primary DB size (MB)', 'Primary DB size of this instance (in MB)');

Hope that helps.

find_real_file.png

View solution in original post

27 REPLIES 27

Step 3: Now for each table, open a record, one with lots of text would be great. Right click the header and select "Show XML"


Step 4: Copy/Paste the XML to a text editor and save it.   Note the size of the file and use that as an expected record size.


Step 5 - Now, for each table, multiple the number of records by the expected record size.   This is the expected size of the table.


Step 6 - Total up the sizes for all the tables.


Step 7 - Now take the sum total of all table sizes and multiply by a suitable _ factor, usually a power of ten.


The underscore in the line above represents a word which was the root cause of my postings being blocked.


So I didn't include it there.   If you want to substitute the underscore with the word, the word starts with an "f" and a "u"


and ends with   "dge".


Whew! I'm glad to have learned what the problem was.   I'll be sure to use appropriate language from now on.


michalkovacgv
Kilo Contributor

Yet another approximation - download http://www.snow-mirror.com/products/servicenow/download/ , obtain 30-days trial license, and copy your SNOW database over to your computer (it is really intuitive and straight-forward process). In case that your local database will be of the same vendor (MySQL), guessing that they will be near the same size (those will be "data size", also you can add some % for indexes, or re-create them manually in your local database).


Deepak Kumar5
Kilo Sage

I was able to see the tables database size during the Cloning of instance in related list during the cloning.It was showing the table size and size copied.