Page MenuHomePhabricator

scap logs sometimes have incorrect date
Open, LowPublic


While investigating my own mess, I discovered that some scap logs had the wrong date:

ls -ltr scap/log
-rw-rw-r-- 1 awight    wikidev 10096 Nov  8 16:49 scap-sync-2017-11-08-0001.log
-rw-rw-r-- 1 awight    wikidev 83060 Nov 20 22:27 scap-sync-2017-11-08-0002-1-g5084251.log
-rw-rw-r-- 1 awight    wikidev 25178 Nov 20 22:55 scap-sync-2017-11-20-0001.log
-rw-rw-r-- 1 awight    wikidev  7161 Nov 20 23:19 95cd523.log
-rw-rw-r-- 1 awight    wikidev 32871 Nov 20 23:38 scap-sync-2017-11-08-0003.log

I remember that I had run scap deploy-log on those 11-08 files, and that they existed before I ran my 11-20 deployments. It seems that scap deploy picked up the last filename given to deploy-log, and overwrote it.

Event Timeline

More context: I was attempting rollbacks, here are the SAL lines from that day:

  • 21:37 <awight@tin> Started deploy [ores/deploy@5084251]: Updating ORES to revscoring 2.0.10, T179711
  • 22:54 <awight@tin> Started deploy [ores/deploy@5084251]: Rollback ORES; T179711
  • 23:18 awight@tin: Started deploy [ores/deploy@95cd523]: Rollback ORES (take 2); 181006
  • 23:25 <awight@tin> Started deploy [ores/deploy@82a13ae]: Rollback ORES (take 3); T181006
thcipriani triaged this task as Medium priority.Nov 22 2017, 5:18 PM
thcipriani added a subscriber: thcipriani.

Looks like we name the log file with git describe --always which could make for some funky names indeed:

We should probably just use the scap tag, although we make that much later in deploy, we could probably move that logic a bit since it's pretty straight-forward/deterministic.

greg lowered the priority of this task from Medium to Low.Jan 22 2018, 5:57 PM