vitessio/vitess · error

GetCellInfoNames(): %w

Error message

GetCellInfoNames(): %w

What it means

CopyShardReplications needs the list of cells in the source topo to iterate ShardReplication objects per cell. This error wraps a failure of fromTS.GetCellInfoNames, i.e. the cell inventory of the source topo could not be read.

Source

Thrown at go/vt/topo/helpers/copy.go:165

				}
			}
		}
	}

	return nil
}

// CopyShardReplications will create the ShardReplication objects in
// the destination topo.
func CopyShardReplications(ctx context.Context, fromTS, toTS *topo.Server) error {
	keyspaces, err := fromTS.GetKeyspaces(ctx)
	if err != nil {
		return fmt.Errorf("fromTS.GetKeyspaces: %w", err)
	}

	cells, err := fromTS.GetCellInfoNames(ctx)
	if err != nil {
		return fmt.Errorf("GetCellInfoNames(): %w", err)
	}

	for _, keyspace := range keyspaces {
		shards, err := fromTS.GetShardNames(ctx, keyspace)
		if err != nil {
			return fmt.Errorf("GetShardNames(%v): %w", keyspace, err)
		}

		for _, shard := range shards {
			for _, cell := range cells {
				sri, err := fromTS.GetShardReplication(ctx, cell, keyspace, shard)
				if err != nil {
					return fmt.Errorf("GetShardReplication(%v, %v, %v): %w", cell, keyspace, shard, err)
				}

				sriNodes := map[string]struct{}{}
				for _, node := range sri.Nodes {
					sriNodes[topoproto.TabletAliasString(node.TabletAlias)] = struct{}{}

View on GitHub (pinned to 01a25a7d17)

Solutions

  1. Inspect the wrapped inner error for the source topo failure
  2. Confirm cells exist in the source topo (vtctldclient GetCellInfoNames or equivalent)
  3. Verify source topo server configuration (topo_type, server address, root)
  4. Retry after fixing the source topo backend
Defensive patterns

Strategy: validation

Validate before calling

cells, err := fromTS.GetCellInfoNames(ctx)
if err != nil {
    return fmt.Errorf("source cells unreadable: %w", err)
}
if len(cells) == 0 {
    log.Warn("source topo has no cells")
}

Try / catch

err := helpers.CopyShardReplications(ctx, fromTS, toTS)
if err != nil {
    if strings.Contains(err.Error(), "GetCellInfoNames") {
        // fall back to inspecting source topo manually
        log.Errorf("cell listing failed: %v", err)
    }
}

Prevention

When it happens

Trigger: Calling CopyShardReplications when fromTS.GetCellInfoNames fails: source topo backend unreachable, cell directory missing/corrupt, or permission denied reading the cells path.

Common situations: Source etcd2/server topo root misconfigured; cells were never created in the source topo; partial topo corruption after a failed migration.

Related errors


AI-assisted analysis of vitessio/vitess@01a25a7d17 (2026-09-01). Data as JSON: /api/errors/e6754afe7f2092e3. Report an issue: GitHub.