Tag: Redgate Monitor

  • Monday Monitor Tips- Enabling Index Tracking in Redgate Monitor

    There is a new index feature in Redgate Monitor, but it’s disabled by default. This post shows how to enable things.

    This is part of a series of posts on Redgate Monitor. Click to see the other posts

    Getting Indexing Information

    If you look on monitor.red-gate.com, inside the details for one of your instances, there is a new Indexing tab. I’ve circled it below.

    2024-07-02 15_00_39-ssc-db-n3_(local) - Server Overview — Mozilla Firefox

    After clicking this, I see the data below for this instance. This shows me a lot of high level information usage on different indexes. The data shows index, then table, then database, but I can search/filter here. I can also sort by the columns, which contain size, updates, seeks, etc. Lots of data.

    2024-07-02 15_03_21-ssc-db-n3_(local) - Server Overview — Mozilla Firefox

    This is disabled by default, as the collection of this data used a lot of memory on the Base Monitor system for some users. Not necessarily something everyone wants, so we left it off.

    You can, however, enable it.

    Enabling Index Data

    There is a doc page for this feature, which I show below. This is a fairly easy procedure, but not everyone knows how to do this, so I’ll explain.

    2024-07-02 15_05_48-Indexes - Redgate Monitor 14 - Product Documentation

    If you look above, in the warning box, it notes how to enable this. From the base monitor, you need to add an environment variable.

    To do this on Windows, the easy thing is search the start menu for “environ”. You should see something like this. Pick the “edit the system environment variables” item at the top.

    2024-07-02 15_08_19-Media Player

    This should bring up the System Properties in Windows (desktop or server). You can also search for environment variables in the Control Panel. Earlier version of Windows let you right click the system and select properties.

    Notice the Environment Variables button at the bottom. We’ll click this.

    2024-07-02 15_08_59-System Properties

    This brings up a dialog that has two sections. We want the bottom, system variables, section. Click the New button at the bottom, below this list of system variables.

    2024-07-02 15_10_42-Environment Variables

    In the dialog, paste this in the variable name: SQLMONITOR_Indexes

    For the value, add “on”. I’m not sure if this is case sensitive, but past in lower case.

    2024-07-02 15_18_52-New System Variable

    Then you need to restart both the base monitor and the web server. This is in the Service Applet, where you can see the Base Monitor and the Web Service.

    Note: depending on versions, you might see this as “SQL Monitor Base Monitor” or “Redgate Monitor Base Monitor”.

    2024-07-02 15_23_01-LiveLabConnection (1) - 3.254.186.109 - Remote Desktop Connection

    Restart both of these services.

    When things come up, you’ll see blanks until some index data can be captured, but be patient and check back in an hour or two.

    Make sure you monitor memory usage on your base monitor machine. If you find yourself running low, you can disable this by setting the system variable to off. Or delete it.

    Or add more RAM. More RAM cures a lot of things.

    Redgate Monitor is a world class monitoring solution for your database estate. Download a trial today and see how it can help you manage your estate more efficiently.

  • Monday Monitor Tips – Adding Redgate Monitor Custom Metrics from SQLMonitorMetrics

    This post talks about adding custom metrics from the sqlmonitormetrics.com site automatically and how this works (and how it doesn’t).

    This is part of a series of posts on Redgate Monitor. Click to see the other posts

    What is SQL Monitor Metrics?

    SQLMonitorMetrics was a site that Redgate built years ago to hold various community submitted metrics that users of Redgate Monitor (formerly SQL Monitor) might care about or be interested in using. Myself, Grant, and a number of other MVPs and SQL Server experts submitted our own metrics in various categories.

    At some point an integration was created to make the install of these metrics easy. This post shows how to do this and not to do this below.

    How to Auto Install Metrics

    The proper way to install metrics is to start in Redgate Monitor. Go to the config screen by clicking the gear in the upper right.

    2024-07-02 14_37_58-Global Dashboard — Mozilla Firefox

    Next, in the Alerts section pick the custom metrics and alerts item. Click this.

    2024-07-02 14_38_43-Configuration — Mozilla Firefox

    This brings up a list of your custom metrics. In the text at the top, it says you can install a metric automatically, but you need to click the link my cursor is highlighted on below.

    2024-07-02 14_39_14-Custom metrics and alerts — Mozilla Firefox

    This brings me to the sqlmonitormetrics site. I’ll click find a metric. I could also click the Custom Metrics at the top.

    2024-07-02 14_40_42-Redgate Monitor Metrics - Custom metrics to use in Redgate Monitor — Mozilla Fir

    I’ll select the first one for this post, but you can filter, search, or scroll around to find one.

    2024-07-02 14_40_51-Custom Metric Archives - Redgate Monitor Metrics — Mozilla Firefox

    The page for the custom metric has a button at the top. Please read the page and test the SQL to see what’s returned before you click this, but when you’re ready, click the button.

    2024-07-02 14_42_59-Detecting Connection Timeouts - Redgate Monitor Metrics — Mozilla Firefox

    When I do this, I’m returned to Redgate Monitor, this time on the Create Custom Metric page, with the fields filled in. As with anything, be sure you review and check to be sure this is what you want.

    2024-07-02 14_43_49-Custom metrics — Mozilla Firefox

    That’s it. When you’re done, click create and your metric and/or alert will be set up.

    How Not to Install Metrics

    This works, but it’s a pain. If I go directly to https://sqlmonitormetrics.red-gate.com/ and then find a metric, such as the number of active backups and restores, I see this, an inactive button:

    2024-07-02 14_45_56-Number of active backups and restores - Redgate Monitor Metrics

    Because I didn’t start from Redgate Monitor, I can’t get this automatically.

    If I scroll down, I see all the fields (in bold) and the entries. I can copy/paste all of these into the form, but this is a slow way to add metrics.

    2024-07-02 14_46_45-Number of active backups and restores - Redgate Monitor Metrics

    Don’t do this. Go to Redgate Monitor and start there (as shown above).

    Summary

    This post shows how to automatically add custom metrics written by others from the sqlmonitormetrics website. This is a good way to add common checks to your system that others use.

    If you see something missing, submit it, or ping me and I’ll write it or find someone else to do so.

    Redgate Monitor is a world class monitoring solution for your database estate. Download a trial today and see how it can help you manage your estate more efficiently.

  • Manually Updating Redgate Monitor/SQL Monitor Patch Info

    This post looks at updating the patch information for SQL Monitor/Redgate Monitor without using the automated process. I have other posts on SQL Monitor as well.

    I heard from a customer recently that saw on their SQL Monitor (soon to be Redgate Monitor) Estate screen that the latest patch for SQL Server 2019 was CU24. I knew that was wrong because I’d updated my build list with CU25. On monitor.red-gate.com we show the same thing.

    2024-03-25 13_28_12-Installed versions — Mozilla Firefox

    I suspected that their web server wasn’t updating for some reason, which is possible. We have plenty of customers that wall off their SQL Monitor install from the public Internet, and they have to manually update the system.

    Getting the data

    We store this info in a JSON file that the web server downloads, but you can download it yourself at: https://assets.red-gate.com/products/dba/sql-monitor/assets/files/SqlServerVersions.json?_ga=2.168000097.1575041045.1711384591-1774306502.1648754310

    If you look at the file, you see that there are versions, levels, etc., and in the SQL 2019 area, there is a CU25.

    Once you have this, you drop this on your SQL Monitor web server. The location is: C:\ProgramData\Red Gate\SQL Monitor\SqlServerVersions.json. You can replace the contents of that file with this one.

    SQL Monitor will re-read the file within 6 hours, or if you restart the server, it will re-read the file.

    That’s it. If your system doesn’t have internet access, you can still get up to date info. FWIW, this is documented at the bottom of this page: https://documentation.red-gate.com/sm13/sql-server-versioning-and-patching-195789945.html

    SQL Monitor is a top-notch system for monitoring your SQL Server and PostgreSQL estates. Oracle and MySQL coming soon. If you haven’t tried it, download an eval and give it a go or play with the demo system at monitor.red-gate.com.

  • Database Search in SQL Monitor

    I learned something new recently. I can search in SQL Monitor for a database name, not just a server or instance name.

    I tested this over at monitor.red-gate.com recently after a developer mentioned this feature. If you look at the Global Dashboard, there are a lot of machines. You can see 28 instances monitored, but many more databases.

    2022-07-12 09_20_30-Global Dashboard — Mozilla Firefox

    If I were looking for the DatabaseWeekly database, I would need to know which instance this was hosted on. I do know, but someone in our IT support org might not.

    However, if they start typing in the search box at the, the instances shrink. This is the top left box that has “Filter by name” in light text. If I type “database”, you can see fewer instances.

    2022-07-12 09_22_07-Global Dashboard — Mozilla Firefox

    If I add the weekly, then you see there is a cluster of two machines that have this database.

    2022-07-12 09_22_17-Global Dashboard — Mozilla Firefox

    If I pick one of these machines, I can see the databases with this name listed.

    2022-07-12 09_25_56-ssc-db-n1_(local) - Server Overview — Mozilla Firefox

    A handy little feature I knew nothing about.

    Give this a try if you have SQL Monitor and save even more time digging into performance issues. If you don’t have SQL Monitor, download an eval today and give it a try.