Skip to content

cmd/syncthing: Always use monitor process (fixes #4774, fixes #5786) - #6278

Merged
imsodin merged 1 commit into
syncthing:masterfrom
imsodin:cmdsyncthing/monitorAll-single
Jan 20, 2020
Merged

imsodin merged 1 commit into
syncthing:masterfrom
imsodin:cmdsyncthing/monitorAll-single

Conversation

@imsodin

@imsodin imsodin commented Jan 19, 2020

Copy link
Copy Markdown
Member

Purpose

Syncthing is now always run through a monitor process. Reasons found in #5786 and it also fixes #4774 as predicted there :)

This will lead to a >20% increase in reports to sentry (according to data.syncthing.net and assuming most apt/arch/fedora/... use some kind of service manager) and an initial spike of old reports, just in case that needs some precautionary measures.

I also took the opportunity to add logging to the desktop entry (also tested to work).

Testing

I manually tested the following that without -no-restart it restarts on ctrl-c in subshell, on restart in UI and on auto-update and it does not restart on shutdown in UI, and with -no-restart it doesn't restart in any of the aforementioned cases.

@calmh calmh left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM all hail the new overlord process

GenericName=File synchronization
Comment=Starts the main syncthing process in the background.
Exec=/usr/bin/syncthing -no-browser
Exec=/usr/bin/syncthing -no-browser -logfile=~/.config/syncthing/syncthing.log

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

You're going to unleash the fucking fury of the XDG aficionados here, be prepared to defend yourself :D

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I know (and I even have more affections than aversion towards XDG myself (I definitely prefer it a thousand times to programs cluttering my home with .hereIAm dirs at the other end of the extremes), so I might eventually get around to fixing #4924, including log location) :)

@calmh

calmh commented Jan 20, 2020

Copy link
Copy Markdown
Member

There's apparently a merge conflict with master which is why the builds didn't happen

@calmh

calmh commented Jan 20, 2020

Copy link
Copy Markdown
Member

No, that was something else, looks like the build server was just confused...

@calmh

calmh commented Jan 20, 2020

Copy link
Copy Markdown
Member

I guess you had this cooking for a while and rebased it, commit inherited original time of august 2019, build server thought "oldcrap, not gonna 🤷‍♀" and that was that

@imsodin

imsodin commented Jan 20, 2020

Copy link
Copy Markdown
Member Author

I need to cover my tracks better xD
I made a very half-assed version of this and then got bored by it then. And now when I felt like finally doing it remembered that something existed and rebase-amended it - note to self: Just checkout old stuff into a new branch :D

@imsodin
imsodin merged commit 69da11a into syncthing:master Jan 20, 2020
@imsodin
imsodin deleted the cmdsyncthing/monitorAll-single branch January 20, 2020 08:07
@calmh

calmh commented Jan 20, 2020

Copy link
Copy Markdown
Member

Note that as Audrius pointed out some time you possibly just broke force stopping Syncthing on Android.

calmh added a commit to calmh/syncthing that referenced this pull request Jan 21, 2020
* master:
  lib/model: Handle progress emitter zero interval (fixes syncthing#6281) (syncthing#6282)
  build(deps): bump github.com/pkg/errors from 0.9.0 to 0.9.1 (syncthing#6279)
  cmd/syncthing: Always use monitor process (fixes syncthing#4774, fixes syncthing#5786) (syncthing#6278)
  lib/syncthing: Wait for actual termination on Stop() (syncthing#6277)
  lib/model: Remove legacy handling of symlinks (syncthing#6276)
  lib/model: Return paused summary instead of error on paused folders (syncthing#6272)
  lib/config: Add some info to the folder marker missing (ref syncthing#5207) (syncthing#6270)
@calmh calmh added this to the v1.4.0 milestone Jan 24, 2020
calmh added a commit to calmh/syncthing that referenced this pull request Jan 30, 2020
* master: (28 commits)
  gui, man, authors: Update docs, translations, and contributors
  lib/config, lib/model: Limit concurrent pulls (fixes syncthing#5914) (syncthing#6290)
  lib/db: Fixup last commit with better key name
  lib/db: Configurable block GC time (syncthing#6295)
  lib/db: Deduplicate block lists in database (fixes syncthing#5898) (syncthing#6283)
  lib/relays: Fix incorrect timeout, bring back logging (ref syncthing#6289) (syncthing#6291)
  gui, man, authors: Update docs, translations, and contributors
  all: Transactionalize db.FileSet (fixes syncthing#5952) (syncthing#6239)
  lib/model: Handle progress emitter zero interval (fixes syncthing#6281) (syncthing#6282)
  build(deps): bump github.com/pkg/errors from 0.9.0 to 0.9.1 (syncthing#6279)
  cmd/syncthing: Always use monitor process (fixes syncthing#4774, fixes syncthing#5786) (syncthing#6278)
  lib/syncthing: Wait for actual termination on Stop() (syncthing#6277)
  lib/model: Remove legacy handling of symlinks (syncthing#6276)
  lib/model: Return paused summary instead of error on paused folders (syncthing#6272)
  lib/config: Add some info to the folder marker missing (ref syncthing#5207) (syncthing#6270)
  assets, gui: Losslessly compress all JPG, PNG, and PDF images (syncthing#6265)
  cmd/strelaypoolsrv: Serve gzip compressed responses
  gui, man, authors: Update docs, translations, and contributors
  gui, man, authors: Update docs, translations, and contributors
  build: go mod tidy
  ...
calmh added a commit to calmh/syncthing that referenced this pull request Jan 30, 2020
* master: (32 commits)
  gui, man, authors: Update docs, translations, and contributors
  lib/config, lib/model: Limit concurrent pulls (fixes syncthing#5914) (syncthing#6290)
  lib/db: Fixup last commit with better key name
  lib/db: Configurable block GC time (syncthing#6295)
  lib/db: Deduplicate block lists in database (fixes syncthing#5898) (syncthing#6283)
  lib/relays: Fix incorrect timeout, bring back logging (ref syncthing#6289) (syncthing#6291)
  gui, man, authors: Update docs, translations, and contributors
  all: Transactionalize db.FileSet (fixes syncthing#5952) (syncthing#6239)
  lib/model: Handle progress emitter zero interval (fixes syncthing#6281) (syncthing#6282)
  build(deps): bump github.com/pkg/errors from 0.9.0 to 0.9.1 (syncthing#6279)
  cmd/syncthing: Always use monitor process (fixes syncthing#4774, fixes syncthing#5786) (syncthing#6278)
  lib/syncthing: Wait for actual termination on Stop() (syncthing#6277)
  lib/model: Remove legacy handling of symlinks (syncthing#6276)
  lib/model: Return paused summary instead of error on paused folders (syncthing#6272)
  lib/config: Add some info to the folder marker missing (ref syncthing#5207) (syncthing#6270)
  assets, gui: Losslessly compress all JPG, PNG, and PDF images (syncthing#6265)
  cmd/strelaypoolsrv: Serve gzip compressed responses
  gui, man, authors: Update docs, translations, and contributors
  gui, man, authors: Update docs, translations, and contributors
  build: go mod tidy
  ...
@st-review st-review added the frozen-due-to-age Issues closed and untouched for a long time, together with being locked for discussion label Jan 20, 2021
@syncthing syncthing locked and limited conversation to collaborators Jan 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

frozen-due-to-age Issues closed and untouched for a long time, together with being locked for discussion

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Doesn't react to Ctrl-C when run in a subshell with -no-restart (Linux)

3 participants