13.2. 指标简介


Red Hat Quay 提供了相关的指标来帮助监控 registry,包括常规 registry 使用情况、上传、下载、垃圾回收和身份验证的指标。

13.2.1. 常规 registry 统计

常规 registry 统计可指示 registry 的增长量。

Expand
指标名称Description

quay_user_rows

数据库中的用户数

quay_robot_rows

数据库中机器人帐户的数量

quay_org_rows

数据库中的组织数

quay_repository_rows

数据库中的软件仓库数

quay_security_scanning_unscanned_images_remaining_total

最新安全扫描程序未扫描的镜像数

指标输出示例

# HELP quay_user_rows number of users in the database
# TYPE quay_user_rows gauge
quay_user_rows{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="65",process_name="globalpromstats.py"} 3

# HELP quay_robot_rows number of robot accounts in the database
# TYPE quay_robot_rows gauge
quay_robot_rows{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="65",process_name="globalpromstats.py"} 2

# HELP quay_org_rows number of organizations in the database
# TYPE quay_org_rows gauge
quay_org_rows{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="65",process_name="globalpromstats.py"} 2

# HELP quay_repository_rows number of repositories in the database
# TYPE quay_repository_rows gauge
quay_repository_rows{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="65",process_name="globalpromstats.py"} 4

# HELP quay_security_scanning_unscanned_images_remaining number of images that are not scanned by the latest security scanner
# TYPE quay_security_scanning_unscanned_images_remaining gauge
quay_security_scanning_unscanned_images_remaining{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 5
Copy to Clipboard Toggle word wrap

13.2.2. 队列项

队列项目 指标提供有关 Quay 用于管理工作的多个队列的信息。

Expand
指标名称Description

quay_queue_items_available

特定队列中的项数

quay_queue_items_locked

正在运行的项目数

quay_queue_items_available_unlocked

等待处理的项目数

指标标签

  • queue_name: 队列的名称。其中之一:

    • exportactionlogs: 用于导出操作日志的队列请求。然后,处理这些日志并将其放置在存储中。然后,通过电子邮件将链接发送到请求者。
    • namespacegc:排队进行垃圾回收的命名空间
    • notification: 要发出的存储库通知的队列
    • repositorygc: Queued 软件仓库被垃圾回收
    • secscanv4: 特定于 Clair V4 的通知队列
    • dockerfilebuild: Quay docker 构建队列
    • imagestoragereplication: Queued blob 在多个存储间复制
    • chunk_cleanup: 需要删除的 Queued blob 片段。这仅供部分存储实施使用,如 Swift。

例如,队列标记的 repositorygc 包含由存储库垃圾回收 worker 标记为删除的存储库。对于带有 repositorygcqueue_name 标签的指标:

  • quay_queue_items_locked 是当前被删除的存储库数量。
  • quay_queue_items_available_unlocked 是 worker 处理的存储库数量。

指标输出示例

# HELP quay_queue_items_available number of queue items that have not expired
# TYPE quay_queue_items_available gauge
quay_queue_items_available{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="63",process_name="exportactionlogsworker.py",queue_name="exportactionlogs"} 0
...

# HELP quay_queue_items_available_unlocked number of queue items that have not expired and are not locked
# TYPE quay_queue_items_available_unlocked gauge
quay_queue_items_available_unlocked{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="63",process_name="exportactionlogsworker.py",queue_name="exportactionlogs"} 0
...

# HELP quay_queue_items_locked number of queue items that have been acquired
# TYPE quay_queue_items_locked gauge
quay_queue_items_locked{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="63",process_name="exportactionlogsworker.py",queue_name="exportactionlogs"} 0
Copy to Clipboard Toggle word wrap

13.2.3. 垃圾回收指标

这些指标显示已从垃圾回收(gc)中删除了多少资源。它们显示 gc worker 运行的次数,以及删除多少个命名空间、存储库和 Blob。

Expand
指标名称Description

quay_gc_iterations_total

GCWorker 的迭代数

quay_gc_namespaces_purged_total

NamespaceGCWorker 清除的命名空间数量

quay_gc_repos_purged_total

RepositoryGCWorker 或 NamespaceGCWorker 清除的存储库数量

quay_gc_storage_blobs_deleted_total

删除的存储 Blob 数量

指标输出示例

# TYPE quay_gc_iterations_created gauge
quay_gc_iterations_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.6317823190189714e+09
...

# HELP quay_gc_iterations_total number of iterations by the GCWorker
# TYPE quay_gc_iterations_total counter
quay_gc_iterations_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0
...

# TYPE quay_gc_namespaces_purged_created gauge
quay_gc_namespaces_purged_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.6317823190189433e+09
...

# HELP quay_gc_namespaces_purged_total number of namespaces purged by the NamespaceGCWorker
# TYPE quay_gc_namespaces_purged_total counter
quay_gc_namespaces_purged_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0
....

# TYPE quay_gc_repos_purged_created gauge
quay_gc_repos_purged_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.631782319018925e+09
...

# HELP quay_gc_repos_purged_total number of repositories purged by the RepositoryGCWorker or NamespaceGCWorker
# TYPE quay_gc_repos_purged_total counter
quay_gc_repos_purged_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0
...

# TYPE quay_gc_storage_blobs_deleted_created gauge
quay_gc_storage_blobs_deleted_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.6317823190189059e+09
...

# HELP quay_gc_storage_blobs_deleted_total number of storage blobs deleted
# TYPE quay_gc_storage_blobs_deleted_total counter
quay_gc_storage_blobs_deleted_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0
...
Copy to Clipboard Toggle word wrap

13.2.3.1. multipart 上传指标

multipart 上传指标显示 blob 上传到存储的数量(S3、Ragdos、GoogleCloudStorage、RHOCS)。当 Quay 无法正确将 Blob 上传到存储时,它们可以帮助识别问题。

Expand
指标名称Description

quay_multipart_uploads_started_total

启动的上传到 Quay 存储的 multipart 数

quay_multipart_uploads_completed_total

完成的上传到 Quay 存储的 multipart 数

指标输出示例

# TYPE quay_multipart_uploads_completed_created gauge
quay_multipart_uploads_completed_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.6317823308284895e+09
...

# HELP quay_multipart_uploads_completed_total number of multipart uploads to Quay storage that completed
# TYPE quay_multipart_uploads_completed_total counter
quay_multipart_uploads_completed_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0

# TYPE quay_multipart_uploads_started_created gauge
quay_multipart_uploads_started_created{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 1.6317823308284352e+09
...

# HELP quay_multipart_uploads_started_total number of multipart uploads to Quay storage that started
# TYPE quay_multipart_uploads_started_total counter
quay_multipart_uploads_started_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="208",process_name="secscan:application"} 0
...
Copy to Clipboard Toggle word wrap

13.2.4. 镜像拉取/拉取指标

与推送和拉取镜像相关的可用指标数据的数量。

13.2.4.1. 镜像拉取(pull)总数

Expand
指标名称Description

quay_registry_image_pulls_total

从 registry 中下载的镜像数量。

指标标签

  • 协议: 所用的 registry 协议(应该总是为 v2)
  • ref: 用于拉取 - 标签、清单的 ref
  • status: 请求的 http 返回代码

13.2.4.2. 拉取(pull)的镜像字节

Expand
指标名称Description

quay_registry_image_pulled_estimated_bytes_total

从 registry 下载的字节数

指标标签

  • 协议: 所用的 registry 协议(应该总是为 v2)

13.2.4.3. 镜像推送总数

Expand
指标名称Description

quay_registry_image_pushes_total

从 registry 上传的镜像数量。

指标标签

  • 协议: 所用的 registry 协议(应该总是为 v2)
  • pstatus: http 返回代码
  • pmedia_type: 上传的清单类型

13.2.4.4. 推送的镜像字节

Expand
指标名称Description

quay_registry_image_pushed_bytes_total

上传到 registry 的字节数

指标输出示例

# HELP quay_registry_image_pushed_bytes_total number of bytes pushed to the registry
# TYPE quay_registry_image_pushed_bytes_total counter
quay_registry_image_pushed_bytes_total{host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="221",process_name="registry:application"} 0
...
Copy to Clipboard Toggle word wrap

13.2.5. 身份验证指标

身份验证指标提供了身份验证请求的数量,根据类型进行标记,以及它是否成功。例如,可以利用此指标来监控失败的基本身份验证请求。

Expand
指标名称Description

quay_authentication_attempts_total

registry 和 API 中的身份验证尝试数

指标标签

  • auth_kind: 使用的 auth 类型,包括:

    • 基本的
    • oauth
    • credentials
  • success: true 或 false

指标输出示例

# TYPE quay_authentication_attempts_created gauge
quay_authentication_attempts_created{auth_kind="basic",host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="221",process_name="registry:application",success="True"} 1.6317843039374158e+09
...

# HELP quay_authentication_attempts_total number of authentication attempts across the registry and API
# TYPE quay_authentication_attempts_total counter
quay_authentication_attempts_total{auth_kind="basic",host="example-registry-quay-app-6df87f7b66-9tfn6",instance="",job="quay",pid="221",process_name="registry:application",success="True"} 2
...
Copy to Clipboard Toggle word wrap

返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat