From 4827e6802cbe2d99aed6cb7830d57a550821ae0c Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Fri, 26 Jul 2024 10:28:04 +1000 Subject: [PATCH 1/8] Placeholder might be elsewhere --- .../kubernetes/kubernetes-agent/troubleshooting.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index bc8d20ee2a..fb99a3ee76 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -62,3 +62,7 @@ If you are using the default NFS storage however, then the script pod would be d - being evicted due to exceeding its storage quota - being moved or restarted as part of routine cluster operation + + +## FAQ +*WIP* From 946cfa81c73ea1b7c06fbe54942699791516ada3 Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Fri, 26 Jul 2024 15:48:34 +1000 Subject: [PATCH 2/8] FAQ section with the last few questions from community slack --- .../kubernetes-agent/troubleshooting.md | 40 ++++++++++++++++++- 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index fb99a3ee76..a2b6453caf 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -64,5 +64,41 @@ If you are using the default NFS storage however, then the script pod would be d - being moved or restarted as part of routine cluster operation -## FAQ -*WIP* +## Frequently Asked Questions {#FAQ} + +### Can the agent work with Octopus running in an HA Cluster setup? +Yes! See the [Kubernetes agent HA Cluster Support](/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/ha-cluster-support) page. + + +### Can a proxy be specified when setting up the Kubernetes agent? +Yes! Proxy servers for the polling connection that takes place between the agent and Octopus Server. These can be supplied for setup via the `.pollingProxy.*` helm values. + +Define the polling proxy server through the `agent.pollingProxy.host`, `agent.pollingProxy.port`, `agent.pollingProxy.username` and `agent.pollingProxy.password` values via the [octopusdeploy/kubernetes-agent](https://hub.docker.com/r/octopusdeploy/kubernetes-agent) helm chart. + +### I hit a 404 error when setting up the NFS Pod. + +First see if this known issue is impacting you. Where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961). If that doesn't help, please [get in touch](https://octopus.com/support). + +### When trying to install the Kubernetes Agent on an existing cluster, I get an 401: Unauthorized response. + +Check where and how the particular command being executed is running, and if the expected auth context is set up. For example: are you logged in to Docker Hub locally if that's where you're doing the setup from. + +### Do I need to have the NFS CSI Driver? +Not for all configurations. It depends, the installation wizard will guide you. + +If you are using `azurefile` then you don't need the NFS CSI driver. + +If you're using a new/clean AKS instance then you will need to install the NFS CSI Driver, as that AKS instance will not have the NFS CSI driver installed. + +### I have unexpected behavior with the polling endpoints in a HA configuration. +This could be a variety of issues. First check that different PORTS and/or URLs are used for each node. + +Check what was supplied to `agent.serverCommsAddresses` as they must be unique for [each Octopus node being registered against](https://octopus.com/docs/administration/high-availability/maintain/polling-tentacles-with-ha#connecting-polling-tentacles). + +If that doesn't help, please [get in touch](https://octopus.com/support). + +### I'm having strange behavior relating to ingress in a HA configuration. +Carefully look and see that there is a `serverCommsAddress` property for backwards compatibility, and a `serverCommsAddresses` the latter supporting an array input, mistyping these can happen. This has presented itself as a variety of errors depending on the broader configuration, e.g. you may see "it failed to allocate the public ip" if using load balancers. + +### The Script Pod seems to hang during a deployment +The times this has been brought up it's been specific to the deployment process being executed. Run subsets of your process to narrow down the cause, or [get in touch](https://octopus.com/support) with info on how we can reproduce what you're seeing. From c0ac729fd9f2ad4e1292c78a1c818bc67b4d841b Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Mon, 29 Jul 2024 11:47:21 +1000 Subject: [PATCH 3/8] Update src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md Co-authored-by: Mark Coafield <46470837+MissedTheMark@users.noreply.github.com> --- .../kubernetes/kubernetes-agent/troubleshooting.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index a2b6453caf..7033299ff2 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -77,7 +77,7 @@ Define the polling proxy server through the `agent.pollingProxy.host`, `agent.po ### I hit a 404 error when setting up the NFS Pod. -First see if this known issue is impacting you. Where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961). If that doesn't help, please [get in touch](https://octopus.com/support). +First see if this known issue is impacting you, where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961). If that doesn't help, please [get in touch](https://octopus.com/support). ### When trying to install the Kubernetes Agent on an existing cluster, I get an 401: Unauthorized response. From a372a3f61def67c1da766d3ad3fa14c1530e779b Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Mon, 29 Jul 2024 11:59:54 +1000 Subject: [PATCH 4/8] Update troubleshooting.md remove this to put in other page --- .../kubernetes/kubernetes-agent/troubleshooting.md | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index 7033299ff2..7260581ded 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -63,7 +63,6 @@ If you are using the default NFS storage however, then the script pod would be d - being evicted due to exceeding its storage quota - being moved or restarted as part of routine cluster operation - ## Frequently Asked Questions {#FAQ} ### Can the agent work with Octopus running in an HA Cluster setup? @@ -75,10 +74,6 @@ Yes! Proxy servers for the polling connection that takes place between the agent Define the polling proxy server through the `agent.pollingProxy.host`, `agent.pollingProxy.port`, `agent.pollingProxy.username` and `agent.pollingProxy.password` values via the [octopusdeploy/kubernetes-agent](https://hub.docker.com/r/octopusdeploy/kubernetes-agent) helm chart. -### I hit a 404 error when setting up the NFS Pod. - -First see if this known issue is impacting you, where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961). If that doesn't help, please [get in touch](https://octopus.com/support). - ### When trying to install the Kubernetes Agent on an existing cluster, I get an 401: Unauthorized response. Check where and how the particular command being executed is running, and if the expected auth context is set up. For example: are you logged in to Docker Hub locally if that's where you're doing the setup from. From 9b6803d8c21c928a9e58341be3703643715f3ad5 Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Mon, 29 Jul 2024 12:02:16 +1000 Subject: [PATCH 5/8] move to here? --- .../kubernetes/kubernetes-agent/troubleshooting.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index 7260581ded..3866b6e6d1 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -44,6 +44,14 @@ If the Agent install command fails with a timeout error, it could be that: - (if using the NFS storage solution) The NFS CSI driver has not been installed - (if using a custom Storage Class) the Storage Class name doesn't match +#### 404 error when setting up the NFS Pod. + +Check if your version of help is up to date. In versions the error message you might be experiencing is [not shown]([url](https://github.com/helm/helm/blob/1ec0aacb8865d5b1f7ef1cb884bbf9b12579ecef/pkg/action/install.go#L753-L769)). + +Once you version of help is up to date, run `helm repo update` and try again. + +If you're still having issues where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961) look at work arounds provided on that helm-issue page. If that doesn't help, please [get in touch](https://octopus.com/support). + ## Script Execution Issues ### `Unexpected Script Pod log line number, expected: expected-line-no, actual: actual-line-no` From b5d39a5f9552f9a3ad356c8ad1ff39ef55b083fc Mon Sep 17 00:00:00 2001 From: Nick Josevski Date: Mon, 29 Jul 2024 12:07:37 +1000 Subject: [PATCH 6/8] added the specific error --- .../kubernetes/kubernetes-agent/troubleshooting.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index 3866b6e6d1..28203bacd7 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -82,9 +82,14 @@ Yes! Proxy servers for the polling connection that takes place between the agent Define the polling proxy server through the `agent.pollingProxy.host`, `agent.pollingProxy.port`, `agent.pollingProxy.username` and `agent.pollingProxy.password` values via the [octopusdeploy/kubernetes-agent](https://hub.docker.com/r/octopusdeploy/kubernetes-agent) helm chart. -### When trying to install the Kubernetes Agent on an existing cluster, I get an 401: Unauthorized response. +### When trying to install the Kubernetes Agent on an existing cluster, I get an 401: Unauthorized error. -Check where and how the particular command being executed is running, and if the expected auth context is set up. For example: are you logged in to Docker Hub locally if that's where you're doing the setup from. +``` +Error: GET "https://registry-1.docker.io/v2/octopusdeploy/kubernetes-agent/tags/list": +GET "https://auth.docker.io/token?scope=repository%3Aoctopusdeploy%2Fkubernetes-agent%3Apull&service=registry.docker.io": unexpected status code 401: Unauthorized +``` +1. If you are running this command locally are you logged in? +2. If this is running from another automation, does that process have valid authentication and authorization? ### Do I need to have the NFS CSI Driver? Not for all configurations. It depends, the installation wizard will guide you. From 6a58a1f65fcfbfc3164667066e1b8383737a5063 Mon Sep 17 00:00:00 2001 From: Steve Fenton <99181436+steve-fenton-octopus@users.noreply.github.com> Date: Mon, 29 Jul 2024 08:28:51 +0100 Subject: [PATCH 7/8] Fix spelling error - workarounds is one word --- .../kubernetes/kubernetes-agent/troubleshooting.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index 28203bacd7..1deafb7f25 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -50,7 +50,7 @@ Check if your version of help is up to date. In versions the error message you m Once you version of help is up to date, run `helm repo update` and try again. -If you're still having issues where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961) look at work arounds provided on that helm-issue page. If that doesn't help, please [get in touch](https://octopus.com/support). +If you're still having issues where Helm fails to retrieve a remote chart if there are [local repos that are not cached](https://github.com/helm/helm/issues/11961) look at workarounds provided on that helm-issue page. If that doesn't help, please [get in touch](https://octopus.com/support). ## Script Execution Issues From 288972fb69be3212ffd04a889058fd655309a5a2 Mon Sep 17 00:00:00 2001 From: Steve Fenton <99181436+steve-fenton-octopus@users.noreply.github.com> Date: Mon, 5 Aug 2024 08:08:28 +0100 Subject: [PATCH 8/8] Update modified date --- .../kubernetes/kubernetes-agent/troubleshooting.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md index 1deafb7f25..1e0c99afd8 100644 --- a/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md +++ b/src/pages/docs/infrastructure/deployment-targets/kubernetes/kubernetes-agent/troubleshooting.md @@ -1,7 +1,7 @@ --- layout: src/layouts/Default.astro pubDate: 2024-05-08 -modDate: 2024-05-30 +modDate: 2024-08-05 title: Troubleshooting description: How to troubleshoot common Kubernetes Agent issues navOrder: 40