Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(cmd/influxd): improve influxd upgrade logging, and require manual confirmation of data copy #20440

Merged
merged 3 commits into from
Jan 7, 2021

Conversation

danxmoran
Copy link
Contributor

Closes #20383

Before this patch, we were:

  1. Calculating expected disk size needed to make a full copy of V1 data
  2. Logging the info, but only in verbose mode
  3. Auto-proceeding with the copy if the disk had enough space

After this patch:

  1. verbose is deprecated/hidden in favor of debug-level logging (reduce the number of levers users need to pull to get useful diagnostics)
  2. Most verbose-level logs are now debug, but the size-log is info
  3. Add an explicit y/n input point before copying data (skippable by using --force)

return fmt.Sprintf(`Proceeding will copy all V1 data to %q
Space available: %s
Space required: %s
`, v2dir, freeBytes, requiredBytes)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@psteinbachs @timhallinflux can you give a 👍 or 👎 to this behavior change? It adds one more y/N interaction point to influxd upgrade, to force users to consider how much disk they're about to use. The check is skipped if the --force flag is given.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, given community feedback around this I think it is a welcome change.

@psteinbachs psteinbachs requested review from psteinbachs and removed request for psteinbachs January 6, 2021 15:17
@danxmoran danxmoran force-pushed the dm-upgrade-improve-logging-20383 branch from 9b9f0ca to 4b5f9e1 Compare January 6, 2021 21:38
Copy link
Contributor

@davidby-influx davidby-influx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make size-check in influxd upgrade more obvious
3 participants