| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
|
| |
0) Segget starts from the highest priority networks.
1) Segget tries local mirrors and mirrors provided by proxy-fetchers first.
2) If no success and requests to proxy-fetchers are allowed => segget selects proxy-fetcher and requests from it.
3) If proxy-fetcher replied that file has been downloaded => segget starts from step 1 again.
4) If no download started till now and remote-mirrors are allowed => segget selects a remote network and selects a mirror from it.
5) If no success on step 4, segget switches to lower priority networks
|
| |
|
|
|
|
|
|
|
|
|
| |
R_PF_BE_MORE_PATIENT
R_PF_ERROR_ADDING_TO_PROXY_QUEUE
R_PF_ADDED_TO_PROXY_QUEUE
R_PF_ALREADY_WAS_IN_QUEUE
R_PF_DOWNLOADED
R_PF_FAILED
|
|
|
|
| |
don't add it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ui_server]
tuiclient monitors segget's activity by establishing tcp connection
with segget daemon (ui_server part of it).
UI_IP
Define an ip address segget uses to provide access for tuiclients.
The parameter should be a string holding your host dotted IP address.
Default:
ui_ip=127.0.0.1
UI_PORT
Define a port segget uses to provide access for tuiclients.
The parameter should be an integer.
Minimum value: 1
Maximum value: 65535
Default:
ui_port=9999
[logs]
LOGS_DIR
Define a dir to store log files.
Default:
logs_dir=./logs
GENERAL_LOG_FILE
Define a file name to store general log.
Default:
general_log_file=tuiclient.log
ERROR_LOG_FILE
Define a file name to store error log.
Default:
error_log_file=segget.log
DEBUG_LOG_FILE
Define a file name to store debug log.
Default:
debug_log_file=segget.log
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PROXY_FETCHER_IP
This option is active only when NETWORK_MODE=1, in other cases it's ignored.
Specify IP addres of the proxy-fetcher
Default:
proxy_fetcher_ip=none
PROXY_FETCHER_PORT
This option is active only when NETWORK_MODE=1, in other cases it's ignored.
Specify proxy-fetcher address
Default:
proxy_fetcher_port=3131
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NOTE: Proxy-fetcher downloads distfiles requested by other segget daemons.
File will be ignored if it's already downloaded.
TO-DO: Proxy-fetcher needs to check if distfile is already in the download list.
[provide_proxy_fetcher_to_others]
PROVIDE_PROXY_FETCHER_IP
Define an ip address segget will use to provide access for tuiclients.
The parameter should be a string holding your host dotted IP address.
Default:
provide_proxy_fetcher_ip=127.0.0.1
PROVIDE_PROXY_FETCHER_PORT
Define a port segget will use to provide access for tuiclients.
The parameter should be an integer.
Minimum value: 1
Maximum value: 65535
Default:
provide_proxy_fetcher_port=9777
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ui_server]
tuiclient monitors segget's activity by establishing tcp connection
with segget daemon (ui_server part of it).
UI_IP
Define an ip address segget will use to provide access for tuiclients.
The parameter should be a string holding your host dotted IP address.
Default:
ui_ip=127.0.0.1
Define a port segget will use to provide access for tuiclients.
The parameter should be an integer.
Minimum value: 1
Maximum value: 65535
Default:
ui_port=9999
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Prepare segget for daemon phase.
Segget gets ui_server interface and tuiclient in curses as a separate app.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
to segget.conf file
SYNOPSIS: PROVIDE_MIRROR_FILES_RESTRICT_LIST_ON= 0 | 1
If PROVIDE_MIRROR_DIR=none this option will be ignored.
- If set to 1, segget will compare distfile name with the list of forbiden
patterns from the restricted.conf file. If distfile name contains any of the
patterns, no symlink will be provided to this distfile.
Default:
provide_mirror_files_restrict_list_on=0
|
|
|
|
|
|
|
|
| |
[provide_mirror_to_others]
PROVIDE_MIRROR_DIR
Define a dir to store distfiles for mirroring.
Default:
provide_mirror_dir=./provide_mirror_dir
|
|
|
|
| |
network_array[network_num].benchmarked_mirror_list
|
|
|
|
|
|
|
|
|
|
|
|
| |
SYNOPSIS: ONLY_LOCAL_WHEN_POSSIBLE=0 | 1
If NETWORK_USES_OWN_MIRROR_LIST_ONLY_ON=0 this option will be ignored.
- If set to 1, segget will not use remote mirrors with equal or lower priority
until all mirrors in network0_mirrors.conf file have failed.
- If set to 0, segget will use remote mirrors with equal priority or mirrors
with lower priority when this network has NO free connections (see option
NETWORK_MAX_CONNECTIONS in [network_connections] section of this file).
Default:
only_local_when_possible=1
|
|
|
|
|
|
|
|
|
|
|
| |
network#.conf :: [network_mirrors]
SYNOPSIS: NETWORK_USES_OWN_MIRROR_LIST_ONLY_ON=0 | 1
- If set to 1, segget will replace mirror list provided by portage system with
the list from network1_mirrors.conf
- If set to 0, segget will use ONLY mirror list provided by portage system,
and will NOT use the list from network1_mirrors.conf file
Default:
use_own_mirror_list_only_on=0
|
|
|
|
| |
Network with the smallest active_connections_num wins.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add [networks] section to segget.conf
[networks]
network0_priority=10
network1_priority=0
network2_priority=0
network3_priority=0
network4_priority=0
network5_priority=0
network6_priority=0
network7_priority=0
network8_priority=0
network9_priority=0
2) Following options moved from segget.conf to network#.conf
[network_bind]
bind_interface=none
[network_connections]
max_connections=2
connection_timeout=15
ftp_response_timeout=180
timeout=500
low_connection_speed_limit=1000
low_connection_speed_time=10
max_connection_speed=3000
[network_protocols]
[network_user_data]
user_agent=segget
[network_proxy]
proxy_ip_or_name=none
proxy_port=3128
proxy_user=none
proxy_password=none
proxy_off=1
[network_mirrors]
use_own_mirror_list_on=0
|
|
|
|
|
|
|
|
| |
SYNOPSIS: del_pkg_list_when_dld_finished=0 | 1
- If del_pkg_list_when_dld_finished set to 1:
Segget deletes pkg.list file, after all distfiles were successfuly fetched.
Default:
del_pkg_list_when_dld_finished=1
|
|
|
|
|
|
|
| |
PKG_LIST_DIR
Define a dir with pkg.list file
Default:
pkg_list_dir=./
|
|
|
|
| |
connection->avg_speed=connection->total_dld_bytes/time_left_from(connection->start_time);
|
|
|
|
|
|
|
|
|
|
|
| |
CURRENT_SPEED_TIME_INTERVAL_MSECS
segget transfers may have bursty nature of their traffic. Therefore, while
measuring current speed, segget actually calculates average speed during
current_speed_time_interval_msecs time interval, defined in milliseconds.
Min limit:100
Max limit: 60000
Default:
current_speed_time_interval_msecs=1000
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
1) Catch exception if segget.conf can't be opened.
2) Catch exceptions if while reading segget.conf.
3) Check if settings suplied by segget.conf can be converted to appropriate type.
4) Check if settings fit allowed range from min_limit to max_limit.
5) In case there was an error apply default settings.
6) Log all described errors.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[mirrors].benchmark_oblivion
SYNOPSIS: use_benchmark_stats=0 | 1
If use_benchmark_stats=1 statistics on mirrors is used to rate them
and therefore improve performance.
Each time connection from a particular mirror closes mirror->dld_time,
and mirror->dld_size get increased (in case of unsuccessful connection
only time gets increased), so avg speed for a mirror can be
calculated:
mirror->avg_speed=mirror->dld_size/mirror->dld_time. (1)
When new segment is going to be started segget goes through the list of
the mirrors distfile/segment has, and asks each mirror for self_rating:
"ulong self_rating=mirror->mirror_on_the_wall();".
This way segget chooses a mirror with the best self_rating. To calculate
self_rating mirrors use the following formula:
self_rating=dld_time/dld_size*honesty. (2)
So mirrors actually say how bad they are.
Even mirrors can have critical times, so to give mirrors another chance
honesty was added to the formula (2). honesty can get values in
interval (0,1]. Each time connection from a mirror opens or closes mirror
sets its honesty=1. If mirror was asked for self_evaluation with
mirror->mirror_on_the_wall(), but wasn't chosen its honesty decreases
somewhat (see [mirror].benchmark_oblivion option), so next time it will
lie little bit more about how bad it's.
Default:
use_benchmark_results=1
***Note: at the moment use_benchmark_results can NOT be set to 0
BENCHMARK_OBLIVION
benchmark_oblivion option allows to adjust how fast segget "forgets"
benchmarking statistics on mirrors performance.
Each time mirror->mirror_on_the_wall() called, mirror decreases its
honesty (to have more chances next time) using the following formula:
honesty=honesty*100/(100+settings.benchmark_oblivion) (3)
Therefore, setting benchmark_oblivion=100 will make mirror look twice
less bad next time mirror->mirror_on_the_wall() called.
Default:
benchmark_oblivion=5
|
|
|
|
|
|
|
|
| |
max_tries=10
ftp_response_timeout=180
timeout=500
max_connections_num_per_mirror=1
proxy_port=3128.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
LOGS_DIR
Define a dir to store log files.
Default:
logs_dir=./logs
GENERAL_LOG_FILE
Define a file name to store general log.
Default:
general_log_file=segget.log
ERROR_LOG_FILE
Define a file name to store error log.
Default:
error_log_file=segget.log
DEBUG_LOG_FILE
Define a file name to store debug log.
Default:
debug_log_file=debug.log
|
|
|
|
|
|
|
|
| |
USER_AGENT
Set the User-Agent: header in the http request sent to the remote server.
This can be used to fool servers or scripts.
Default:
user_agent=segget
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PROXY_IP_OR_NAME
Specify a proxy to use (address and port).
Set HTTP proxy to use. The parameter should be a string holding the proxy host
name or dotted IP address. To specify port number in this string,
append :[port] to the end of the host name. The proxy string may be prefixed
with [protocol]:// since any such prefix will be ignored. The proxy's port
number may optionally be specified with the separate option. If not specified,
by default port 1080 will be used for proxies.
When you tell segget to use an HTTP proxy, segget will transparently convert
operations to HTTP even if you specify an FTP URL etc.
Segget respects the environment variables http_proxy, ftp_proxy, all_proxy etc,
if any of those are set. The PROXY option does however override any possibly
set environment variables.
Default:
proxy_ip_or_name=none
PROXY_PORT
Set the proxy port to connect to unless it is specified in the PROXY option.
Default:
proxy_port=1080
PROXY_USER
Set user name to use for the transfer while connecting to Proxy.
The PROXY_USER option should be used in same way as the PROXY_PASSWORD is used.
In order to specify the password to be used in conjunction with the user name
use the PROXY_PASSWORD option.
Default:
proxy_user=none
PROXY_PASSWORD
Set password to use for the transfer while connecting to Proxy.
The PROXY_PASSWORD option should be used in conjunction with the PROXY_USER
option.
Default:
proxy_password=none
SYNOPSIS: proxy_off=0 | 1
Setting the proxy_off=1 will explicitly disable the use of a proxy, even if
there is an environment variable set for it.
Default:
proxy_off=1
|
|
|
|
|
|
|
|
|
| |
benchmark_oblivion option allows to adjust how fast segget "forgets" benchmarking
statistics on mirrors performance.
Default:
benchmark_oblivion=5
Note: settings.forgetness option replaced by settings.benchmark_oblivion.
|
|
|
|
|
|
|
|
| |
[mirrors].max_connections_num_per_mirror
Segget gathers stats on mirrors and uses it to rate them and therefore improve performance.
settings.forgetness option (by default set to 5) allows to adjust how fast segget "forgets"
about bad performance of a mirror.
|
|
|
|
|
|
|
|
|
| |
BIND INTERFACE / IP
Pass a string as parameter. This sets the interface name to use as outgoing
network interface. The name can be an interface name, an IP address, or a host
name. No binding is set by default.
default:
bind_interface=none
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[connections].low_connection_speed_time
LOW_CONNECTION_SPEED_LIMIT
Define the low speed limit for connection. Pass a long as parameter. It
contains the transfer speed in bytes per second that the transfer should be
below during LOW_CONNECTION_SPEED_TIME seconds to consider it too slow and abort.
default:
low_connection_speed_limit=1000
LOW_CONNECTION_SPEED_TIME
Pass a long as parameter. It contains the time in seconds that the transfer
should be below the LOW_SPEED_LIMIT to consider it too slow and abort.
default:
low_connection_speed_time=10
|