Giter Club home page Giter Club logo

Comments (13)

calmh avatar calmh commented on May 22, 2024

Shouldn't happen, seems to only happen in the Solaris build. I suspect a runtime bug.

from syncthing.

jedie avatar jedie commented on May 22, 2024

I get also this error on linux:

[BFBR3] 14:13:21 INFO: syncthing v0.8.7 (go1.2.2 linux-386) jb@jborg-mbp 2014-05-16 14:28:52 UTC
[BFBR3] 14:13:21 INFO: My ID: BFBR...
[BFBR3] 14:13:21 INFO: Starting web GUI on http://0.0.0.0:8080/
[BFBR3] 14:13:21 INFO: Populating repository index
panic: runtime error: slice bounds out of range

goroutine 1 [running]:
runtime.panic(0x830b3c0, 0x8775faa)
    /usr/local/go/src/pkg/runtime/panic.c:266 +0xac
github.com/calmh/syncthing/xdr.(*Reader).ReadBytesMaxInto(0x18a96de0, 0x40, 0x0, 0x0, 0x0, ...)
    /Users/jb/src/github.com/calmh/syncthing/xdr/reader.go:58 +0x22b
github.com/calmh/syncthing/xdr.(*Reader).ReadBytesMax(0x18a96de0, 0x40, 0x1b315a00, 0x20, 0x20)
    /Users/jb/src/github.com/calmh/syncthing/xdr/reader.go:36 +0x3c
github.com/calmh/syncthing/protocol.(*BlockInfo).decodeXDR(0x1b314ba0, 0x18a96de0, 0x0, 0x0)
    /Users/jb/src/github.com/calmh/syncthing/protocol/message_xdr.go:152 +0x49
github.com/calmh/syncthing/protocol.(*FileInfo).decodeXDR(0x18d4f808, 0x18a96de0, 0x0, 0x0)
    /Users/jb/src/github.com/calmh/syncthing/protocol/message_xdr.go:113 +0x137
github.com/calmh/syncthing/protocol.(*IndexMessage).decodeXDR(0xb7621ac0, 0x18a96de0, 0xc, 0x18a3182c)
    /Users/jb/src/github.com/calmh/syncthing/protocol/message_xdr.go:56 +0xe4
github.com/calmh/syncthing/protocol.(*IndexMessage).DecodeXDR(0xb7621ac0, 0xb770cbb8, 0x18bc9780, 0x0, 0x0)
    /Users/jb/src/github.com/calmh/syncthing/protocol/message_xdr.go:39 +0x6c
github.com/calmh/syncthing/model.(*Model).loadIndex(0x18b23990, 0x18a00698, 0x4, 0x18a1ba80, 0x21, ...)
    /Users/jb/src/github.com/calmh/syncthing/model/model.go:687 +0x2e4
github.com/calmh/syncthing/model.(*Model).LoadIndexes(0x18b23990, 0x18a1ba80, 0x21)
    /Users/jb/src/github.com/calmh/syncthing/model/model.go:641 +0xa6
main.main()
    /Users/jb/src/github.com/calmh/syncthing/cmd/syncthing/main.go:288 +0x11c6

Some info:

3.8.0-35-generic #50-Ubuntu SMP Tue Dec 3 01:25:33 UTC 2013 i686 athlon i686 GNU/Linux

$ ./syncthing --version
syncthing v0.8.7 (go1.2.2 linux-386) jb@jborg-mbp 2014-05-16 14:28:52 UTC

from syncthing.

calmh avatar calmh commented on May 22, 2024

Fascinating! Doing what/when does it happen?

from syncthing.

calmh avatar calmh commented on May 22, 2024

(Not the same issue/backtrace as the original, but we might as well reuse the issue)

from syncthing.

calmh avatar calmh commented on May 22, 2024

Looks like at startup, when reading the index cache. So is it 100% reproducible? If so, it would be great if I could get that index cache file. It will contain the file names, metadata and hashes for all files in the repository so if that's data you'd rather not have me see I fully respect that. If you have multiple repositories, you can find the guilty one using this utility: https://nym.se/t/stpidx

Run it as stpidx ~/.config/syncthing/....idx.gz for each .idx.gz file and it should either print the contents of the index or crash with the same symptoms as above.

from syncthing.

jedie avatar jedie commented on May 22, 2024

Oh, sorry... to late... I have done this: rm .config/syncthing/*.idx.gz ;)

It was 100% reproducible. After deleting the index it works... But maybe it will fail over the same files, because the repro files/config i haven't touch. So it should index the same...

from syncthing.

calmh avatar calmh commented on May 22, 2024

Argh. :) If it does happen again, please save the files for posterity.

from syncthing.

DinizCabreira avatar DinizCabreira commented on May 22, 2024

I believe I have come across this, or a similar bug:

[BFHOS] 17:01:05 INFO: syncthing v0.10.29 (go1.4.2 linux-386 default) unknown-user@syncthing-builder 2015-03-22 14:09:14 UTC
[BFHOS] 17:01:05 INFO: My ID: BFHOS3U-LWKIQ5P-2S44XWQ-PBSJSL3-O7YUAW2-NMM2NEV-JGFPOO3-F64ABQQ
[BFHOS] 17:01:06 INFO: Starting web GUI on http://127.0.0.1:8080/
[BFHOS] 17:01:08 INFO: Starting UPnP discovery...
[BFHOS] 17:01:11 INFO: Invalid IGD response: invalid device UUID bc4b25d-4a71-371d-bd98-038eb5924b23 (continuing anyway)
[BFHOS] 17:01:11 INFO: Invalid IGD response: invalid device UUID bc4b25d-4a71-371d-bd98-038eb5924b23 (continuing anyway)
[BFHOS] 17:01:11 INFO: Invalid IGD response: invalid device UUID bc4b25d-4a71-371d-bd98-038eb5924b23 (continuing anyway)
[BFHOS] 17:01:14 INFO: UPnP discovery complete (found 3 devices).
[BFHOS] 17:01:14 INFO: Created UPnP port mapping for external port 63512 on UPnP device 'equipo_wifimedia_R' (192.168.1.1).
[BFHOS] 17:01:14 INFO: Starting local discovery announcements
[BFHOS] 17:01:14 INFO: Starting global discovery announcements
[BFHOS] 17:01:14 OK: Ready to synchronize Musica (read-write)
[BFHOS] 17:01:14 OK: Ready to synchronize SacauntosDenis (read-write)
[BFHOS] 17:01:14 OK: Ready to synchronize SyncDenis (read-write)
[BFHOS] 17:01:14 INFO: Device BFHOS3U-LWKIQ5P-2S44XWQ-PBSJSL3-O7YUAW2-NMM2NEV-JGFPOO3-F64ABQQ is "SacauntosDenis" at [dynamic]
[BFHOS] 17:01:14 INFO: Device UARDV55-OJWEADP-OKZMKPI-ZITDZQV-D4Z6KKA-ZCHGR7F-U5R5OOL-I4Q32AT is "spektr" at [dynamic]
[BFHOS] 17:01:14 INFO: Starting usage reporting
[BFHOS] 17:01:14 INFO: Completed initial scan (rw) of folder Musica
[BFHOS] 17:01:14 INFO: Completed initial scan (rw) of folder SacauntosDenis
[BFHOS] 17:01:29 INFO: Established secure connection to UARDV55-OJWEADP-OKZMKPI-ZITDZQV-D4Z6KKA-ZCHGR7F-U5R5OOL-I4Q32AT at 192.168.1.2:22000-192.168.1.207:36246
[BFHOS] 17:01:29 INFO: Connection to UARDV55-OJWEADP-OKZMKPI-ZITDZQV-D4Z6KKA-ZCHGR7F-U5R5OOL-I4Q32AT closed: EOF
[BFHOS] 17:01:45 INFO: Established secure connection to UARDV55-OJWEADP-OKZMKPI-ZITDZQV-D4Z6KKA-ZCHGR7F-U5R5OOL-I4Q32AT at [fe80::92e6:baff:fec4:c6a%eth0]:41166-[fe80::5a94:6bff:feaa:c038%eth0]:22000
panic: runtime error: slice bounds out of range

goroutine 222 [running]:
github.com/calmh/xdr.(*Reader).ReadBytesMaxInto(0x1a721380, 0x40, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)

from syncthing.

AudriusButkevicius avatar AudriusButkevicius commented on May 22, 2024

Your's is most likely two incompatible versions connecting. Check that all devices are either on 0.10 or 0.11.

from syncthing.

DinizCabreira avatar DinizCabreira commented on May 22, 2024

Indeed, that was the case. Thank you! :)

Shouldn't Syncthing detect incompatible versions and ignore them, perhaps after spawning a warning, but keep working with other peers that have compatible ones, rather than crashing?

from syncthing.

AudriusButkevicius avatar AudriusButkevicius commented on May 22, 2024

It warns you when you upgrade.
If the protocol is incompatible, we might not even be able to read the version.

from syncthing.

calmh avatar calmh commented on May 22, 2024

Holy issue necromancy, batman! :)

from syncthing.

calmh avatar calmh commented on May 22, 2024

The actual crash is fixed though, in v0.11.

from syncthing.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.