极狐GitLab Prometheus 指标
- Tier: 基础版,专业版,旗舰版
- Offering: 私有化部署
要启用极狐GitLab Prometheus 指标:
- 以拥有管理员访问权限的用户身份登录极狐GitLab。
- 在左侧边栏的底部,选择 管理员。
- 选择 设置 > 指标和性能分析。
- 找到 指标 - Prometheus 部分,并选择 启用极狐GitLab Prometheus 指标端点。
- 重启极狐GitLab 以使更改生效。
对于自编译安装,您必须自行配置。
收集指标
极狐GitLab 监控其自身的内部服务指标,并在 /-/metrics 端点提供这些指标。与其他 Prometheus 导出器不同,要访问这些指标,客户端 IP 地址必须被显式允许。
这些指标已启用并为 Linux 软件包 和 Helm chart 安装收集。对于自编译安装,这些指标必须手动启用并由 Prometheus 服务器收集。
要启用和查看来自 Sidekiq 节点的指标,请参见 Sidekiq 指标。
可用指标
History
- caller_id 在极狐GitLab 15.11 中从 redis_hit_miss_operations_total 和 redis_cache_generation_duration_seconds 中移除。
以下指标可用:
| 指标 | 类型 | 自 | 描述 | 标签 |
|---|---|---|---|---|
| gitlab_cache_misses_total | Counter | 10.2 | 缓存读取未命中 | controller,action,store,endpoint_id |
| gitlab_cache_operation_duration_seconds | Histogram | 10.2 | 缓存访问时间 | operation,store,endpoint_id |
| gitlab_cache_operations_total | Counter | 12.2 | 按控制器或操作的缓存操作 | controller,action,operation,store,endpoint_id |
| gitlab_cache_read_multikey_count | Histogram | 15.7 | 多键缓存读取操作中的键计数 | controller,action,store,endpoint_id |
| gitlab_ci_job_token_inbound_access | Counter | 17.2 | 通过 CI 作业令牌的入站访问计数 | |
| gitlab_ci_job_token_authorization_failures | Counter | 17.11 | 通过 CI 作业令牌的授权尝试失败计数 | same_root_ancestor |
| gitlab_ci_pipeline_builder_scoped_variables_duration | Histogram | 14.5 | 创建 CI/CD 作业的作用域变量所需的秒数 | |
| gitlab_ci_pipeline_creation_duration_seconds | Histogram | 13.0 | 创建 CI/CD 流水线所需的秒数 | gitlab |
| gitlab_ci_pipeline_size_builds | Histogram | 13.1 | 按流水线来源分组的流水线内构建总数 | source |
| gitlab_ci_runner_authentication_success_total | Counter | 15.2 | runner 认证成功的总次数 | type |
| gitlab_ci_runner_authentication_failure_total | Counter | 15.2 | runner 认证失败的总次数 | |
| gitlab_ghost_user_migration_lag_seconds | Gauge | 15.6 | 鬼用户迁移的最旧计划记录的等待时间(秒) | |
| gitlab_ghost_user_migration_scheduled_records_total | Gauge | 15.6 | 已安排的鬼用户迁移总数 | |
| gitlab_ci_active_jobs | Histogram | 14.2 | 创建流水线时的活动作业计数 | |
| gitlab_database_transaction_seconds | Histogram | 12.1 | 数据库事务中花费的时间,以秒为单位 | |
| gitlab_method_call_duration_seconds | Histogram | 10.2 | 方法调用的真实持续时间 | controller,action,module,method |
| gitlab_omniauth_login_total | Counter | 16.1 | OmniAuth 登录尝试的总次数 | omniauth_provider,status |
| gitlab_page_out_of_bounds | Counter | 12.8 | PageLimiter 分页限制命中的计数器 | controller,action,bot |
| gitlab_rails_boot_time_seconds | Gauge | 14.8 | Rails 主进程完成启动所用的时间 | |
| gitlab_rails_queue_duration_seconds | Histogram | 9.4 | 测量极狐GitLab Workhorse 转发请求到 Rails 的延迟 | |
| gitlab_sql_duration_seconds | Histogram | 10.2 | SQL 执行时间,不包括 SCHEMA 操作和 BEGIN / COMMIT | |
| gitlab_sql_<role>_duration_seconds | Histogram | 13.10 | SQL 执行时间,不包括 SCHEMA 操作和 BEGIN / COMMIT,按数据库角色(主/副本)分组 | |
| gitlab_ruby_threads_max_expected_threads | Gauge | 13.3 | 预期运行并执行应用程序工作的最大线程数 | |
| gitlab_ruby_threads_running_threads | Gauge | 13.3 | 按名称运行的 Ruby 线程数 | |
| gitlab_transaction_cache_<key>_count_total | Counter | 10.2 | Rails 缓存调用的总计数器(每个键) | |
| gitlab_transaction_cache_<key>_duration_total | Counter | 10.2 | Rails 缓存调用的总时间(秒)计数器(每个键) | |
| gitlab_transaction_cache_count_total | Counter | 10.2 | Rails 缓存调用的总计数器(汇总) | |
| gitlab_transaction_cache_duration_total | Counter | 10.2 | Rails 缓存调用的总时间(秒)计数器(汇总) | |
| gitlab_transaction_cache_read_hit_count_total | Counter | 10.2 | Rails 缓存调用的缓存命中计数器 | controller,action,store,endpoint_id |
| gitlab_transaction_cache_read_miss_count_total | Counter | 10.2 | Rails 缓存调用的缓存未命中计数器 | controller,action,store,endpoint_id |
| gitlab_transaction_duration_seconds | Histogram | 10.2 | 成功请求的持续时间(gitlab_transaction_* 指标) | controller,action,endpoint_id |
| gitlab_transaction_event_build_found_total | Counter | 9.4 | API /jobs/request 的构建找到计数器 | |
| gitlab_transaction_event_build_invalid_total | Counter | 9.4 | API /jobs/request 的构建因并发冲突无效的计数器 | |
| gitlab_transaction_event_build_not_found_cached_total | Counter | 9.4 | API /jobs/request 的构建未找到的缓存响应计数器 | |
| gitlab_transaction_event_build_not_found_total | Counter | 9.4 | API /jobs/request 的构建未找到计数器 | |
| gitlab_transaction_event_change_default_branch_total | Counter | 9.4 | 任何存储库的默认分支更改时的计数器 | |
| gitlab_transaction_event_create_repository_total | Counter | 9.4 | 任何存储库创建时的计数器 | |
| gitlab_transaction_event_etag_caching_cache_hit_total | Counter | 9.4 | ETag 缓存命中计数器 | endpoint |
| gitlab_transaction_event_etag_caching_header_missing_total | Counter | 9.4 | ETag 缓存未命中 - 缺少标头计数器 | endpoint |
| gitlab_transaction_event_etag_caching_key_not_found_total | Counter | 9.4 | ETag 缓存未命中 - 未找到键计数器 | endpoint |
| gitlab_transaction_event_etag_caching_middleware_used_total | Counter | 9.4 | 访问 ETag 中间件的计数器 | endpoint |
| gitlab_transaction_event_etag_caching_resource_changed_total | Counter | 9.4 | ETag 缓存未命中 - 资源更改计数器 | endpoint |
| gitlab_transaction_event_fork_repository_total | Counter | 9.4 | 存储库分支(RepositoryForkWorker)的计数器。仅在源存储库存在时递增 | |
| gitlab_transaction_event_import_repository_total | Counter | 9.4 | 存储库导入(RepositoryImportWorker)的计数器 | |
| gitlab_transaction_event_patch_hard_limit_bytes_hit_total | Counter | 13.9 | 差异补丁大小限制命中计数器 | |
| gitlab_transaction_event_push_branch_total | Counter | 9.4 | 所有分支推送的计数器 | |
| gitlab_transaction_event_rails_exception_total | Counter | 9.4 | Rails 异常次数的计数器 | |
| gitlab_transaction_event_receive_email_total | Counter | 9.4 | 接收电子邮件的计数器 | handler |
| gitlab_transaction_event_remove_branch_total | Counter | 9.4 | 任何存储库删除分支时的计数器 | |
| gitlab_transaction_event_remove_repository_total | Counter | 9.4 | 存储库被删除时的计数器 | |
| gitlab_transaction_event_remove_tag_total | Counter | 9.4 | 任何存储库的标签被删除时的计数器 | |
| gitlab_transaction_event_sidekiq_exception_total | Counter | 9.4 | Sidekiq 异常计数器 | |
| gitlab_transaction_event_stuck_import_jobs_total | Counter | 9.4 | 卡住的导入作业计数 | projects_without_jid_count,projects_with_jid_count |
| gitlab_transaction_event_update_build_total | Counter | 9.4 | 更新 API /jobs/request/:id 的构建计数器 | |
| gitlab_transaction_new_redis_connections_total | Counter | 9.4 | 新 Redis 连接计数器 | |
| gitlab_transaction_rails_queue_duration_total | Counter | 9.4 | 测量极狐GitLab Workhorse 转发请求到 Rails 的延迟 | controller,action,endpoint_id |
| gitlab_transaction_view_duration_total | Counter | 9.4 | 视图的持续时间 | controller,action,view,endpoint_id |
| gitlab_view_rendering_duration_seconds | Histogram | 10.2 | 视图的持续时间(直方图) | controller,action,view,endpoint_id |
| http_requests_total | Counter | 9.4 | Rack 请求计数 | method,status |
| http_request_duration_seconds | Histogram | 9.4 | 从 rack 中间件成功请求的 HTTP 响应时间 | method |
| gitlab_transaction_db_count_total | Counter | 13.1 | SQL 调用总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_<role>_count_total | Counter | 13.10 | 按数据库角色(主/副本)分组的 SQL 调用总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_write_count_total | Counter | 13.1 | 写入 SQL 调用总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_cached_count_total | Counter | 13.1 | 缓存 SQL 调用总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_<role>_cached_count_total | Counter | 13.1 | 按数据库角色(主/副本)分组的缓存 SQL 调用总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_<role>_wal_count_total | Counter | 14.0 | 按数据库角色(主/副本)分组的 WAL(预写日志位置)查询总数的计数器 | controller,action,endpoint_id |
| gitlab_transaction_db_<role>_wal_cached_count_total | Counter | 14.1 | 按数据库角色(主/副本)分组的缓存 WAL(预写日志位置)查询总数的计数器 | controller,action,endpoint_id |
| http_elasticsearch_requests_duration_seconds | Histogram | 13.1 | Web 事务期间 Elasticsearch 请求的持续时间。仅专业版和旗舰版。 | controller,action,endpoint_id |
| http_elasticsearch_requests_total | Counter | 13.1 | Web 事务期间 Elasticsearch 请求计数。仅专业版和旗舰版。 | controller,action,endpoint_id |
| pipelines_created_total | Counter | 9.4 | 创建的流水线计数器 | source,partition_id |
| rack_uncaught_errors_total | Counter | 9.4 | 处理 Rack 连接时未捕获错误的计数 | |
| user_session_logins_total | Counter | 9.4 | 自极狐GitLab 启动或重启以来登录的用户数 | |
| upload_file_does_not_exist | Counter | 10.7 | 上传记录找不到文件的次数 | |
| failed_login_captcha_total | Gauge | 11.0 | 登录期间失败的 CAPTCHA 尝试次数 | |
| successful_login_captcha_total | Gauge | 11.0 | 登录期间成功的 CAPTCHA 尝试次数 | |
| auto_devops_pipelines_completed_total | Counter | 12.7 | 按状态标记的已完成自动 DevOps 流水线计数 | |
| artifact_report_<report_type>_builds_completed_total | Counter | 15.3 | 按报告类型分组并按状态标记的具有报告类型产物的已完成 CI 构建的计数 | |
| gitlab_metrics_dashboard_processing_time_ms | Summary | 12.10 | 指标仪表板处理时间(毫秒) | service,stages |
| action_cable_active_connections | Gauge | 13.4 | 当前连接的 ActionCable WS 客户端数量 | server_mode |
| action_cable_broadcasts_total | Counter | 13.10 | 发出的 ActionCable 广播的数量 | server_mode |
| action_cable_pool_min_size | Gauge | 13.4 | ActionCable 线程池中的最小工作线程数 | server_mode |
| action_cable_pool_max_size | Gauge | 13.4 | ActionCable 线程池中的最大工作线程数 | server_mode |
| action_cable_pool_current_size | Gauge | 13.4 | ActionCable 线程池中当前的工作线程数 | server_mode |
| action_cable_pool_largest_size | Gauge | 13.4 | ActionCable 线程池中观察到的最大工作线程数 | server_mode |
| action_cable_pool_pending_tasks | Gauge | 13.4 | ActionCable 线程池中等待执行的任务数 | server_mode |
| action_cable_pool_tasks_total | Gauge | 13.4 | ActionCable 线程池中执行的任务总数 | server_mode |
| gitlab_ci_trace_operations_total | Counter | 13.4 | 作业跟踪上的不同操作总数 | operation |
| gitlab_ci_trace_bytes_total | Counter | 13.4 | 传输的作业跟踪字节总数 | |
| action_cable_single_client_transmissions_total | Counter | 13.10 | 传输给任何频道中任何客户端的 ActionCable 消息数 | server_mode |
| action_cable_subscription_confirmations_total | Counter | 13.10 | 客户端确认的 ActionCable 订阅数 | server_mode |
| action_cable_subscription_rejections_total | Counter | 13.10 | 客户端拒绝的 ActionCable 订阅数 | server_mode |
| action_cable_transmitted_bytes_total | Counter | 16.0 | 通过 ActionCable 传输的字节总数 | operation,channel |
| gitlab_issuable_fast_count_by_state_total | Counter | 13.5 | 议题 和 合并请求 页面上的行计数操作总数 | |
| gitlab_issuable_fast_count_by_state_failures_total | Counter | 13.5 | 议题 和 合并请求 页面上的软失败行计数操作数量 | |
| gitlab_ci_trace_finalize_duration_seconds | Histogram | 13.6 | 作业跟踪块迁移到对象存储的持续时间 | |
| gitlab_vulnerability_report_branch_comparison_real_duration_seconds | Histogram | 15.11 | 漏洞报告在默认分支 SQL 查询上的执行持续时间 | |
| gitlab_vulnerability_report_branch_comparison_cpu_duration_seconds | Histogram | 15.11 | 漏洞报告在默认分支 SQL 查询上的执行持续时间 | |
| gitlab_external_http_total | Counter | 13.8 | 对外部系统进行的 HTTP 调用总数 | controller,action,endpoint_id |
| gitlab_external_http_duration_seconds | Counter | 13.8 | 对外部系统的每个 HTTP 调用所花费的时间(秒) | |
| gitlab_external_http_exception_total | Counter | 13.8 | 发起外部 HTTP 调用时引发的异常总数 | |
| ci_report_parser_duration_seconds | Histogram | 13.9 | 解析 CI/CD 报告产物所需的时间 | parser |
| pipeline_graph_link_calculation_duration_seconds | Histogram | 13.9 | 计算链接所花费的总时间,以秒为单位 | |
| pipeline_graph_links_total | Histogram | 13.9 | 每个图的链接数 | |
| pipeline_graph_links_per_job_ratio | Histogram | 13.9 | 每个图的链接与作业比率 | |
| gitlab_ci_pipeline_security_orchestration_policy_processing_duration_seconds | Histogram | 13.12 | 处理 CI/CD 流水线中的安全策略所需的时间(秒) | |
| gitlab_spamcheck_request_duration_seconds | Histogram | 13.12 | Rails 和反垃圾邮件引擎之间请求的持续时间 | |
| service_desk_thank_you_email | Counter | 14.0 | 对新服务台电子邮件的电子邮件回复总数 | |
| service_desk_new_note_email | Counter | 14.0 | 新服务台评论的电子邮件通知总数 | |
| email_receiver_error | Counter | 14.1 | 处理传入电子邮件时的错误总数 | |
| gitlab_snowplow_events_total | Counter | 14.1 | 发出的极狐GitLab Snowplow Analytics Instrumentation 事件总数 | |
| gitlab_snowplow_failed_events_total | Counter | 14.1 | 极狐GitLab Snowplow Analytics Instrumentation 事件发射失败总数 | |
| gitlab_snowplow_successful_events_total | Counter | 14.1 | 极狐GitLab Snowplow Analytics Instrumentation 事件发射成功总数 | |
| gitlab_ci_build_trace_errors_total | Counter | 14.4 | 作业跟踪上不同错误类型的总数 | error_reason |
| gitlab_presentable_object_cacheless_render_real_duration_seconds | Histogram | 15.3 | 缓存和表示特定 Web 请求对象所花费的实际时间 | controller,action,endpoint_id |
| cached_object_operations_total | Counter | 15.3 | 为特定 Web 请求缓存的对象总数 | controller,action,endpoint_id |
| redis_hit_miss_operations_total | Counter | 15.6 | Redis 缓存命中和未命中的总数 | cache_hit,cache_identifier,feature_category,backing_resource |
| redis_cache_generation_duration_seconds | Histogram | 15.6 | 生成 Redis 缓存所需的时间 | cache_hit,cache_identifier,feature_category,backing_resource |
| gitlab_diffs_reorder_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中重新排序差异文件所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_collection_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中查询合并请求差异文件所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_comparison_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中获取比较数据所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_unfoldable_positions_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中获取可展开的注释位置所花费的时间(秒) | controller,action |
| gitlab_diffs_unfold_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中展开位置所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_write_cache_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中缓存高亮显示的行和统计信息所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_highlight_cache_decorate_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中从缓存设置高亮显示行所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_diffs_render_real_duration_seconds | Histogram | 15.8 | 在差异批量请求中序列化和渲染差异所花费的时间(秒) | controller,action,endpoint_id |
| gitlab_memwd_violations_total | Counter | 15.9 | Ruby 进程违反内存阈值的总次数 | |
| gitlab_memwd_violations_handled_total | Counter | 15.9 | 处理 Ruby 进程内存违规的总次数 | |
| gitlab_sli_rails_request_apdex_total | Counter | 14.4 | 请求 Apdex 测量总数。有关详细信息,请参见 Rails 请求 SLIs | endpoint_id,feature_category,request_urgency |
| gitlab_sli_rails_request_apdex_success_total | Counter | 14.4 | 满足其紧急性目标持续时间的成功请求总数。将其除以 gitlab_sli_rails_requests_apdex_total 可获得成功率 | endpoint_id,feature_category,request_urgency |
| gitlab_sli_rails_request_error_total | Counter | 15.7 | 请求错误测量总数。有关详细信息,请参见 Rails 请求 SLIs | endpoint_id,feature_category,request_urgency,error |
| job_register_attempts_failed_total | Counter | 9.5 | runner 注册作业失败的次数 | |
| job_register_attempts_total | Counter | 9.5 | runner 尝试注册作业的次数 | |
| job_queue_duration_seconds | Histogram | 9.5 | 请求处理执行时间 | |
| gitlab_ci_queue_operations_total | Counter | 16.3 | 记录队列中发生的所有操作 | |
| gitlab_ci_queue_depth_total | Histogram | 16.3 | CI/CD 构建队列相对于操作结果的大小 | |
| gitlab_ci_queue_size_total | Histogram | 16.3 | 初始化 CI/CD 构建队列的大小 | |
| gitlab_ci_current_queue_size | Gauge | 16.3 | 初始化 CI/CD 构建队列的当前大小 | |
| gitlab_ci_queue_iteration_duration_seconds | Histogram | 16.3 | 在 CI/CD 队列中找到构建所需的时间 | |
| gitlab_ci_queue_retrieval_duration_seconds | Histogram | 16.3 | 执行 SQL 查询以检索构建队列所需的时间 | |
| gitlab_connection_pool_size | Gauge | 16.7 | 连接池的大小 | |
| gitlab_connection_pool_available_count | Gauge | 16.7 | 池中可用连接数 | |
| gitlab_security_policies_scan_result_process_duration_seconds | Histogram | 16.7 | 处理合并请求审批策略所需的时间 | |
| gitlab_security_policies_policy_sync_duration_seconds | Histogram | 17.6 | 同步策略配置的策略更改所需的时间 | |
| gitlab_security_policies_policy_deletion_duration_seconds | Histogram | 17.6 | 删除与策略相关的配置所需的时间 | |
| gitlab_security_policies_policy_creation_duration_seconds | Histogram | 17.6 | 创建与策略相关的配置所需的时间 | |
| gitlab_security_policies_sync_opened_merge_requests_duration_seconds | Histogram | 17.6 | 在策略更改后同步已打开的合并请求所需的时间 | |
| gitlab_security_policies_scan_execution_configuration_rendering_seconds | Histogram | 17.3 | 渲染扫描执行策略 CI 配置所需的时间 | |
| gitlab_security_policies_update_configuration_duration_seconds | Histogram | 17.6 | 为策略配置更改安排同步所需的时间 | |
| gitlab_highlight_usage | Counter | 16.8 | 使用 Gitlab::Highlight 的次数 | used_on |
| dependency_linker_usage | Counter | 16.8 | 依赖链接器的使用次数 | used_on |
| gitlab_keeparound_refs_requested_total | Counter | 16.10 | 请求创建的 keep-around refs 数量 | source |
| gitlab_keeparound_refs_created_total | Counter | 16.10 | 实际创建的 keep-around refs 数量 | source |
| search_advanced_index_repair_total | Counter | 17.3 | 索引修复操作的数量 | document_type |
| search_advanced_boolean_settings | Gauge | 17.3 | 高级搜索布尔设置的当前状态 | name |
| gitlab_http_router_rule_total | Counter | 17.4 | 记录 HTTP 路由器规则的 rule_action 和 rule_type 的出现次数 | rule_action,rule_type |
| gitlab_rack_attack_events_total | Counter | 17.6 | 由 Rack Attack 处理的事件总数 | event_type,event_name |
| gitlab_rack_attack_throttle_limit | Gauge | 17.6 | 报告客户在 Rack Attack 限流之前可以进行的最大请求数 | event_name |
| gitlab_rack_attack_throttle_period_seconds | Gauge | 17.6 | 报告在 Rack Attack 限流之前计算客户请求的持续时间 | event_name |
| gitlab_application_rate_limiter_throttle_utilization_ratio | Histogram | 17.6 | 极狐GitLab 应用速率限制器中限流的利用率。 | throttle_key,peek,feature_category |
| gitlab_dependency_path_cte_real_duration_seconds | Histogram | 17.10 | 解析给定组件的祖先依赖路径所花费的时间(秒)。 | |
| dependency_path_cte_paths_found | Counter | 17.10 | 为给定依赖项找到的祖先依赖路径的数量。 | max_depth_reached,cyclic |
由功能标志控制的指标
以下指标可以由功能标志控制:
| 指标 | 功能标志 |
|---|---|
| gitlab_view_rendering_duration_seconds | prometheus_metrics_view_instrumentation |
| gitlab_ci_queue_depth_total | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_queue_size | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_queue_size_total | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_queue_iteration_duration_seconds | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_current_queue_size | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_queue_retrieval_duration_seconds | gitlab_ci_builds_queuing_metrics |
| gitlab_ci_queue_active_runners_total | gitlab_ci_builds_queuing_metrics |
Praefect 指标
您可以配置 Praefect 以报告指标。有关可用指标的信息,请参阅相关文档。
Sidekiq 指标
Sidekiq 作业也可以收集指标,如果启用了 Sidekiq 导出器,则可以访问这些指标:例如,使用 gitlab.yml 中的 monitoring.sidekiq_exporter 配置选项。这些指标从配置的端口的 /metrics 路径提供。
| 指标 | 类型 | 自 | 描述 | 标签 |
|---|---|---|---|---|
| sidekiq_jobs_cpu_seconds | Histogram | 12.4 | 运行 Sidekiq 作业所需的 CPU 时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_jobs_completion_seconds | Histogram | 12.2 | 完成 Sidekiq 作业所需的时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_jobs_db_seconds | Histogram | 12.9 | 运行 Sidekiq 作业所需的数据库时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_jobs_gitaly_seconds | Histogram | 12.9 | 运行 Sidekiq 作业所需的 Gitaly 时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_redis_requests_duration_seconds | Histogram | 13.1 | Sidekiq 作业查询 Redis 服务器所花费的时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_elasticsearch_requests_duration_seconds | Histogram | 13.1 | Sidekiq 作业请求 Elasticsearch 服务器所花费的时间(秒) | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_jobs_queue_duration_seconds | Histogram | 12.5 | Sidekiq 作业在执行前排队的时间(秒) | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_jobs_failed_total | Counter | 12.2 | Sidekiq 作业失败次数 | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_jobs_retried_total | Counter | 12.2 | Sidekiq 作业重试次数 | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_jobs_interrupted_total | Counter | 15.2 | Sidekiq 作业中断次数 | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_jobs_dead_total | Counter | 13.7 | Sidekiq 死亡作业(已用尽重试次数的作业) | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_redis_requests_total | Counter | 13.1 | Sidekiq 作业执行期间的 Redis 请求 | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_elasticsearch_requests_total | Counter | 13.1 | Sidekiq 作业执行期间的 Elasticsearch 请求 | queue,boundary,external_dependencies,feature_category,job_status,urgency |
| sidekiq_jobs_skipped_total | Counter | 16.2 | 启用 drop_sidekiq_jobs 功能标志或禁用 run_sidekiq_jobs 功能标志时跳过的作业数 | worker,action,feature_category,reason |
| sidekiq_running_jobs | Gauge | 12.2 | 正在运行的 Sidekiq 作业数量 | queue,boundary,external_dependencies,feature_category,urgency |
| sidekiq_concurrency | Gauge | 12.5 | Sidekiq 作业的最大数量 | |
| sidekiq_mem_total_bytes | Gauge | 15.3 | 分配给占用对象槽的对象和需要 malloc 的对象的字节数 | |
| sidekiq_concurrency_limit_queue_jobs | Gauge | 17.3 | 并发限制队列中等待的 Sidekiq 作业数 | worker |
| sidekiq_concurrency_limit_max_concurrent_jobs | Gauge | 17.3 | 最大并发运行 Sidekiq 作业数 | worker |
| sidekiq_concurrency_limit_deferred_jobs_total | Counter | 17.3 | 延迟的 Sidekiq 作业总数 | worker |
| sidekiq_concurrency_limit_queue_jobs_total | Counter | 17.6 | 用于计算由于并发限制而在等待队列中的作业数量的代理。它必须被解释为 max(idelta(sidekiq_concurrency_limit_queue_jobs_total[1m)) 以查看总队列大小。与其他计数器不同,此计数器的总体 rate 无意义。 | worker |
| sidekiq_concurrency_limit_current_concurrent_jobs_total | Counter | 17.6 | 用于计算并发运行作业数量的代理。它必须被解释为 max(idelta(sidekiq_concurrency_limit_current_concurrent_jobs_total[1m)) 以查看并发作业的数量。与其他计数器不同,此计数器的总体 rate 无意义。 | worker |
| geo_db_replication_lag_seconds | Gauge | 10.2 | 数据库复制延迟(秒) | url |
| geo_repositories | Gauge | 10.2 | 计划在 18.0 中删除。被 geo_project_repositories 取代。主服务器上可用的存储库总数 | url |
| geo_lfs_objects | Gauge | 10.2 | 主服务器上的 LFS 对象数量 | url |
| geo_lfs_objects_checksummed | Gauge | 14.6 | 在主服务器上成功计算校验和的 LFS 对象数量 | url |
| geo_lfs_objects_checksum_failed | Gauge | 14.6 | 在主服务器上计算校验和失败的 LFS 对象数量 | url |
| geo_lfs_objects_checksum_total | Gauge | 14.6 | 需要在主服务器上计算校验和的 LFS 对象数量 | url |
| geo_lfs_objects_synced | Gauge | 10.2 | 在次服务器上同步的可同步 LFS 对象数量 | url |
| geo_lfs_objects_failed | Gauge | 10.2 | 在次服务器上同步失败的可同步 LFS 对象数量 | url |
| geo_lfs_objects_registry | Gauge | 14.6 | 注册表中的 LFS 对象数量 | url |
| geo_lfs_objects_verified | Gauge | 14.6 | 在次服务器上成功验证的 LFS 对象数量 | url |
| geo_lfs_objects_verification_failed | Gauge | 14.6 | 在次服务器上验证失败的 LFS 对象数量 | url |
| geo_lfs_objects_verification_total | Gauge | 14.6 | 尝试在次服务器上验证的 LFS 对象数量 | url |
| geo_last_event_id | Gauge | 10.2 | 主服务器上最新事件日志条目的数据库 ID | url |
| geo_last_event_timestamp | Gauge | 10.2 | 主服务器上最新事件日志条目的 UNIX 时间戳 | url |
| geo_cursor_last_event_id | Gauge | 10.2 | 次服务器处理的事件日志的最后数据库 ID | url |
| geo_cursor_last_event_timestamp | Gauge | 10.2 | 次服务器处理的事件日志的最后 UNIX 时间戳 | url |
| geo_status_failed_total | Counter | 10.2 | 从 Geo 节点检索状态失败的次数 | url |
| geo_last_successful_status_check_timestamp | Gauge | 10.2 | 状态成功更新的最后时间戳 | url |
| geo_package_files | Gauge | 13.0 | 主服务器上的软件包文件数 | url |
| geo_package_files_checksummed | Gauge | 13.0 | 在主服务器上计算校验和的软件包文件数 | url |
| geo_package_files_checksum_failed | Gauge | 13.0 | 在主服务器上计算校验和失败的软件包文件数 | url |
| geo_package_files_synced | Gauge | 13.3 | 在次服务器上同步的可同步软件包文件数 | url |
| geo_package_files_failed | Gauge | 13.3 | 在次服务器上同步失败的可同步软件包文件数 | url |
| geo_package_files_registry | Gauge | 13.3 | 注册表中的软件包文件数 | url |
| geo_terraform_state_versions | Gauge | 13.5 | 主服务器上的 Terraform 状态版本数 | url |
| geo_terraform_state_versions_checksummed | Gauge | 13.5 | 在主服务器上成功计算校验和的 Terraform 状态版本数 | url |
| geo_terraform_state_versions_checksum_failed | 仪表盘指标(Gauge) | 13.5 | 在主节点上无法计算校验和的 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_checksum_total | 仪表盘指标(Gauge) | 13.12 | 在主节点上需要计算校验和的 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_synced | 仪表盘指标(Gauge) | 13.5 | 在从节点上已同步的可同步 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_failed | 仪表盘指标(Gauge) | 13.5 | 在从节点上同步失败的可同步 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_registry | 仪表盘指标(Gauge) | 13.5 | 注册表中的 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_verified | 仪表盘指标(Gauge) | 13.12 | 在从节点上已成功验证的 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_verification_failed | 仪表盘指标(Gauge) | 13.12 | 在从节点上验证失败的 Terraform 状态版本数量 | url |
| geo_terraform_state_versions_verification_total | 仪表盘指标(Gauge) | 13.12 | 在从节点上需要尝试验证的 Terraform 状态版本数量 | url |
| global_search_bulk_cron_queue_size | 仪表盘指标(Gauge) | 12.10 | 已弃用,计划在 18.0 版本中移除。已被 search_advanced_bulk_cron_queue_size 取代。等待同步到 Elasticsearch 的增量数据库更新数量 | |
| global_search_bulk_cron_initial_queue_size | 仪表盘指标(Gauge) | 13.1 | 已弃用,计划在 18.0 版本中移除。已被 search_advanced_bulk_cron_initial_queue_size 取代。等待同步到 Elasticsearch 的初始数据库更新数量 | |
| global_search_awaiting_indexing_queue_size | 仪表盘指标(Gauge) | 13.2 | 已弃用,计划在 18.0 版本中移除。已被 search_advanced_awaiting_indexing_queue_size 取代。在索引暂停时等待同步到 Elasticsearch 的数据库更新数量 | |
| search_advanced_bulk_cron_queue_size | 仪表盘指标(Gauge) | 17.6 | 等待同步到 Elasticsearch 的增量数据库更新数量 | |
| search_advanced_bulk_cron_initial_queue_size | 仪表盘指标(Gauge) | 17.6 | 等待同步到 Elasticsearch 的初始数据库更新数量 | |
| search_advanced_bulk_cron_embedding_queue_size | 仪表盘指标(Gauge) | 17.6 | 等待同步到 Elasticsearch 的嵌入更新数量 | |
| search_advanced_awaiting_indexing_queue_size | 仪表盘指标(Gauge) | 17.6 | 在索引暂停时等待同步到 Elasticsearch 的数据库更新数量 | |
| geo_merge_request_diffs | 仪表盘指标(Gauge) | 13.4 | 主节点上的合并请求差异数量 | url |
| geo_merge_request_diffs_checksum_total | 仪表盘指标(Gauge) | 13.12 | 主节点上需要计算校验和的合并请求差异数量 | url |
| geo_merge_request_diffs_checksummed | 仪表盘指标(Gauge) | 13.4 | 主节点上已成功计算校验和的合并请求差异数量 | url |
| geo_merge_request_diffs_checksum_failed | 仪表盘指标(Gauge) | 13.4 | 主节点上无法计算校验和的合并请求差异数量 | url |
| geo_merge_request_diffs_synced | 仪表盘指标(Gauge) | 13.4 | 从节点上已同步的可同步合并请求差异数量 | url |
| geo_merge_request_diffs_failed | 仪表盘指标(Gauge) | 13.4 | 从节点上同步失败的可同步合并请求差异数量 | url |
| geo_merge_request_diffs_registry | 仪表盘指标(Gauge) | 13.4 | 注册表中的合并请求差异数量 | url |
| geo_merge_request_diffs_verification_total | 仪表盘指标(Gauge) | 13.12 | 在从节点上需要尝试验证的合并请求差异数量 | url |
| geo_merge_request_diffs_verified | 仪表盘指标(Gauge) | 13.12 | 在从节点上已成功验证的合并请求差异数量 | url |
| geo_merge_request_diffs_verification_failed | 仪表盘指标(Gauge) | 13.12 | 在从节点上验证失败的合并请求差异数量 | url |
| geo_snippet_repositories | 仪表盘指标(Gauge) | 13.4 | 主节点上的代码片段仓库数量 | url |
| geo_snippet_repositories_checksummed | 仪表盘指标(Gauge) | 13.4 | 主节点上已计算校验和的代码片段仓库数量 | url |
| geo_snippet_repositories_checksum_failed | 仪表盘指标(Gauge) | 13.4 | 主节点上无法计算校验和的代码片段仓库数量 | url |
| geo_snippet_repositories_synced | 仪表盘指标(Gauge) | 13.4 | 从节点上已同步的可同步代码片段仓库数量 | url |
| geo_snippet_repositories_failed | 仪表盘指标(Gauge) | 13.4 | 从节点上同步失败的可同步代码片段仓库数量 | url |
| geo_snippet_repositories_registry | 仪表盘指标(Gauge) | 13.4 | 注册表中的可同步代码片段仓库数量 | url |
| geo_group_wiki_repositories | 仪表盘指标(Gauge) | 13.10 | 主节点上的群组维基仓库数量 | url |
| geo_group_wiki_repositories_checksum_total | 仪表盘指标(Gauge) | 16.3 | 主节点上需要计算校验和的群组维基仓库数量 | url |
| geo_group_wiki_repositories_checksummed | 仪表盘指标(Gauge) | 13.10 | 主节点上已成功计算校验和的群组维基仓库数量 | url |
| geo_group_wiki_repositories_checksum_failed | 仪表盘指标(Gauge) | 13.10 | 主节点上无法计算校验和的群组维基仓库数量 | url |
| geo_group_wiki_repositories_synced | 仪表盘指标(Gauge) | 13.10 | 从节点上已同步的可同步群组维基仓库数量 | url |
| geo_group_wiki_repositories_failed | 仪表盘指标(Gauge) | 13.10 | 从节点上同步失败的可同步群组维基仓库数量 | url |
| geo_group_wiki_repositories_registry | 仪表盘指标(Gauge) | 13.10 | 注册表中的群组维基仓库数量 | url |
| geo_group_wiki_repositories_verification_total | 仪表盘指标(Gauge) | 16.3 | 在从节点上需要尝试验证的群组维基仓库数量 | url |
| geo_group_wiki_repositories_verified | 仪表盘指标(Gauge) | 16.3 | 在从节点上已成功验证的群组维基仓库数量 | url |
| geo_group_wiki_repositories_verification_failed | 仪表盘指标(Gauge) | 16.3 | 在从节点上验证失败的群组维基仓库数量 | url |
| geo_pages_deployments | 仪表盘指标(Gauge) | 14.3 | 主节点上的页面部署数量 | url |
| geo_pages_deployments_checksum_total | 仪表盘指标(Gauge) | 14.6 | 主节点上需要计算校验和的页面部署数量 | url |
| geo_pages_deployments_checksummed | 仪表盘指标(Gauge) | 14.6 | 主节点上已成功计算校验和的页面部署数量 | url |
| geo_pages_deployments_checksum_failed | 仪表盘指标(Gauge) | 14.6 | 主节点上无法计算校验和的页面部署数量 | url |
| geo_pages_deployments_synced | 仪表盘指标(Gauge) | 14.3 | 从节点上已同步的可同步页面部署数量 | url |
| geo_pages_deployments_failed | 仪表盘指标(Gauge) | 14.3 | 从节点上同步失败的可同步页面部署数量 | url |
| geo_pages_deployments_registry | 仪表盘指标(Gauge) | 14.3 | 注册表中的页面部署数量 | url |
| geo_pages_deployments_verification_total | 仪表盘指标(Gauge) | 14.6 | 在从节点上需要尝试验证的页面部署数量 | url |
| geo_pages_deployments_verified | 仪表盘指标(Gauge) | 14.6 | 在从节点上已成功验证的页面部署数量 | url |
| geo_pages_deployments_verification_failed | 仪表盘指标(Gauge) | 14.6 | 在从节点上验证失败的页面部署数量 | url |
| geo_job_artifacts | 仪表盘指标(Gauge) | 14.8 | 主节点上的作业工件数量 | url |
| geo_job_artifacts_checksum_total | 仪表盘指标(Gauge) | 14.8 | 在主节点上需要计算校验和的作业工件数量 | url |
| geo_job_artifacts_checksummed | 仪表盘指标(Gauge) | 14.8 | 在主节点上已成功计算校验和的作业工件数量 | url |
| geo_job_artifacts_checksum_failed | 仪表盘指标(Gauge) | 14.8 | 在主节点上无法计算校验和的作业工件数量 | url |
| geo_job_artifacts_synced | 仪表盘指标(Gauge) | 14.8 | 在从节点上已同步的可同步作业工件数量 | url |
| geo_job_artifacts_failed | 仪表盘指标(Gauge) | 14.8 | 在从节点上同步失败的可同步作业工件数量 | url |
| geo_job_artifacts_registry | 仪表盘指标(Gauge) | 14.8 | 注册表中的作业工件数量 | url |
| geo_job_artifacts_verification_total | 仪表盘指标(Gauge) | 14.8 | 在从节点上需要尝试验证的作业工件数量 | url |
| geo_job_artifacts_verified | 仪表盘指标(Gauge) | 14.8 | 在从节点上已成功验证的作业工件数量 | url |
| geo_job_artifacts_verification_failed | 仪表盘指标(Gauge) | 14.8 | 在从节点上验证失败的作业工件数量 | url |
| limited_capacity_worker_running_jobs | 仪表盘指标(Gauge) | 13.5 | 正在运行的作业数量 | worker |
| limited_capacity_worker_max_running_jobs | 仪表盘指标(Gauge) | 13.5 | 可运行的最大作业数量 | worker |
| limited_capacity_worker_remaining_work_count | 仪表盘指标(Gauge) | 13.5 | 等待入队的作业数量 | worker |
| destroyed_job_artifacts_count_total | 计数器(Counter) | 13.6 | 已销毁的过期作业工件数量 | |
| destroyed_pipeline_artifacts_count_total | 计数器(Counter) | 13.8 | 已销毁的过期流水线工件数量 | |
| 极狐gitlab_optimistic_locking_retries | 直方图(Histogram) | 13.10 | 执行乐观重试锁的重试次数 | |
| geo_uploads | 仪表盘指标(Gauge) | 14.1 | 主节点上的上传数量 | url |
| geo_uploads_synced | 仪表盘指标(Gauge) | 14.1 | 从节点上已同步的可同步上传数量 | url |
| geo_uploads_failed | 仪表盘指标(Gauge) | 14.1 | 从节点上同步失败的可同步上传数量 | url |
| geo_uploads_registry | 仪表盘指标(Gauge) | 14.1 | 注册表中的上传数量 | url |
| geo_uploads_checksum_total | 仪表盘指标(Gauge) | 14.6 | 在主节点上需要计算校验和的上传数量 | url |
| geo_uploads_checksummed | 仪表盘指标(Gauge) | 14.6 | 在主节点上已成功计算校验和的上传数量 | url |
| geo_uploads_checksum_failed | 仪表盘指标(Gauge) | 14.6 | 在主节点上无法计算校验和的上传数量 | url |
| geo_uploads_verification_total | 仪表盘指标(Gauge) | 14.6 | 在从节点上需要尝试验证的上传数量 | url |
| geo_uploads_verified | 仪表盘指标(Gauge) | 14.6 | 在从节点上已成功验证的上传数量 | url |
| geo_uploads_verification_failed | 仪表盘指标(Gauge) | 14.6 | 在从节点上验证失败的上传数量 | url |
| geo_container_repositories | 仪表盘指标(Gauge) | 15.4 | 主节点上的容器仓库数量 | url |
| geo_container_repositories_synced | 仪表盘指标(Gauge) | 15.4 | 从节点上已同步的可同步容器仓库数量 | url |
| geo_container_repositories_failed | 仪表盘指标(Gauge) | 15.4 | 从节点上同步失败的可同步容器仓库数量 | url |
| geo_container_repositories_registry | 仪表盘指标(Gauge) | 15.4 | 注册表中的容器仓库数量 | url |
| geo_container_repositories_checksum_total | 仪表盘指标(Gauge) | 15.10 | 在主节点上已成功计算校验和的容器仓库数量 | url |
| geo_container_repositories_checksummed | 仪表盘指标(Gauge) | 15.10 | 在主节点上尝试计算校验和的容器仓库数量 | url |
| geo_container_repositories_checksum_failed | 仪表盘指标(Gauge) | 15.10 | 在主节点上无法计算校验和的容器仓库数量 | url |
| geo_container_repositories_verification_total | 仪表盘指标(Gauge) | 15.10 | 在从节点上尝试进行验证的容器仓库数量 | url |
| geo_container_repositories_verified | 仪表盘指标(Gauge) | 15.10 | 在从节点上已验证的容器仓库数量 | url |
| geo_container_repositories_verification_failed | 仪表盘指标(Gauge) | 15.10 | 在从节点上验证失败的容器仓库数量 | url |
| geo_ci_secure_files | 仪表盘指标(Gauge) | 15.3 | 主节点上的持续集成(CI)安全文件数量 | url |
| geo_ci_secure_files_checksum_total | 仪表盘指标(Gauge) | 15.3 | 在主节点上需要计算校验和的持续集成(CI)安全文件数量 | url |
| geo_ci_secure_files_checksummed | 仪表盘指标(Gauge) | 15.3 | 在主节点上已成功计算 | url |
数据库负载均衡指标
- Tier: 专业版, 旗舰版
- Offering: 私有化部署
以下指标可用:
| Metric | Type | Since | Description | Labels |
|---|---|---|---|---|
| db_load_balancing_hosts | 仪表盘指标(Gauge) | 12.3 | 当前负载均衡主机的数量 | |
| sidekiq_load_balancing_count | 计数器(Counter) | 13.11 | 使用数据一致性设置为“粘性(:sticky)”或“延迟(:delayed)”的负载均衡的 Sidekiq 作业数量 | 队列(queue), 边界(boundary), 外部依赖(external_dependencies), 功能类别(feature_category), 作业状态(job_status), 紧急程度(urgency), 数据一致性(data_consistency), 负载均衡策略(load_balancing_strategy) |
| gitlab_transaction_caught_up_replica_pick_count_total | 计数器(Counter) | 14.1 | 针对已赶上的副本的搜索尝试次数 | 结果(result) |
数据库分区指标
- Tier: 专业版, 旗舰版
- Offering: 私有化部署
以下指标可用:
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| db_partitions_present | 仪表盘指标(Gauge) | 13.4 | 当前存在的数据库分区数量 |
| db_partitions_missing | 仪表盘指标(Gauge) | 13.4 | 当前预期存在但实际缺失的数据库分区数量 |
连接池指标
这些指标记录了数据库连接池的状态,并且所有指标都有这些标签:
- class - 被记录的 Ruby 类。
- ActiveRecord::Base 是主数据库连接。
- Geo::TrackingBase 是连接到 Geo 跟踪数据库的,如果启用的话。
- host - 用于连接到数据库的主机名。
- port - 用于连接到数据库的端口。
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| gitlab_database_connection_pool_size | 仪表盘指标(Gauge) | 13.0 | 数据库连接池的总容量 |
| gitlab_database_connection_pool_connections | 仪表盘指标(Gauge) | 13.0 | 连接池中当前的连接数量 |
| gitlab_database_connection_pool_busy | 仪表盘指标(Gauge) | 13.0 | 正在使用且所属对象仍存活的连接数量 |
| gitlab_database_connection_pool_dead | 仪表盘指标(Gauge) | 13.0 | 正在使用但所属对象已失效的连接数量 |
| gitlab_database_connection_pool_idle | 仪表盘指标(Gauge) | 13.0 | 未被使用的连接数量 |
| gitlab_database_connection_pool_waiting | 仪表盘指标(Gauge) | 13.0 | 当前正在此队列中等待的线程数量 |
Ruby 指标
一些基本的 Ruby 运行指标可用:
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| ruby_gc_duration_seconds | 计数器(Counter) | 11.1 | Ruby 进行垃圾回收(GC)所花费的时间 |
| ruby_gc_stat_... | 仪表盘指标(Gauge) | 11.1 | 来自 GC.stat 的各种指标 |
| ruby_gc_stat_ext_heap_fragmentation | 仪表盘指标(Gauge) | 15.2 | Ruby 堆的碎片化程度,以存活对象与伊甸园槽位的比例衡量(范围从 0 到 1) |
| ruby_file_descriptors | 仪表盘指标(Gauge) | 11.1 | 每个进程的文件描述符数量 |
| ruby_sampler_duration_seconds | 计数器(Counter) | 11.1 | 收集统计信息所花费的时间 |
| ruby_process_cpu_seconds_total | 仪表盘指标(Gauge) | 12.0 | 每个进程的 CPU 总使用时间 |
| ruby_process_max_fds | 仪表盘指标(Gauge) | 12.0 | 每个进程可打开的最大文件描述符数量 |
| ruby_process_resident_memory_bytes | 仪表盘指标(Gauge) | 12.0 | 进程的内存使用量(常驻集大小,RSS) |
| ruby_process_resident_anon_memory_bytes | 仪表盘指标(Gauge) | 15.6 | 进程的匿名内存使用量(常驻集大小,RSS) |
| ruby_process_resident_file_memory_bytes | 仪表盘指标(Gauge) | 15.6 | 进程由文件支持的内存使用量(常驻集大小,RSS) |
| ruby_process_unique_memory_bytes | 仪表盘指标(Gauge) | 13.0 | 进程的内存使用量(唯一集大小,USS) |
| ruby_process_proportional_memory_bytes | 仪表盘指标(Gauge) | 13.0 | 进程的内存使用量(比例集大小,PSS) |
| ruby_process_start_time_seconds | 仪表盘指标(Gauge) | 12.0 | 进程启动时间的 UNIX 时间戳 |
Puma 指标
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| puma_workers | 仪表盘指标(Gauge) | 12.0 | 工作进程的总数 |
| puma_running_workers | 仪表盘指标(Gauge) | 12.0 | 已启动的工作进程数量 |
| puma_stale_workers | 仪表盘指标(Gauge) | 12.0 | 旧的工作进程数量 |
| puma_running | 仪表盘指标(Gauge) | 12.0 | 正在运行的线程数量 |
| puma_queued_connections | 仪表盘指标(Gauge) | 12.0 | 该工作进程的“待处理”集合中等待工作线程处理的连接数量 |
| puma_active_connections | 仪表盘指标(Gauge) | 12.0 | 正在处理请求的线程数量 |
| puma_pool_capacity | 仪表盘指标(Gauge) | 12.0 | 该工作进程当前能够处理的请求数量 |
| puma_max_threads | 仪表盘指标(Gauge) | 12.0 | 工作线程的最大数量 |
| puma_idle_threads | 仪表盘指标(Gauge) | 12.0 | 已生成但未处理请求的线程数量 |
Redis 指标
这些客户端指标旨在补充 Redis 服务器指标。这些指标根据每个Redis 实例分解。这些指标都有一个 storage 标签,指示 Redis 实例。例如,cache 或 shared_state。
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| gitlab_redis_client_exceptions_total | 计数器 | 13.2 | Redis 客户端异常的数量,按异常类细分 |
| gitlab_redis_client_requests_total | 计数器 | 13.2 | Redis 客户端请求的数量 |
| gitlab_redis_client_requests_duration_seconds | 直方图 | 13.2 | Redis 请求延迟,不包括阻塞命令 |
| gitlab_redis_client_redirections_total | 计数器 | 15.10 | Redis 集群 MOVED/ASK 重定向的数量,按重定向类型细分 |
| gitlab_redis_client_requests_pipelined_commands | 直方图 | 16.4 | 发送到单个 Redis 服务器的每个管道中的命令数量 |
| gitlab_redis_client_pipeline_redirections_count | 直方图 | 17.0 | 管道中 Redis 集群重定向的数量 |
Git LFS 指标
用于跟踪各种 Git LFS 功能的指标。
| 指标 | 类型 | 自版本 | 描述 |
|---|---|---|---|
| gitlab_sli_lfs_update_objects_total | 计数器 | 16.10 | 总共更新的大文件存储(LFS)对象数量 |
| gitlab_sli_lfs_update_objects_error_total | 计数器 | 16.10 | 总共更新 LFS 对象时出现的错误数量 |
| gitlab_sli_lfs_check_objects_total | 计数器 | 16.10 | 总共检查的 LFS 对象数量 |
| gitlab_sli_lfs_check_objects_error_total | 计数器 | 16.10 | 总共检查 LFS 对象时出现的错误数量 |
| gitlab_sli_lfs_validate_link_objects_total | 计数器 | 16.10 | 总共验证的 LFS 链接对象数量 |
| gitlab_sli_lfs_validate_link_objects_error_total | 计数器 | 16.10 | 总共验证 LFS 链接对象时出现的错误数量 |
指标共享目录
极狐GitLab Prometheus 客户端需要一个目录来存储在多进程服务之间共享的指标数据。这些文件在所有运行于 Puma 服务器的实例之间共享。该目录必须可供所有运行的 Puma 的进程访问,否则指标无法正常工作。
该目录的位置是通过环境变量 prometheus_multiproc_dir 配置的。为了获得最佳性能,请在 tmpfs 中创建此目录。
如果使用 Linux 软件包安装极狐GitLab,并且 tmpfs 可用,那么极狐GitLab 会为您配置指标目录。