diff options
Diffstat (limited to 'doc/administration/monitoring')
8 files changed, 146 insertions, 99 deletions
diff --git a/doc/administration/monitoring/gitlab_self_monitoring_project/index.md b/doc/administration/monitoring/gitlab_self_monitoring_project/index.md index 6f2e3cce0fa..2553638291d 100644 --- a/doc/administration/monitoring/gitlab_self_monitoring_project/index.md +++ b/doc/administration/monitoring/gitlab_self_monitoring_project/index.md @@ -54,7 +54,7 @@ you create the project again, it's created in its default state. 1. On the top bar, select **Menu > Admin**. 1. On the left sidebar, go to **Settings > Metrics and profiling** and expand **Self monitoring**. 1. Toggle **Self monitoring** off. -1. In the confirmation dialog that opens, click **Delete self monitoring project**. +1. In the confirmation dialog that opens, select **Delete self monitoring project**. It can take a few seconds for it to be deleted. 1. After the project is deleted, GitLab displays a message confirming your action. @@ -82,10 +82,10 @@ you [configure it manually](../../../user/project/integrations/prometheus.md#man ## Take action on Prometheus alerts **(ULTIMATE)** -You can [add a webhook](../../../operations/metrics/alerts.md#external-prometheus-instances) -to the Prometheus configuration for GitLab to receive notifications of any alerts. +You can [add a Prometheus integration](../../../operations/incident_management/integrations.md) +to GitLab to receive notifications of any alerts. -Once the webhook is setup, you can +Once the integration is setup, you can [take action on incoming alerts](../../../operations/metrics/alerts.md#trigger-actions-from-alerts). ## Add custom metrics to the self monitoring project diff --git a/doc/administration/monitoring/index.md b/doc/administration/monitoring/index.md index 381c807dbc5..82a6da1d56a 100644 --- a/doc/administration/monitoring/index.md +++ b/doc/administration/monitoring/index.md @@ -20,7 +20,7 @@ Explore our features to monitor your GitLab instance: importer with various Prometheus metrics. - [Monitoring uptime](../../user/admin_area/monitoring/health_check.md): Check the server status using the health check endpoint. - - [IP whitelists](ip_whitelist.md): Configure GitLab for monitoring endpoints that + - [IP allowlists](ip_whitelist.md): Configure GitLab for monitoring endpoints that provide health check information when probed. - [`nginx_status`](https://docs.gitlab.com/omnibus/settings/nginx.html#enablingdisabling-nginx_status): Monitor your NGINX server status. diff --git a/doc/administration/monitoring/ip_allowlist.md b/doc/administration/monitoring/ip_allowlist.md new file mode 100644 index 00000000000..adf9516733a --- /dev/null +++ b/doc/administration/monitoring/ip_allowlist.md @@ -0,0 +1,57 @@ +--- +stage: Data Stores +group: Memory +info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments +--- + +# IP whitelist **(FREE SELF)** + +NOTE: +We intend to [rename IP whitelist as `IP allowlist`](https://gitlab.com/groups/gitlab-org/-/epics/3478). + +GitLab provides some [monitoring endpoints](../../user/admin_area/monitoring/health_check.md) +that provide health check information when probed. + +To control access to those endpoints via IP whitelisting, you can add single +hosts or use IP ranges: + +**For Omnibus installations** + +1. Open `/etc/gitlab/gitlab.rb` and add or uncomment the following: + + ```ruby + gitlab_rails['monitoring_whitelist'] = ['127.0.0.0/8', '192.168.0.1'] + ``` + +1. Save the file and [reconfigure](../restart_gitlab.md#omnibus-gitlab-reconfigure) GitLab for the changes to take effect. + +--- + +**For installations using cloud native Helm charts** + +You can set the required IPs under the `gitlab.webservice.monitoring.ipWhitelist` key. For example: + +```yaml +gitlab: + webservice: + monitoring: + # Monitoring IP whitelist + ipWhitelist: + - 0.0.0.0/0 # Default +``` + +--- + +**For installations from source** + +1. Edit `config/gitlab.yml`: + + ```yaml + monitoring: + # by default only local IPs are allowed to access monitoring resources + ip_whitelist: + - 127.0.0.0/8 + - 192.168.0.1 + ``` + +1. Save the file and [restart](../restart_gitlab.md#installations-from-source) GitLab for the changes to take effect. diff --git a/doc/administration/monitoring/ip_whitelist.md b/doc/administration/monitoring/ip_whitelist.md index b8347ba3f0d..9fb4ffe3089 100644 --- a/doc/administration/monitoring/ip_whitelist.md +++ b/doc/administration/monitoring/ip_whitelist.md @@ -1,57 +1,11 @@ --- -stage: Monitor -group: Respond -info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments +redirect_to: 'ip_allowlist.md' +remove_date: '2022-08-31' --- -# IP whitelist **(FREE SELF)** +This document was moved to [another location](ip_allowlist.md). -NOTE: -We intend to [rename IP whitelist as `IP allowlist`](https://gitlab.com/groups/gitlab-org/-/epics/3478). - -GitLab provides some [monitoring endpoints](../../user/admin_area/monitoring/health_check.md) -that provide health check information when probed. - -To control access to those endpoints via IP whitelisting, you can add single -hosts or use IP ranges: - -**For Omnibus installations** - -1. Open `/etc/gitlab/gitlab.rb` and add or uncomment the following: - - ```ruby - gitlab_rails['monitoring_whitelist'] = ['127.0.0.0/8', '192.168.0.1'] - ``` - -1. Save the file and [reconfigure](../restart_gitlab.md#omnibus-gitlab-reconfigure) GitLab for the changes to take effect. - ---- - -**For installations using cloud native Helm charts** - -You can set the required IPs under the `gitlab.webservice.monitoring.ipWhitelist` key. For example: - -```yaml -gitlab: - webservice: - monitoring: - # Monitoring IP whitelist - ipWhitelist: - - 0.0.0.0/0 # Default -``` - ---- - -**For installations from source** - -1. Edit `config/gitlab.yml`: - - ```yaml - monitoring: - # by default only local IPs are allowed to access monitoring resources - ip_whitelist: - - 127.0.0.0/8 - - 192.168.0.1 - ``` - -1. Save the file and [restart](../restart_gitlab.md#installations-from-source) GitLab for the changes to take effect. +<!-- This redirect file can be deleted after <2022-08-31>. --> +<!-- Redirects that point to other docs in the same project expire in three months. --> +<!-- Redirects that point to docs in a different project or site (for example, link is not relative and starts with `https:`) expire in one year. --> +<!-- Before deletion, see: https://docs.gitlab.com/ee/development/documentation/redirects.html --> diff --git a/doc/administration/monitoring/performance/performance_bar.md b/doc/administration/monitoring/performance/performance_bar.md index bc311f73dfe..aefd7a49b8b 100644 --- a/doc/administration/monitoring/performance/performance_bar.md +++ b/doc/administration/monitoring/performance/performance_bar.md @@ -21,7 +21,7 @@ From left to right, the performance bar displays: - **Current Host**: the current host serving the page. - **Database queries**: the time taken (in milliseconds) and the total number - of database queries, displayed in the format `00ms / 00 (00 cached) pg`. Click to display + of database queries, displayed in the format `00ms / 00 (00 cached) pg`. Select to display a modal window with more details. You can use this to see the following details for each query: - **In a transaction**: shows up below the query if it was executed in @@ -35,21 +35,21 @@ From left to right, the performance bar displays: GitLab features. The name shown is the same name used to configure database connections in GitLab. - **Gitaly calls**: the time taken (in milliseconds) and the total number of - [Gitaly](../../gitaly/index.md) calls. Click to display a modal window with more + [Gitaly](../../gitaly/index.md) calls. Select to display a modal window with more details. - **Rugged calls**: the time taken (in milliseconds) and the total number of [Rugged](../../nfs.md#improving-nfs-performance-with-gitlab) calls. - Click to display a modal window with more details. + Select to display a modal window with more details. - **Redis calls**: the time taken (in milliseconds) and the total number of - Redis calls. Click to display a modal window with more details. + Redis calls. Select to display a modal window with more details. - **Elasticsearch calls**: the time taken (in milliseconds) and the total number of - Elasticsearch calls. Click to display a modal window with more details. + Elasticsearch calls. Select to display a modal window with more details. - **External HTTP calls**: the time taken (in milliseconds) and the total - number of external calls to other systems. Click to display a modal window + number of external calls to other systems. Select to display a modal window with more details. - **Load timings** of the page: if your browser supports load timings, several values in milliseconds, separated by slashes. - Click to display a modal window with more details. The values, from left to right: + Select to display a modal window with more details. The values, from left to right: - **Backend**: time needed for the base page to load. - [**First Contentful Paint**](https://web.dev/first-contentful-paint/): Time until something was visible to the user. Displays `NaN` if your browser does not @@ -112,7 +112,7 @@ for a given group: 1. On the left sidebar, select **Settings > Metrics and profiling** (`admin/application_settings/metrics_and_profiling`), and expand **Profiling - Performance bar**. -1. Click **Allow non-administrators access to the performance bar**. +1. Select **Allow non-administrators access to the performance bar**. 1. In the **Allow access to members of the following group** field, provide the full path of the group allowed to access the performance. -1. Click **Save changes**. +1. Select **Save changes**. diff --git a/doc/administration/monitoring/prometheus/index.md b/doc/administration/monitoring/prometheus/index.md index 22f7419be9a..51360800d66 100644 --- a/doc/administration/monitoring/prometheus/index.md +++ b/doc/administration/monitoring/prometheus/index.md @@ -1,5 +1,5 @@ --- -stage: Enablement +stage: Systems group: Distribution info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments --- @@ -137,8 +137,8 @@ The steps below are the minimum necessary to configure a Monitoring node running # Enable service discovery for Prometheus consul['enable'] = true - consul['monitoring_service_discovery'] = true - consul['configuration'] = { + consul['monitoring_service_discovery'] = true + consul['configuration'] = { retry_join: %w(10.0.0.1 10.0.0.2 10.0.0.3), # The addresses can be IPs or FQDNs } @@ -205,7 +205,7 @@ To use an external Prometheus server: ``` 1. Install and set up a dedicated Prometheus instance, if necessary, using the [official installation instructions](https://prometheus.io/docs/prometheus/latest/installation/). -1. Add the Prometheus server IP address to the [monitoring IP whitelist](../ip_whitelist.md). For example: +1. Add the Prometheus server IP address to the [monitoring IP allowlist](../ip_whitelist.md). For example: ```ruby gitlab_rails['monitoring_whitelist'] = ['127.0.0.0/8', '192.168.0.1'] @@ -381,11 +381,12 @@ memory, disk, and CPU utilization. [Read more about the node exporter](node_exporter.md). -### Puma exporter +### Web exporter -The Puma exporter allows you to measure various Puma metrics. +The web exporter is a dedicated metrics server that allows splitting end-user and Prometheus traffic +into two separate applications to improve performance and availability. -[Read more about the Puma exporter](puma_exporter.md). +[Read more about the web exporter](puma_exporter.md). ### Redis exporter diff --git a/doc/administration/monitoring/prometheus/puma_exporter.md b/doc/administration/monitoring/prometheus/puma_exporter.md index 794e2c10b25..a3e095f5f09 100644 --- a/doc/administration/monitoring/prometheus/puma_exporter.md +++ b/doc/administration/monitoring/prometheus/puma_exporter.md @@ -1,29 +1,11 @@ --- -stage: Monitor -group: Respond -info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments +redirect_to: 'web_exporter.md' +remove_date: '2022-09-01' --- -# Puma exporter **(FREE SELF)** +This document was moved to [another location](web_exporter.md). -You can use the [Puma exporter](https://github.com/sapcc/puma-exporter) -to measure various Puma metrics. - -To enable the Puma exporter: - -1. [Enable Prometheus](index.md#configuring-prometheus). -1. Edit `/etc/gitlab/gitlab.rb` to add (or find and uncomment) the following lines. Make sure - `puma['exporter_enabled']` is set to `true`: - - ```ruby - puma['exporter_enabled'] = true - puma['exporter_address'] = "127.0.0.1" - puma['exporter_port'] = 8083 - ``` - -1. Save the file and [reconfigure GitLab](../../restart_gitlab.md#omnibus-gitlab-reconfigure) - for the changes to take effect. - -Prometheus begins collecting performance data from the Puma exporter exposed at `localhost:8083`. - -For more information on using Puma with GitLab, see [Puma](../../operations/puma.md). +<!-- This redirect file can be deleted after <2022-09-01>. --> +<!-- Redirects that point to other docs in the same project expire in three months. --> +<!-- Redirects that point to docs in a different project or site (for example, link is not relative and starts with `https:`) expire in one year. --> +<!-- Before deletion, see: https://docs.gitlab.com/ee/development/documentation/redirects.html -->
\ No newline at end of file diff --git a/doc/administration/monitoring/prometheus/web_exporter.md b/doc/administration/monitoring/prometheus/web_exporter.md new file mode 100644 index 00000000000..4b449a1d74e --- /dev/null +++ b/doc/administration/monitoring/prometheus/web_exporter.md @@ -0,0 +1,53 @@ +--- +stage: Data Stores +group: Memory +info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments +--- + +# Web exporter (dedicated metrics server) **(FREE SELF)** + +When [monitoring GitLab with Prometheus](index.md), GitLab runs various collectors that +sample the application for data related to usage, load and performance. GitLab can then make +this data available to a Prometheus scraper by running one or more Prometheus exporters. +A Prometheus exporter is an HTTP server that serializes metric data into a format the +Prometheus scraper understands. + +NOTE: +This page is about web application metrics. +To export background job metrics, learn how to [configure the Sidekiq metrics server](../../sidekiq.md#configure-the-sidekiq-metrics-server). + +We provide two mechanisms by which web application metrics can be exported: + +- Through the main Rails application. This means [Puma](../../operations/puma.md), the application server we use, + makes metric data available via its own `/-/metrics` endpoint. This is the default, + and is described in [GitLab Metrics](index.md#gitlab-metrics). We recommend this + default for small GitLab installations where the amount of metrics collected is small. +- Through a dedicated metrics server. Enabling this server will cause Puma to launch an + additional process whose sole responsibility is to serve metrics. This approach leads + to better fault isolation and performance for very large GitLab installations, but + comes with additional memory use. We recommend this approach for medium to large + GitLab installations that seek high performance and availability. + +Both the dedicated server and the Rails `/-/metrics` endpoint serve the same data, so +they are functionally equivalent and differ merely in their performance characteristics. + +To enable the dedicated server: + +1. [Enable Prometheus](index.md#configuring-prometheus). +1. Edit `/etc/gitlab/gitlab.rb` to add (or find and uncomment) the following lines. Make sure + `puma['exporter_enabled']` is set to `true`: + + ```ruby + puma['exporter_enabled'] = true + puma['exporter_address'] = "127.0.0.1" + puma['exporter_port'] = 8083 + ``` + +1. When using the GitLab-bundled Prometheus, make sure that its `scrape_config` is pointing + to `localhost:8083/metrics`. Refer to the [Adding custom scrape configurations](index.md#adding-custom-scrape-configurations) page + for how to configure scraper targets. For external Prometheus setup, refer to + [Using an external Prometheus server](index.md#using-an-external-prometheus-server) instead. +1. Save the file and [reconfigure GitLab](../../restart_gitlab.md#omnibus-gitlab-reconfigure) + for the changes to take effect. + +Metrics can now be served and scraped from `localhost:8083/metrics`. |