Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Migration failing due to too many range table entries #17075

Copy link
Copy link
@luciamota

Description

@luciamota
Issue body actions

On the upgrade from version 4.7 to 4.8 the migration m_209_to_m_210_add_updated_at_to_network_flows_v2 fails with error

{"level":"Info","time":"2025-09-30T09:01:41.356469287Z","name":"Migrator","caller":"log.go:18","msg":"unable to alter table network_flows_v2: unable to update column updatedat: ERROR: too many range table entries (SQLSTATE 54000)"}
{"level":"Info","time":"2025-09-30T09:01:41.357212389Z","name":"Migrator","caller":"log.go:18","msg":"Migrator failed: ERROR: too many range table entries (SQLSTATE 54000)\nunable to update column updatedat\ngithub.com/stackrox/rox/migrator/migrations/m_209_to_m_210_add_updated_at_to_network_flows_v2.addColumnToTable\n\tgithub.com/stackrox/rox/migrator/migrations/m_209_to_m_210_add_updated_at_to_network_flows_v2/migration_impl.go:52\ngithub.com/stackrox/rox/migrator/migrations/m_209_to_m_210_add_updated_at_to_network_flows_v2.migrate\n\tgithub.com/stackrox/rox/migrator/migrations/m_209_to_m_210_add_updated_at_to_network_flows_v2/migration_impl.go:23\ngithub.com/stackrox/rox/migrator/runner.runMigrations\n\tgithub.com/stackrox/rox/migrator/runner/runner.go:103\ngithub.com/stackrox/rox/migrator/runner.Run\n\tgithub.com/stackrox/rox/migrator/runner/runner.go:62\nmain.upgrade\n\tgithub.com/stackrox/rox/migrator/upgrade.go:50\nmain.run\n\tgithub.com/stackrox/rox/migrator/main.go:88\nmain.main\n\tgithub.com/stackrox/rox/migrator/main.go:24\nruntime.main\n\truntime/proc.go:272\nruntime.goexit\n\truntime/asm_amd64.s:1700\nerror running migration starting at 209\ngithub.com/stackrox/rox/migrator/runner.runMigrations\n\tgithub.com/stackrox/rox/migrator/runner/runner.go:105\ngithub.com/stackrox/rox/migrator/runner.Run\n\tgithub.com/stackrox/rox/migrator/runner/runner.go:62\nmain.upgrade\n\tgithub.com/stackrox/rox/migrator/upgrade.go:50\nmain.run\n\tgithub.com/stackrox/rox/migrator/main.go:88\nmain.main\n\tgithub.com/stackrox/rox/migrator/main.go:24\nruntime.main\n\truntime/proc.go:272\nruntime.goexit\n\truntime/asm_amd64.s:1700\nmigrations failed\nmain.upgrade\n\tgithub.com/stackrox/rox/migrator/upgrade.go:55\nmain.run\n\tgithub.com/stackrox/rox/migrator/main.go:88\nmain.main\n\tgithub.com/stackrox/rox/migrator/main.go:24\nruntime.main\n\truntime/proc.go:272\nruntime.goexit\n\truntime/asm_amd64.s:1700"}

Checking the network_flows_v2 table, it has 488 partitions, which I believe is causing the issue.

This blocks the upgrade.

Is there a way to circumvent this issue?
Should there be a cleanup process for this information?

Thanks

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.