Editing Gcloud logging read

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
 
{{lc}}
 
{{lc}}
<code>[[gcloud logging]] read</code>
 
[[gcloud logging read --help]]
 
  
* https://cloud.google.com/sdk/gcloud/reference/logging/read
+
[[gcloud logging]] read "resource.type=global"
 +
ERROR: (gcloud.logging.read) PERMISSION_DENIED: The caller does not have permission
  
  [[--freshness]] 90d
+
  gcloud logging read  projects/yourproject/logs/[[kubelet]]
  
  resource.labels.container_name=""
+
  [[gcloud logging read --help]]
                .pod_name=""
 
                .[[gcloud logging read resource.labels.cluster_name|cluster_name]]=""
 
 
 
resource.type=K8s_container=""
 
 
 
resource.labels.[[k8s_node]]=""
 
 
 
 
 
 
 
gcloud logging read "[[resource.labels.container_name]]=YourContainerName"
 
gcloud logging read "[[resource.labels.pod_name]]=YourPodsName"
 
 
 
container.name
 
:<code>gcloud logging read "resource.labels.container_name=[[elasticsearch]]"</code>
 
 
 
pod.name
 
gcloud logging read "resource.labels.pod_name=[[elasticsearch-master-0]]"
 
gcloud logging read "resource.labels.pod_name=elasticsearch-master-0 OR resource.labels.pod_name=elasticsearch-master-1"
 
 
 
 
 
gcloud logging read "[[resource.type]]=k8s_container AND [[resource.labels.container_name]]=YourContainerName"
 
 
 
[[gcloud logging]] read "resource.labels.container_name=backup" | grep [[textPayload]]
 
 
 
[[gcloud logging read projects/your-project/logs/kubelet]]
 
  
 
  [[gcloud logging logs list]]
 
  [[gcloud logging logs list]]
 
 
{{gloud logging logs list kubernetes}}
 
 
== Errors ==
 
[[gcloud logging]] read "resource.type=global"
 
ERROR: (gcloud.logging.read) PERMISSION_DENIED: The caller does not have permission
 
[[helm get all]]
 
 
gcloud logging read "resource.labels.[[k8s_node]]=gke-gitlab-runner-cluster-pool-1-3534-4"
 
ERROR: (gcloud.logging.read) INVALID_ARGUMENT: Request contains an invalid argument.
 
  
 
== Related ==
 
== Related ==
* <code>[[kubectl get events]]</code>
+
[[ubectl get events]]
* [[GCP log explorer]]
 
* <code>[[resource.labels.container_name]]</code>
 
* <code>textPayload=~".*your-text-to-be-included.*"</code>
 
* <code>[[gcloud app logs read]]</code>
 
  
 
== See also ==
 
== See also ==

Please note that all contributions to wikieduonline may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see Wikieduonline:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)

Advertising: