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

Interrupted system call #85

Closed
rkfg opened this issue Aug 12, 2014 · 29 comments
Closed

Interrupted system call #85

rkfg opened this issue Aug 12, 2014 · 29 comments

Comments

@rkfg
Copy link

rkfg commented Aug 12, 2014

It shows a red message for my DCIM/Camera repo (and only for it): Interrupted system call. The problem is it happens after a while, maybe day or two. So it's hard to provide a logcat. After the message appears, it seems it stops syncing this repo while sitting on "Scanning 100%". The only option is to restart Syncthing (btw, need to add the restart button to GUI). Any hints on this? Happens on Nexus 4 and (possibly) on Nexus 10, will check the latter.

@Nutomic
Copy link
Contributor

Nutomic commented Aug 17, 2014

@calmh Any idea?

@firecat53
Copy link

This is also happening to me. I have 3 repositories and it seems to happen randomly once or twice a day. All of the repositories have been affected at one time or another. Only one repo at a time, however. That repository stops syncing, but the other 2 still seem to be active.

@calmh
Copy link
Member

calmh commented Aug 17, 2014

What's the full, actual, error message shown in the GUI (same is in the logs, without any debugging on)?

@rkfg
Copy link
Author

rkfg commented Aug 17, 2014

It shows that exact message in the Android GUI near the repo path — "Interrupted system call", nothing more. Unfortunately, I didn't open the web UI, there could be more details. Will do that when it occurs again.

@calmh
Copy link
Member

calmh commented Aug 17, 2014

@Nutomic What's the source of that error message? If from syncthing, it ought to be on the form "WARNING: (some hopefully useful context): Interrupted system call".

@Nutomic
Copy link
Contributor

Nutomic commented Aug 17, 2014

I use the exact error message straight from syncthing.

But I'm still getting the errors from /rest/config and /rest/model, maybe that's not the correct way any more.

@rkfg @firecat53 What does localhost:8080/rest/errors show in your browser?

@rkfg
Copy link
Author

rkfg commented Aug 17, 2014

For now it's empty because no errors happened. I'll wait for it to happen and check both the UI and the REST API.

@calmh
Copy link
Member

calmh commented Aug 17, 2014

@Nutomic Do you mean syncthing returns the exact string Interrupted system call as response to a call to /rest/config etc? Are you sure?

@Nutomic
Copy link
Contributor

Nutomic commented Aug 17, 2014

@calmh I have no idea, but that's all I use for getting errors at the moment. I checked it and the strings aren't changed either (unless I missed something). Maybe it's because of an older syncthing version?

@rkfg
Copy link
Author

rkfg commented Aug 17, 2014

This happened on 0.8 branch, too. I've updated ST on the phone, now it's 0.9.4. We'll see if it changes anything.

@firecat53
Copy link

The error from the web GUI page is:

Error lstat /storage/emulated/0/DCIM/Camera: interrupted system call

The output is [] on the*/rest/errors page.

Thanks,
Scott
On Aug 17, 2014 4:21 AM, "Felix Ableitner" notifications@github.com wrote:

I use the exact error message straight from syncthing.

But I'm still getting the errors from /rest/config and /rest/model, maybe
that's not the correct way any more.

@rkfg https://github.com/rkfg @firecat53 https://github.com/firecat53
What does localhost:8080/rest/errors show in your browser?


Reply to this email directly or view it on GitHub
#85 (comment)
.

@calmh
Copy link
Member

calmh commented Aug 18, 2014

@firecat53 Screenshot?

@rkfg
Copy link
Author

rkfg commented Aug 18, 2014

It just happened. I haven't shoot any photos recently (after the launch of ST), for the record. Here are the screenshots:


@calmh
Copy link
Member

calmh commented Aug 18, 2014

Thanks! Looking into it. Any pattern that you know of that causes this to happen (i.e. when the phone sleeps/wakes/roams/is dropped on the floor/...)?

@rkfg
Copy link
Author

rkfg commented Aug 18, 2014

Can't tell much. Usually I turn off wi-fi, mobile data and bluteooth before going to sleep and turn them on in the morning. Most of the time the phone isn't used actively. I checked for the error periodically today and it happened recently. My phone is Nexus 4 and it's rooted, so it may interfere in some way. I also experimented a bit with the libsyncthing.so binary (replacing the original in /data/app-lib/com.nutomic.syncthing with the precompiled ARM binaries) but couldn't get 0.9.5 to work, it crashed with error 124 or so. But that's not the case, the issue persists from the early 0.8.x versions, I just paid less attention to it and restarted the program. Now the binary is original.

@firecat53
Copy link

No screenshot yet...of course it survived the night and going out with me on a run this morning without having the issue. But I happened to look at http://localhost:8080/rest/config when it happened yesterday. The "Interrupted System Error" appears in the "Invalid" data block for that repository. The error is exactly the same as show in @rkfg's screenshots.

I also can't discern any pattern to the error. It's happened to each of the three repositories at various times and can happen at home while on wifi or when I'm out of the house on celluar data.

Thanks,
Scott

@calmh
Copy link
Member

calmh commented Aug 19, 2014

Escalated even further upstream since this is an issue with the Go runtime or standard library. I suspect a specific Android interaction (the OS doing something unexpected), so it might be tricky to narrow down.

(https://code.google.com/p/go/issues/detail?id=8551)

@rkfg
Copy link
Author

rkfg commented Aug 20, 2014

Some more info. I've left ST running after the first error message, and after a while the other repo showed that error and stopped syncing. Before I always restarted the program after that message so there was no time for it to happen again for another repo.

@calmh
Copy link
Member

calmh commented Aug 20, 2014

@rkfg This isn't something that can be easily solved by either @Nutomic or me, and probably quite platform specific, so unfortunately I don't think you should expect a quick resolution here.

@rkfg
Copy link
Author

rkfg commented Aug 20, 2014

@calmh I understand the issue very well, thank you! Probably, as a temporary workaround @Nutomic could add the automatic binary restart function when this error pops up? I doubt it will interfere with anything, 99% of the time the app works in background.

@Nutomic
Copy link
Contributor

Nutomic commented Aug 20, 2014

That would mean comparing error messages to that string (while stripping out the path), and if it matches, restarting the binary (which is handled in an entirely different place). So imo it's too complicated/ugly to add (and frankly, there don't seem to be many users affected to justify this).

Sorry :(

@Nutomic
Copy link
Contributor

Nutomic commented Aug 21, 2014

But until this is fixed, you could alternatively just install an older version from github ;)

@rkfg
Copy link
Author

rkfg commented Aug 21, 2014

It doesn't help, I saw this error even in 0.8.x as I said before. They've planned go 1.4 code freeze at September 1st and release somewhere in December. I hope it will be fixed sooner than that and then you could compile the binary with the beta version of the compiler.

@Nutomic
Copy link
Contributor

Nutomic commented Oct 12, 2014

Okay so the issue at golang was closed as "WorkingAsIntended".

@calmh Any idea how to continue with this?

@firecat53
Copy link

For what it's worth, I haven't seen the 'interrupted system call' error in a couple of months now on my Android.

@rkfg
Copy link
Author

rkfg commented Oct 12, 2014

Same here but it's only because the backend is now restarted each time the device wakes up. It just doesn't have enough time to get to this error. Before it required a day or two of uptime for me, now the backend lives several minutes at most while the screen is on.

@Nutomic
Copy link
Contributor

Nutomic commented Oct 12, 2014

Okay so this doesn't occur any more/is not reproducible any more, but it's not fixed. So we can't close the issue.

Aaaaaah D:

@calmh
Copy link
Member

calmh commented Oct 13, 2014

Sorry, no. This requires an Android guru with the will to figure out what exactly happens. Then the fix is probably easy...

@Zillode
Copy link
Contributor

Zillode commented Apr 29, 2015

Fixed in next release
See golang/go#8551 and syncthing/syncthing@102a2db

@Zillode Zillode closed this as completed Apr 29, 2015
@syncthing syncthing locked and limited conversation to collaborators Nov 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants