diff --git a/vault/core.go b/vault/core.go index 66903db03..75df72601 100644 --- a/vault/core.go +++ b/vault/core.go @@ -1183,9 +1183,14 @@ func (c *Core) Seal(token string) (retErr error) { } } if err != nil { + // Since there is no token store in standby nodes, sealing cannot + // be done. Ideally, the request has to be forwarded to leader node + // for validation and the operation should be performed. But for now, + // just returning with an error and recommending a vault restart, which + // essentially does the same thing. if c.standby { - c.logger.Printf("[ERR] core: cannot seal the vault in standby mode") - return errors.New("Vault cannot be sealed in standby mode") + c.logger.Printf("[ERR] core: vault cannot be sealed when in standby mode; please restart instead") + return errors.New("vault cannot be sealed when in standby mode; please restart instead") } return err }