Author Topic: improper handling of connection failure and something else  (Read 3096 times)

Pedro

  • Guest
Sorry, long post :oops:

I have my servers setup like this (with max # connections)
A (3)
--B (1)
--C (4)
B (1)
--A (3)
--C (4)

So each of my primary servers are each others back-ups. As I understand there is no better way to set this up in Altbinz.
C is a pay per GB server I use for fills.

I have two problems, possibly related:

1. One of my primary servers (B) refused to connect, with the result that altbinz tries to connect over and over again. The one part it tries to download it does not download from the other servers.
As a result the download never completes, the file is not saved (although it is 99% complete) and no par files are being downloaded (even though there are enough avaiable).

The problem was fixed by restarting altbinz and then, by chance, it tried to download the part from my other primary server (A).

2. When starting another download that was really old and was only available from server C, the system downloaded some parts from server C, but then it got stuck with 4 threads trying to connect to server B. Even though I set server B up with 1 connection as primary an 1 connection as backup server for A. I do not understand how it can be that Altbinz tries to connect to server B with more than 2 threads.
My guess is that for each connection on A Altbinz get an error 430 it starts a thread to the backup server and the number of connections for the backup server is just ignored. (BTW B is able to handle 2 connections, when it works :) ).
On the other hand if this is how it works I do not understand how some parts were downloaded from server C at all. :?:

My suggestion (just trying to help, not trying to be arrogant):
- Treat a number of failed (re)connects just as an error 430 and try another server (primary or backup).
- Create a different system for server priority setting that is able to control the total number of connections to a server.
e.g.

A
B
--C

Where A and B have the same priority and part is only downloaded from C if both A and B do not have it.

As a workaround I have removed server B from the setup and that seems to work.