wavetermdev/waveterm · error

error getting linux storage backend: %w

Error message

error getting linux storage backend: %w

What it means

GetSecretsLinuxStorageBackendCommand reports which Linux secret-storage backend Wave would use (e.g. keyring/kwallet/file-based). GetLinuxStorageBackend probes the environment, and any failure to determine a usable backend is wrapped as "error getting linux storage backend". This command is only meaningful on Linux.

Source

Thrown at pkg/wshrpc/wshserver/wshserver.go:1517

		if value == nil {
			err := secretstore.DeleteSecret(name)
			if err != nil {
				return fmt.Errorf("error deleting secret %q: %w", name, err)
			}
		} else {
			err := secretstore.SetSecret(name, *value)
			if err != nil {
				return fmt.Errorf("error setting secret %q: %w", name, err)
			}
		}
	}
	return nil
}

func (ws *WshServer) GetSecretsLinuxStorageBackendCommand(ctx context.Context) (string, error) {
	backend, err := secretstore.GetLinuxStorageBackend()
	if err != nil {
		return "", fmt.Errorf("error getting linux storage backend: %w", err)
	}
	return backend, nil
}

func (ws *WshServer) JobCmdExitedCommand(ctx context.Context, data wshrpc.CommandJobCmdExitedData) error {
	return jobcontroller.HandleCmdJobExited(ctx, data.JobId, data)
}

func (ws *WshServer) JobControllerListCommand(ctx context.Context) ([]*waveobj.Job, error) {
	return wstore.DBGetAllObjsByType[*waveobj.Job](ctx, waveobj.OType_Job)
}

func (ws *WshServer) JobControllerDeleteJobCommand(ctx context.Context, jobId string) error {
	return jobcontroller.DeleteJob(ctx, jobId)
}

func (ws *WshServer) JobControllerStartJobCommand(ctx context.Context, data wshrpc.CommandJobControllerStartJobData) (string, error) {
	params := jobcontroller.StartJobParams{

View on GitHub (pinned to a4447c1563)

Solutions

  1. Verify a D-Bus session bus is available (DBUS_SESSION_BUS_ADDRESS set).
  2. Install/start a secrets provider: gnome-keyring (Secret Service API) or KWallet.
  3. If running headless is intentional, use Wave's non-keyring secret storage configuration instead of the keyring backend.
Defensive patterns

Strategy: fallback

Validate before calling

if runtime.GOOS != "linux" {
    // skip backend probe entirely on macOS/Windows
    return nil
}

Try / catch

backend, err := wshclient.GetSecretsLinuxStorageBackendCommand(ctx)
if err != nil {
    log.Printf("no linux secret backend (%v); falling back to non-keyring storage", err)
}

Prevention

When it happens

Trigger: Calling GetSecretsLinuxStorageBackendCommand on a Linux system with no detectable secret backend: no D-Bus session bus, no gnome-keyring/kwallet daemon, or the detection code itself errors.

Common situations: SSH sessions without a D-Bus session; minimal/headless servers or containers; desktop environments without any secrets provider installed.

Related errors


AI-assisted analysis of wavetermdev/waveterm@a4447c1563 (2026-09-01). Data as JSON: /api/errors/85e0a8ae761cc7a6. Report an issue: GitHub.