-
-
Notifications
You must be signed in to change notification settings - Fork 344
Will multiple magneticod of processes help? #23
Comments
From what i can work out in theory becuase the DHT bootstrap node node would not return the same peers for a second request the crawling would take a completely different path |
Hey @lozbrown, sorry for the belated reply. Honestly speaking, I don't know the answer and you should try and see (and please inform us as well!). The thing is, you will probably be limited by the network anyway so I don't think it will be much helpful. Lastly, one running magneticod instance should be sufficient by design (i.e. that is what we aim for), so if you see an increase in performance, let us know, and we will try to improve its performance by doing necessary modifications! =) |
I was disappointed by only scraping 30-50 torrents a minute, so modified my mana project to support multiple public ports and use a different UID for each, and launch one instance per CPU core. Gave me a clean N-fold speedup. |
@itdaniher That's interesting! Maybe we can modify the networking logic. I'll surely think about it and I would love some suggestions to make it possible in a single running instance. |
It only helps if you're CPU-bound, but the python multiprocessing library would probably be a good place to start. The obvious issue you'll run into is sharing a list of already-seen torrents amongst multiple threads. Mana uses Redis to great effect. |
This is supported in the new written-in-Go versions. You can simply pass multiple Let me know if you have any other/similar questions with the recent version of magnetico. |
I ran a test with 2 scenarios:
This test runs with an Intel(R) Atom(TM) CPU D2550 @ 1.86GHz. There is enough RAM. I have a 1Gb/s down and 600Mb/s up connection. The result is that scenario one use less CPU: ~87% vs ~107%. So I will stick with one indexer for now, since I need some CPU for something else. |
Left overnight magnetico managed to add around 100 items, so not going to imminently replace centralised sites. It's not even using much bandwidth.
But I have multiple cores, and several other raspberry Pi's sitting doing very low utilisation jobs that could be put to further work.
Would multiple magneticod processes help or would they just interfere with each other? Would they just repeat the same work?
If not could they be made to work well together?
The text was updated successfully, but these errors were encountered: