2.15.8. 管理通知配置


您可以使用命令行界面列出、获取和删除存储桶的通知配置。

先决条件

  • 一个正在运行的 Red Hat Ceph Storage 集群。
  • 配置了 Ceph 对象网关。

流程

  • 列出所有存储桶通知配置:

    语法

    radosgw-admin notification list --bucket=BUCKET_NAME

    Example

    [root@host04 ~]# radosgw-admin notification list --bucket bkt2
    {
        "notifications": [
            {
                "TopicArn": "arn:aws:sns:default::topic1",
                "Id": "notif1",
                "Events": [
                    "s3:ObjectCreated:*",
                    "s3:ObjectRemoved:*"
                ],
                "Filter": {
                    "S3Key": {},
                    "S3Metadata": {},
                    "S3Tags": {}
                }
            },
            {
                "TopicArn": "arn:aws:sns:default::topic1",
                "Id": "notif2",
                "Events": [
                    "s3:ObjectSynced:*"
                ],
                "Filter": {
                    "S3Key": {},
                    "S3Metadata": {},
                    "S3Tags": {}
                }
            }
        ]
    }

  • 获取存储桶通知配置:

    语法

    radosgw-admin notification get --bucket BUCKET_NAME --notification-id NOTIFICATION_ID

    Example

    [root@host04 ~]# radosgw-admin notification get --bucket bkt2 --notification-id notif2
    {
        "TopicArn": "arn:aws:sns:default::topic1",
        "Id": "notif2",
        "Events": [
            "s3:ObjectSynced:*"
        ],
        "Filter": {
            "S3Key": {},
            "S3Metadata": {},
            "S3Tags": {}
        }
    }

  • 删除特定的存储桶通知配置:

    语法

    radosgw-admin notification rm --bucket BUCKET_NAME [--notification-id NOTIFICATION_ID]

    此处,NOTIFICATION_ID 是可选的。如果没有指定,命令会删除该存储桶的所有通知配置。

    Example

    [root@host04 ~]# radosgw-admin notification rm --bucket bkt2 --notification-id notif1

Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

關於紅帽

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

让开源更具包容性

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

关于红帽文档

Legal Notice

Theme

© 2026 Red Hat
返回顶部