1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
|
[folders]
# DISTFILES_DIR
# Define a dir to store distfiles
# Default:
# distfiles_dir=./distfiles
distfiles_dir=./distfiles
# SEGMENTS_DIR
# Define a dir to store distfiles' segments
# Default:
# segments_dir=./tmp
segments_dir=./tmp
[pkg_list]
# PKG_LIST_DIR
# Define a dir with pkg.list file
# Default:
# pkg_list_dir=./
pkg_list_dir=./
# 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
del_pkg_list_when_dld_finished=1
[portage]
# SYNOPSIS: fetch_only=0 | 1
# NOT IMPLEMENTED YET: fetch_only=0
[distfiles]
# MAX_CONNECTION_NUM_PER_DISTFILE
# Each distfile can have up to max_connection_num_per_distfile simultaneous
# connections.
# Minimum value: 1
# Maximum value: 20
# Default:
# max_connection_num_per_distfile=3
max_connection_num_per_distfile=3
[segments]
# MAX_SEGMENT_SIZE
# Define maximum segment size in bytes.
# Minimum value: 10000
# Maximum value: 10000000
# Default:
# max_segment_size=500000
max_segment_size=500000
# SYNOPSIS: resume_on=0 | 1
# - If resume_on set to 1:
# Before starting downloading a segment segget checks whether this segment is
# already downloaded, checks segments size and if size mathces considers this
# segment to be downloaded and skips downloading process.
# - If resume_on set to 0:
# Segget always starts new fetch for a segment regardless of the fact whether it
# is downloaded or not.
# Default:
# resume_on=1
resume_on=1
# MAX_TRIES
# If segment download was unsuccessful, new attempts are made. When attempts
# number reaches max_tries, segment gets FAILED status and error logged to error_log
# Minimum value: 1
# Maximum value: -1 (for no limit)
# Default:
# max_tries=10
max_tries=10
[connections]
# MAX_CONNECTIONS
# Define maximum number of connections
# Minimum value: 1
# Maximum value: 20
# Default:
# max_connections=10
max_connections=10
# 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.
# Minimum value: 100
# Maximum value: 60000
# Default:
# current_speed_time_interval_msecs=1000
current_speed_time_interval_msecs=1000
# NOT IMPLEMENTED YET: max_total_speed=50000
[mirrors]
# MAX_CONNECTIONS_NUM_PER_MIRROR
# Define how many simultaneous downloads from one mirror segget is allowed to
# have. While choosing a mirror segget will skip mirrors with
# max_connections_num_per_mirror active downloads.
# Minimum value: 1
# Maximum value: 10
# Default:
# max_connections_num_per_mirror=1
max_connections_num_per_mirror=1
# SYNOPSIS: collect_benchmark_stats_on=0 | 1
# - If set to 1, stats on mirrors performance will be collected.
# default:
# collect_benchmark_stats_on=1 (Note: at the moment can NOT be changed)
collect_benchmark_stats_on=1
# 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
use_benchmark_stats=1
# 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.
# Minimum value: 0 (Beware: setting to 0, will can exclude unlucky mirrors)
# Maximum value: 1000
# Default:
# benchmark_oblivion=5
benchmark_oblivion=5
[provide_mirror_to_others]
# PROVIDE_MIRROR_DIR
# Define a dir for making symlinks to downloaded distfiles. This dir can be
# used to provide local mirror for other hosts (with help of Apache, vsftp, etc).
# If set to none, segget will not make symlinks.
# Default:
# provide_mirror_dir=none
provide_mirror_dir=./provide_mirror_dir
# 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_files_restrict_list_on=0
[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=none
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=3131
provide_proxy_fetcher_port=3130
[networks]
# NETWORK0_PRIORITY
# Define priority as a value in range from lowest 0 to highest 10.
# Segget tries to use networks with higher priority levels first, and in case of
# failure will switch to networks with lower priority levels.
# Segget will NOT use network if its priority level set to 0. Therefore at least
# one network must have priority level higher than 0.
# Networks with local mirrors usually would have higher priority than that of
# networks with remote mirrors.
# Segget can have up to 10 networks (from network0 to network9).
# Settings for each network should be defined in network#.conf file, where
# instead of # should be network number. For network0 it's network0.conf
# Default:
# 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
network0_priority=0
network1_priority=0
network2_priority=0
network3_priority=0
network4_priority=7
network5_priority=0
network6_priority=0
network7_priority=0
network8_priority=0
network9_priority=0
[schedule]
[user-data]
# 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
user_agent=segget
# Specify the user and password for authentication on a ftp servers.
# NOT IMPLEMENTED YET: ftp-user=anonymous
# NOT IMPLEMENTED YET: ftp-password=me@mail.ru
[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
ui_ip=127.0.0.1
# UI_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:
# ui_port=9999
ui_port=9999
[logs]
# LOGS_DIR
# Define a dir to store log files.
# Default:
# logs_dir=./logs
logs_dir=./logs
# GENERAL_LOG_FILE
# Define a file name to store general log.
# Set to none to disable loggin.
# Default:
# general_log_file=segget.log
general_log_file=segget.log
# ERROR_LOG_FILE
# Define a file name to store error log.
# Set to none to disable loggin.
# Default:
# error_log_file=segget.log
error_log_file=error.log
# DEBUG_LOG_FILE
# Define a file name to store debug log.
# Set to none to disable loggin.
# Default:
# debug_log_file=segget.log
debug_log_file=debug.log
|