From 3be64e913bde73d0b014169952fbe21144a91eab Mon Sep 17 00:00:00 2001 From: Brian Picciano Date: Mon, 30 Dec 2024 17:51:10 +0100 Subject: [PATCH] Added some bug tasks which came out of real world testing --- go/daemon/network/network.go | 5 +++-- ...garage-apply-layout-before-stopping-instance.md | 14 ++++++++++++++ tasks/bugs/garage-credential-propagation-fix.md | 13 +++++++++++++ tasks/bugs/include-garage-firewall-entries.md | 9 +++++++++ .../set-config-dont-commit-new-config-on-err.md | 2 ++ 5 files changed, 41 insertions(+), 2 deletions(-) create mode 100644 tasks/bugs/garage-apply-layout-before-stopping-instance.md create mode 100644 tasks/bugs/garage-credential-propagation-fix.md create mode 100644 tasks/bugs/include-garage-firewall-entries.md diff --git a/go/daemon/network/network.go b/go/daemon/network/network.go index ecb5496..6dad009 100644 --- a/go/daemon/network/network.go +++ b/go/daemon/network/network.go @@ -495,8 +495,9 @@ func (n *network) initialize( } // Do this now so that everything is stable before returning. This also - // serves a dual-purpose, as it makes sure that the PUT from the postChildrenInit - // above has propagated from the local garage instance, if there is one. + // serves a dual-purpose, as it makes sure that the PUT from the + // postChildrenInit above has propagated from the local garage instance, if + // there is one. n.logger.Info(ctx, "Reloading hosts from network storage") if err = n.reloadHosts(ctx); err != nil { return fmt.Errorf("Reloading network bootstrap: %w", err) diff --git a/tasks/bugs/garage-apply-layout-before-stopping-instance.md b/tasks/bugs/garage-apply-layout-before-stopping-instance.md new file mode 100644 index 0000000..4759a31 --- /dev/null +++ b/tasks/bugs/garage-apply-layout-before-stopping-instance.md @@ -0,0 +1,14 @@ +--- +type: host +--- + +When removing a storage allocation the new layout should be applied _before_ the +impacted garage instance is shut down. Isle should ideally also wait for the +impacted instance to no longer be in the "draining" state prior to shutting it +down, if possible. + +Some care needs to be taken in the case of the `daemon.yml` file being used for +configuration. The daemon should probably initially load using the old +configuration, and only then apply the new configuration as if it were applied +using `SetConfig`. This way the garage instance being removed can be brought +back up, drained, then shut down again. diff --git a/tasks/bugs/garage-credential-propagation-fix.md b/tasks/bugs/garage-credential-propagation-fix.md new file mode 100644 index 0000000..4f72606 --- /dev/null +++ b/tasks/bugs/garage-credential-propagation-fix.md @@ -0,0 +1,13 @@ +--- +type: task +--- + +It seems in real world testing that this error came up after `isle storage +allocation add` had already completed: + +``` +ERROR [daemon/networks/micropelago.net] Background job failed errMsg="getting hosts from garage: listing objects: Forbidden: No such key: XXXXXXXXXXXXXXXXXXXXXXXXXX" workerLabel=reloadHosts +``` + +Isle should wait until bucket credentials are propagated to the new garage +instance before considering it to be online. diff --git a/tasks/bugs/include-garage-firewall-entries.md b/tasks/bugs/include-garage-firewall-entries.md new file mode 100644 index 0000000..738ba9b --- /dev/null +++ b/tasks/bugs/include-garage-firewall-entries.md @@ -0,0 +1,9 @@ +--- +type: task +--- + +When listing firewall entries using `isle vpn firewall list`, any firewall +entries which are automatically included for garage (and all other services in +the future) should be included in the returned list as well. These should be +annotated in such a way that the user understands they are automatically +generated and can't be changed. diff --git a/tasks/bugs/set-config-dont-commit-new-config-on-err.md b/tasks/bugs/set-config-dont-commit-new-config-on-err.md index 5f2d8a8..d07d587 100644 --- a/tasks/bugs/set-config-dont-commit-new-config-on-err.md +++ b/tasks/bugs/set-config-dont-commit-new-config-on-err.md @@ -1,5 +1,7 @@ --- type: task +after: + - ./garage-apply-layout-before-stopping-instance.md --- When SetConfig is called, but ends up erroring, the new config should not end up