From 1feea68b107a1f73a1aa4dc8e7ffaaf15fdf87bb Mon Sep 17 00:00:00 2001 From: Sebastiaan van Steenis Date: Thu, 13 Dec 2018 00:06:48 +0100 Subject: [PATCH] Correct commands to get Rancher logs on contributing page --- .../rancher/v2.x/en/contributing/_index.md | 29 +++++++++++++++---- 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/content/rancher/v2.x/en/contributing/_index.md b/content/rancher/v2.x/en/contributing/_index.md index 1824664d80a..d54ff552f9c 100644 --- a/content/rancher/v2.x/en/contributing/_index.md +++ b/content/rancher/v2.x/en/contributing/_index.md @@ -63,15 +63,33 @@ Please follow this checklist when filing an issue which will helps us investigat ``` docker logs \ - --tail=all \ --timestamps \ - $(docker ps -q -f label=org.label-schema.vcs-url=https://github.com/rancher/rancher.git) + $(docker ps | grep -E "rancher/rancher:|rancher/rancher " | awk '{ print $1 }') ``` - - High Availability + - High Availability (HA) install using `kubectl` + + > **Note:** Make sure you configured the correct kubeconfig (for example, `export KUBECONFIG=$PWD/kube_config_rancher-cluster.yml` for Rancher HA) or are using the embedded kubectl via the UI. ``` - kubectl --kubeconfig $KUBECONFIG logs \ - -n cattle-system \ + kubectl -n cattle-system \ + logs \ + -l app=rancher \ + --timestamps=true + ``` + - High Availability (HA) install using `docker` on each of the nodes in the RKE cluster + + ``` + docker logs \ + --timestamps \ + $(docker ps | grep -E "rancher/rancher@|rancher_rancher" | awk '{ print $1 }') + ``` + - High Availability (HA) RKE Add-On Install + + > **Note:** Make sure you configured the correct kubeconfig (for example, `export KUBECONFIG=$PWD/kube_config_rancher-cluster.yml` for Rancher HA) or are using the embedded kubectl via the UI. + + ``` + kubectl -n cattle-system \ + logs \ --timestamps=true \ -f $(kubectl --kubeconfig $KUBECONFIG get pods -n cattle-system -o json | jq -r '.items[] | select(.spec.containers[].name="cattle-server") | .metadata.name') ``` @@ -84,7 +102,6 @@ Please follow this checklist when filing an issue which will helps us investigat If you are experiencing performance issues, please provide as much of data (files or screenshots) of metrics which can help determining what is going on. If you have an issue related to a machine, it helps to supply output of `top`, `free -m`, `df` which shows processes/memory/disk usage. - ### Docs If you have any updates to our documentation, please make any pull request to our docs repo.