Cloud Load Balancingのアクセスログとクエリのサンプル

記事タイトルとURLをコピーする

G-gen の杉村です。2024年10月現在で利用可能な12種類の Cloud Load Balancing のアクセスログは、それぞれフォーマットが異なります。アクセスログをクエリするための Cloud Logging クエリと、アクセスログのサンプルを掲載します。

はじめに

Cloud Load Balancing は、Google Cloud(旧称 GCP)のフルマネージドのロードバランサーです。2024年10月現在、Cloud Load Balancing には用途によって異なる12種類のロードバランサーが存在します。

Cloud Load Balancing を構成するコンポーネントの1つであるバックエンドサービスでログ出力を有効化することで、アクセスログを Cloud Logging に出力できます。しかし、12種類あるそれぞれのロードバランサーでは、アクセスログのフォーマットが異なります。そのため、監査目的で組織全体のすべてのロードバランサーのアクセスログを Cloud Logging の集約シンクで集積したいというようなシチュエーションでログを網羅的に収集するには、ログのフィルタリングのためのクエリを適切に設定する必要があります。

当記事では、12種類の Cloud Load Balancing のアクセスログをフィルタリングするための方法や、各ロードバランサーのアクセスログのサンプルを掲載します。

なお、Cloud Logging や集約シンクについては、以下の記事を参照してください。

blog.g-gen.co.jp

アクセスログのフィルタリング

フィールドに入る値の違い

12種類のロードバランサーについて、アクセスログをフィルタするための Cloud Logging クエリについて検討します。

Cloud Logging で特定の種類のログエントリをフィルタするには、以下のようなフィールドでフィルタすることが考えられます。

  • resource.type
  • jsonPayload.@type
  • logName

例として、VPC Flow Logs のログエントリを抽出したい場合、以下のようなクエリになります(my-project はプロジェクト ID に置き換えてください。以下同じ)。

logName="projects/my-project/logs/compute.googleapis.com%2Fvpc_flows"

しかし Cloud Load Balancing においては、12種類のロードバランサーでそれぞれこれらのフィールドに入る値が異なっていることがわかります。

同じ Cloud Load Balancing というサービス名がついていても、ロードバランサー種別によって、その内部構造や成り立ち(開発の経緯)が大きく異なっていることが、この違いの根本にあるように思われます。

コピー&ペーストできるよう、同じ表を以下にテキスト形式でも掲載します。

# ロードバランサー名 resource.type jsonPayload.@type logName
1 Global external Application Load Balancer http_load_balancer type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/requests
2 Classic Global external Application Load Balancer http_load_balancer type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/requests
3 Regional external Application Load Balancer http_external_regional_lb_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fexternal_regional_requests
4 Regional internal Application Load Balancer internal_http_lb_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Frequests
5 Cross-region internal Application Load Balancer internal_http_lb_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Frequests
6 Global external proxy Network Load Balancer l4_proxy_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections
7 Classic Global external proxy Network Load Balancer tcp_ssl_proxy_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/requests
8 Regional external proxy Network Load Balancer l4_proxy_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections
9 Regional internal proxy Network Load Balancer l4_proxy_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections
10 Cross-region internal proxy Network Load Balancer l4_proxy_rule type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections
11 Regional external passthrough Network Load Balancer loadbalancing.googleapis.com/ExternalNetworkLoadBalancerRule type.googleapis.com/google.cloud.loadbalancing.type.ExternalNetworkLoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fflows
12 Regional internal passthrough Network Load Balancer loadbalancing.googleapis.com/InternalNetworkLoadBalancerRule type.googleapis.com/google.cloud.loadbalancing.type.InternalNetworkLoadBalancerLogEntry projects/my-project/logs/loadbalancing.googleapis.com%2Fflows

公式ドキュメントの記述

Google Cloud の公式ドキュメントには、ロードバランサーごとに、アクセスログへのクエリ方法が記載されています。resource.type でのフィルタリング手順が記載されているドキュメントもあれば、logName が記載されている場合もあります。

Cloud Logging 用クエリ

表に示したように、12種類すべてのロードバランサーが共通して持つ値はありません。ドキュメントの記述に基づいた各ロードバランサーへのクエリを、以下のように OR 条件を用いて繋げることで、すべての種類のアクセスログを抽出することができます(2024年10月の当社環境による検証結果でも確認)。

クエリ1

(
  resource.type=(
    "http_load_balancer"
    OR "http_external_regional_lb_rule"
    OR "internal_http_lb_rule"
    OR "tcp_ssl_proxy_rule"
  )
  OR logName:(
    "logs/loadbalancing.googleapis.com%2Fconnections"
    OR "logs/loadbalancing.googleapis.com%2Fflows"
  )
)

あるいは以下のように、jsonPayload.@type フィールドに対して、部分一致を示す : 記号でフィルタすることでもアクセスログを抽出できます。

クエリ2

jsonPayload.@type:"type.googleapis.com/google.cloud.loadbalancing.type"

上記のクエリは短くてシンプルである一方、公式ドキュメントの手順に基づいていません。さらに、resource.typelogName フィールドの方が、デフォルトでインデックスが作成されているため、より高速です。

なお部分一致検索は、完全一致での検索に比較してパフォーマンスが悪いとされています。最初のクエリでも、logName フィールドに対して部分一致(:)で検索しています。もしクエリのパフォーマンスが重要な場合、プロジェクト名を明示してクエリするか、前掲の表に基づいて resource.type フィールドに対してクエリしてください。

クエリ3

(
  resource.type=(
    "http_load_balancer"
    OR "http_external_regional_lb_rule"
    OR "internal_http_lb_rule"
    OR "tcp_ssl_proxy_rule"
  )
  OR logName=(
    "projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections"
    OR "projects/my-project/logs/loadbalancing.googleapis.com%2Fflows"
  )
)

クエリ4

resource.type=("http_load_balancer"
    OR "http_external_regional_lb_rule"
    OR "internal_http_lb_rule"
    OR "l4_proxy_rule"
    OR "tcp_ssl_proxy_rule"
    OR "loadbalancing.googleapis.com/ExternalNetworkLoadBalancerRule"
    OR "loadbalancing.googleapis.com/InternalNetworkLoadBalancerRule"
)

アクセスログのサンプル

以下に、12種類の各ロードバランサーのアクセスログのサンプルを掲載します。設定の条件によって、ログに含まれるフィールドが異なる場合があることをご了承ください。

Global external Application Load Balancer

{
  "insertId": "1hl3dx4f9l9kl0",
  "jsonPayload": {
    "enforcedSecurityPolicy": {
      "rateLimitAction": {
        "key": "119.173.43.159",
        "outcome": "RATE_LIMIT_THRESHOLD_CONFORM"
      },
      "outcome": "ACCEPT",
      "priority": 2147483646,
      "name": "default-security-policy-for-backend-service-be",
      "configuredAction": "THROTTLE"
    },
    "cacheDecision": [
      "RESPONSE_HAS_ETAG",
      "RESPONSE_HAS_LAST_MODIFIED",
      "RESPONSE_HAS_CONTENT_TYPE",
      "CACHE_MODE_USE_ORIGIN_HEADERS"
    ],
    "remoteIp": "119.173.43.159",
    "securityPolicyRequestData": {
      "remoteIpInfo": {
        "regionCode": "JP"
      }
    },
    "backendTargetProjectNumber": "projects/1234567890",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "statusDetails": "response_sent_by_backend"
  },
  "httpRequest": {
    "requestMethod": "GET",
    "requestUrl": "http://34.128.128.201/",
    "requestSize": "78",
    "status": 200,
    "responseSize": "251",
    "userAgent": "curl/7.88.1",
    "remoteIp": "119.173.43.159",
    "serverIp": "10.146.15.212",
    "latency": "0.006456s"
  },
  "resource": {
    "type": "http_load_balancer",
    "labels": {
      "backend_service_name": "be",
      "zone": "global",
      "forwarding_rule_name": "fe",
      "url_map_name": "global-external-alb",
      "target_proxy_name": "global-external-alb-target-proxy",
      "project_id": "my-project"
    }
  },
  "timestamp": "2024-10-19T00:25:02.709671Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/requests",
  "trace": "projects/my-project/traces/91b497c4aa913d1adb6cb7239ff7c18f",
  "receiveTimestamp": "2024-10-19T00:25:03.445640111Z",
  "spanId": "c85d614f1f6380f7"
}

Classic Global external Application Load Balancer

{
  "insertId": "d1hn5ifh5uld4",
  "jsonPayload": {
    "remoteIp": "34.84.45.157",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "cacheDecision": [
      "RESPONSE_HAS_ETAG",
      "RESPONSE_HAS_LAST_MODIFIED",
      "RESPONSE_HAS_CONTENT_TYPE",
      "CACHE_MODE_USE_ORIGIN_HEADERS"
    ],
    "statusDetails": "response_sent_by_backend",
    "backendTargetProjectNumber": "projects/1234567890"
  },
  "httpRequest": {
    "requestMethod": "GET",
    "requestUrl": "http://34.160.74.92/",
    "requestSize": "76",
    "status": 200,
    "responseSize": "251",
    "userAgent": "curl/7.74.0",
    "remoteIp": "34.84.45.157",
    "serverIp": "10.146.15.212",
    "latency": "0.004245s"
  },
  "resource": {
    "type": "http_load_balancer",
    "labels": {
      "target_proxy_name": "classic-global-external-alb-target-proxy",
      "forwarding_rule_name": "classic-global-external-alb-fe",
      "project_id": "my-project",
      "backend_service_name": "classic-global-external-alb-be",
      "url_map_name": "classic-global-external-alb",
      "zone": "global"
    }
  },
  "timestamp": "2024-10-19T01:26:45.677162Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/requests",
  "trace": "projects/my-project/traces/fd0787f95c1d8c088f56dd3a0fc645a9",
  "receiveTimestamp": "2024-10-19T01:26:46.011597715Z",
  "spanId": "0600c851dd6caba0"
}

Regional external Application Load Balancer

{
  "insertId": "r6zhmhe3tin0",
  "jsonPayload": {
    "securityPolicyRequestData": {
      "remoteIpInfo": {
        "asn": 9824,
        "regionCode": "JP"
      }
    },
    "enforcedSecurityPolicy": {
      "configuredAction": "THROTTLE",
      "outcome": "ACCEPT",
      "priority": 2147483646,
      "name": "default-security-policy-for-be-regional-external-alb",
      "rateLimitAction": {
        "key": "119.173.43.159",
        "outcome": "RATE_LIMIT_THRESHOLD_CONFORM"
      }
    },
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "backendTargetProjectNumber": "projects/1234567890"
  },
  "httpRequest": {
    "requestMethod": "GET",
    "requestUrl": "http://34.146.179.192/",
    "requestSize": "78",
    "status": 200,
    "responseSize": "251",
    "userAgent": "curl/7.88.1",
    "remoteIp": "119.173.43.159:45490",
    "serverIp": "10.146.15.212:80",
    "latency": "0.006646s",
    "protocol": "HTTP/1.1"
  },
  "resource": {
    "type": "http_external_regional_lb_rule",
    "labels": {
      "forwarding_rule_name": "fe-regional-external-alb",
      "network_name": "default",
      "url_map_name": "regional-external-alb",
      "backend_target_type": "BACKEND_SERVICE",
      "target_proxy_name": "regional-external-alb-target-proxy",
      "backend_type": "INSTANCE_GROUP",
      "matched_url_path_rule": "UNMATCHED",
      "backend_name": "my-unmanaged-instance-group",
      "backend_target_name": "be-regional-external-alb",
      "project_id": "my-project",
      "region": "asia-northeast1",
      "backend_scope": "asia-northeast1-b",
      "backend_scope_type": "ZONE"
    }
  },
  "timestamp": "2024-10-19T00:26:57.853386Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fexternal_regional_requests",
  "receiveTimestamp": "2024-10-19T00:27:01.596354155Z"
}

Regional internal Application Load Balancer

{
  "insertId": "1g7z8yle6gehh",
  "jsonPayload": {
    "backendTargetProjectNumber": "projects/1234567890",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry"
  },
  "httpRequest": {
    "requestMethod": "GET",
    "requestUrl": "http://10.146.0.6/",
    "requestSize": "74",
    "status": 200,
    "responseSize": "251",
    "userAgent": "curl/7.74.0",
    "remoteIp": "10.146.15.212:34372",
    "serverIp": "10.146.15.212:80",
    "latency": "0.005247s",
    "protocol": "HTTP/1.1"
  },
  "resource": {
    "type": "internal_http_lb_rule",
    "labels": {
      "project_id": "my-project",
      "matched_url_path_rule": "UNMATCHED",
      "backend_target_type": "BACKEND_SERVICE",
      "backend_scope_type": "ZONE",
      "backend_type": "INSTANCE_GROUP",
      "url_map_name": "regional-internal-alb",
      "target_proxy_name": "regional-internal-alb-target-proxy",
      "forwarding_rule_name": "regional-internal-alb-fe",
      "backend_name": "my-unmanaged-instance-group",
      "backend_scope": "asia-northeast1-b",
      "backend_target_name": "regional-internal-alb-be",
      "network_name": "default",
      "region": "asia-northeast1"
    }
  },
  "timestamp": "2024-10-19T01:07:22.171311Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Frequests",
  "receiveTimestamp": "2024-10-19T01:07:31.591492497Z"
}

Cross-region internal Application Load Balancer

{
  "insertId": "nvlidgezxrk5",
  "jsonPayload": {
    "backendTargetProjectNumber": "projects/1234567890",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry"
  },
  "httpRequest": {
    "requestMethod": "GET",
    "requestUrl": "http://10.146.0.7/",
    "requestSize": "74",
    "status": 200,
    "responseSize": "251",
    "userAgent": "curl/7.74.0",
    "remoteIp": "10.146.15.212:49148",
    "serverIp": "10.146.15.212:80",
    "latency": "0.000594s",
    "protocol": "HTTP/1.1"
  },
  "resource": {
    "type": "internal_http_lb_rule",
    "labels": {
      "target_proxy_name": "cross-region-internal-alb-target-proxy",
      "url_map_name": "cross-region-internal-alb",
      "region": "asia-northeast1",
      "project_id": "my-project",
      "network_name": "default",
      "backend_target_name": "cross-region-internal-alb-be",
      "backend_type": "INSTANCE_GROUP",
      "backend_scope_type": "ZONE",
      "backend_name": "my-unmanaged-instance-group",
      "backend_scope": "asia-northeast1-b",
      "matched_url_path_rule": "UNMATCHED",
      "forwarding_rule_name": "cross-region-internal-alb-fe",
      "backend_target_type": "BACKEND_SERVICE"
    }
  },
  "timestamp": "2024-10-19T01:13:07.097824Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Frequests",
  "receiveTimestamp": "2024-10-19T01:13:11.841628180Z"
}

Global external proxy Network Load Balancer

{
  "insertId": "wqqyu5e6bgx2",
  "jsonPayload": {
    "endTime": "2024-10-19T01:34:01.839237Z",
    "startTime": "2024-10-19T01:34:01.837981Z",
    "connection": {
      "clientIp": "10.146.15.212",
      "serverPort": 80,
      "protocol": 6,
      "clientPort": 58774,
      "serverIp": "10.146.15.233"
    },
    "serverBytesReceived": "77",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "serverBytesSent": "258"
  },
  "resource": {
    "type": "l4_proxy_rule",
    "labels": {
      "forwarding_rule_name": "regional-internal-proxy-nlb-fe",
      "network_name": "default",
      "protocol": "TCP",
      "region": "asia-northeast1",
      "backend_scope": "asia-northeast1-b",
      "load_balancing_scheme": "INTERNAL_MANAGED",
      "target_proxy_name": "regional-internal-proxy-nlb-target-proxy",
      "backend_name": "my-unmanaged-instance-group",
      "backend_target_name": "regional-internal-proxy-nlb",
      "backend_scope_type": "ZONE",
      "project_id": "my-project",
      "backend_type": "INSTANCE_GROUP",
      "backend_target_type": "BACKEND_SERVICE"
    }
  },
  "timestamp": "2024-10-19T01:34:01.837981Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections",
  "receiveTimestamp": "2024-10-19T01:34:06.969020769Z"
}

Classic Global external proxy Network Load Balancer

{
  "insertId": "g5348lf4ffk6m",
  "jsonPayload": {
    "remoteIp": "34.84.45.157",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "statusDetails": "response_sent_by_backend",
    "backendTargetProjectNumber": "projects/1234567890"
  },
  "resource": {
    "type": "tcp_ssl_proxy_rule",
    "labels": {
      "region": "global",
      "backend_scope": "asia-northeast1-b",
      "project_id": "my-project",
      "forwarding_rule_name": "classic-global-external-proxy-nlb-fe",
      "backend_target_name": "classic-global-external-proxy-nlb",
      "backend_name": "7592391117369982738",
      "target_proxy_name": "classic-global-external-proxy-target-proxy",
      "backend_scope_type": "ZONE",
      "backend_target_type": "BACKEND_SERVICE",
      "backend_type": "INSTANCE_GROUP"
    }
  },
  "timestamp": "2024-10-19T01:28:26.522314Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/requests",
  "receiveTimestamp": "2024-10-19T01:28:28.589962783Z"
}

Regional external proxy Network Load Balancer

{
  "insertId": "eqlb0pe8i7nf",
  "jsonPayload": {
    "startTime": "2024-10-19T01:32:45.769843Z",
    "endTime": "2024-10-19T01:32:45.776569Z",
    "serverBytesReceived": "76",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "connection": {
      "clientIp": "34.84.45.157",
      "serverPort": 80,
      "clientPort": 39902,
      "protocol": 6,
      "serverIp": "34.85.18.103"
    },
    "serverBytesSent": "258"
  },
  "resource": {
    "type": "l4_proxy_rule",
    "labels": {
      "target_proxy_name": "regional-external-proxy-nlb-target-proxy",
      "protocol": "TCP",
      "forwarding_rule_name": "regional-external-proxy-nlb-fe",
      "backend_target_type": "BACKEND_SERVICE",
      "backend_type": "INSTANCE_GROUP",
      "project_id": "my-project",
      "backend_name": "my-unmanaged-instance-group",
      "load_balancing_scheme": "EXTERNAL_MANAGED",
      "backend_target_name": "regional-external-proxy-nlb",
      "region": "asia-northeast1",
      "network_name": "default",
      "backend_scope_type": "ZONE",
      "backend_scope": "asia-northeast1-b"
    }
  },
  "timestamp": "2024-10-19T01:32:45.769843Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections",
  "receiveTimestamp": "2024-10-19T01:32:51.445900382Z"
}

Regional internal proxy Network Load Balancer

{
  "insertId": "wqqyu5e6bgx2",
  "jsonPayload": {
    "endTime": "2024-10-19T01:34:01.839237Z",
    "startTime": "2024-10-19T01:34:01.837981Z",
    "connection": {
      "clientIp": "10.146.15.212",
      "serverPort": 80,
      "protocol": 6,
      "clientPort": 58774,
      "serverIp": "10.146.15.233"
    },
    "serverBytesReceived": "77",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry",
    "serverBytesSent": "258"
  },
  "resource": {
    "type": "l4_proxy_rule",
    "labels": {
      "forwarding_rule_name": "regional-internal-proxy-nlb-fe",
      "network_name": "default",
      "protocol": "TCP",
      "region": "asia-northeast1",
      "backend_scope": "asia-northeast1-b",
      "load_balancing_scheme": "INTERNAL_MANAGED",
      "target_proxy_name": "regional-internal-proxy-nlb-target-proxy",
      "backend_name": "my-unmanaged-instance-group",
      "backend_target_name": "regional-internal-proxy-nlb",
      "backend_scope_type": "ZONE",
      "project_id": "my-project",
      "backend_type": "INSTANCE_GROUP",
      "backend_target_type": "BACKEND_SERVICE"
    }
  },
  "timestamp": "2024-10-19T01:34:01.837981Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections",
  "receiveTimestamp": "2024-10-19T01:34:06.969020769Z"
}

Cross-region internal proxy Network Load Balancer

{
  "insertId": "1kbs0nme7cs09",
  "jsonPayload": {
    "serverBytesSent": "258",
    "serverBytesReceived": "77",
    "connection": {
      "serverIp": "10.146.15.234",
      "serverPort": 80,
      "clientPort": 38876,
      "protocol": 6,
      "clientIp": "10.146.15.212"
    },
    "startTime": "2024-10-19T01:40:48.650089Z",
    "endTime": "2024-10-19T01:40:48.656509Z",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.LoadBalancerLogEntry"
  },
  "resource": {
    "type": "l4_proxy_rule",
    "labels": {
      "protocol": "TCP",
      "load_balancing_scheme": "INTERNAL_MANAGED",
      "network_name": "default",
      "target_proxy_name": "cross-region-internal-proxy-nl-target-proxy",
      "backend_scope_type": "ZONE",
      "forwarding_rule_name": "cross-region-internal-proxy-nlb-fe",
      "backend_target_type": "BACKEND_SERVICE",
      "backend_type": "INSTANCE_GROUP",
      "project_id": "my-project",
      "region": "asia-northeast1",
      "backend_name": "my-unmanaged-instance-group",
      "backend_scope": "asia-northeast1-b",
      "backend_target_name": "cross-region-internal-proxy-nlb"
    }
  },
  "timestamp": "2024-10-19T01:40:48.650089Z",
  "severity": "INFO",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fconnections",
  "receiveTimestamp": "2024-10-19T01:40:51.373191590Z"
}

Regional external passthrough Network Load Balancer

{
  "insertId": "1fcug38f3uvja4",
  "jsonPayload": {
    "endTime": "2024-10-19T01:59:03.698069641Z",
    "startTime": "2024-10-19T01:59:03.696967927Z",
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.ExternalNetworkLoadBalancerLogEntry",
    "connection": {
      "clientIp": "34.84.45.157",
      "serverIp": "34.84.37.150",
      "protocol": 6,
      "serverPort": 80,
      "clientPort": 53720
    },
    "packetsReceived": "8"
  },
  "resource": {
    "type": "loadbalancing.googleapis.com/ExternalNetworkLoadBalancerRule",
    "labels": {
      "backend_group_scope": "ZONE",
      "primary_target_pool": "",
      "backend_service_name": "regional-external-passthrough-nlb",
      "backend_subnetwork_name": "default",
      "forwarding_rule_name": "regional-external-passthrough-nlb-fe",
      "backend_group_name": "my-unmanaged-instance-group",
      "target_pool": "",
      "project_id": "my-project",
      "backend_zone": "asia-northeast1-b",
      "backend_network_name": "default",
      "backend_group_type": "INSTANCE_GROUP",
      "backend_target_type": "BACKEND_SERVICE",
      "region": "asia-northeast1"
    }
  },
  "timestamp": "2024-10-19T01:59:03.698069641Z",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fflows",
  "receiveTimestamp": "2024-10-19T01:59:16.645829810Z"
}

Regional internal passthrough Network Load Balancer

{
  "insertId": "1gq6lrwfwidq51",
  "jsonPayload": {
    "packetsSent": "2",
    "bytesReceived": "154",
    "endTime": "2024-10-19T02:03:37.78722619Z",
    "packetsReceived": "2",
    "startTime": "2024-10-19T02:03:37.787098544Z",
    "connection": {
      "serverPort": 80,
      "clientIp": "10.146.15.212",
      "serverIp": "10.146.15.236",
      "protocol": 6,
      "clientPort": 36116
    },
    "@type": "type.googleapis.com/google.cloud.loadbalancing.type.InternalNetworkLoadBalancerLogEntry",
    "rtt": "0.000127646s"
  },
  "resource": {
    "type": "loadbalancing.googleapis.com/InternalNetworkLoadBalancerRule",
    "labels": {
      "backend_service_name": "regional-internal-passthrough-nlb",
      "region": "asia-northeast1",
      "project_id": "my-project",
      "backend_subnetwork_name": "default",
      "forwarding_rule_name": "regional-internal-passthrough-nlb-fe",
      "backend_network_name": "default",
      "backend_group_type": "INSTANCE_GROUP",
      "backend_group_scope": "ZONE",
      "backend_group_name": "my-unmanaged-instance-group"
    }
  },
  "timestamp": "2024-10-19T02:03:37.787226190Z",
  "logName": "projects/my-project/logs/loadbalancing.googleapis.com%2Fflows",
  "receiveTimestamp": "2024-10-19T02:03:46.610207174Z"
}

杉村 勇馬 (記事一覧)

執行役員 CTO / クラウドソリューション部 部長

元警察官という経歴を持つ現 IT エンジニア。クラウド管理・運用やネットワークに知見。AWS 12資格、Google Cloud認定資格11資格。X (旧 Twitter) では Google Cloud や AWS のアップデート情報をつぶやいています。