Page MenuHomePhabricator

Recommend dumping database backups with "--compress --output X" instead of "| gzip > X"
ClosedPublic

Authored by epriestley on Jun 5 2019, 10:00 PM.
Tags
None
Referenced Files
F15479185: D20572.id49075.diff
Tue, Apr 8, 5:28 AM
F15410641: D20572.diff
Wed, Mar 19, 7:59 AM
F15407321: D20572.id.diff
Tue, Mar 18, 4:53 PM
F15401456: D20572.id49075.diff
Mon, Mar 17, 5:48 PM
F15401243: D20572.id49075.diff
Mon, Mar 17, 4:31 PM
F15401016: D20572.id49075.diff
Mon, Mar 17, 3:15 PM
F15400775: D20572.id49075.diff
Mon, Mar 17, 1:58 PM
F15400579: D20572.id49075.diff
Mon, Mar 17, 12:40 PM
Subscribers
None

Details

Summary

Fixes T13304. Shell pipes and redirects do not have robust behavior when errors occur. We provide "--compress" and "--output" flags as robust alternatives, but do not currently recommend their use.

  • Recommend their use, since their error handling behavior is more robust in the face of issues like full disks.
  • If "--compress" is provided but won't work because the "zlib" extension is missing, raise an explicit error. I believe this extension is very common and this error should be rare. If that turns out to be untrue, we could take another look at this.
  • Also, verify some flag usage sooner so we can exit with an error faster if you mistype a "bin/storage dump" command.
Test Plan

Read documentation, hit affected error cases, did a dump and spot-checked that it came out sane looking.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable