|
| 1 | +# is this config file disabled |
| 2 | +# false for enabled |
| 3 | +# true for disabled |
| 4 | +disabled=false |
| 5 | + |
| 6 | +# the name of the group this storage server belongs to |
| 7 | +# |
| 8 | +# comment or remove this item for fetching from tracker server, |
| 9 | +# in this case, use_storage_id must set to true in tracker.conf, |
| 10 | +# and storage_ids.conf must be configed correctly. |
| 11 | +group_name=group1 |
| 12 | + |
| 13 | +# bind an address of this host |
| 14 | +# empty for bind all addresses of this host |
| 15 | +bind_addr= |
| 16 | + |
| 17 | +# if bind an address of this host when connect to other servers |
| 18 | +# (this storage server as a client) |
| 19 | +# true for binding the address configed by above parameter: "bind_addr" |
| 20 | +# false for binding any address of this host |
| 21 | +client_bind=true |
| 22 | + |
| 23 | +# the storage server port |
| 24 | +port=23000 |
| 25 | + |
| 26 | +# connect timeout in seconds |
| 27 | +# default value is 30s |
| 28 | +connect_timeout=10 |
| 29 | + |
| 30 | +# network timeout in seconds |
| 31 | +# default value is 30s |
| 32 | +network_timeout=60 |
| 33 | + |
| 34 | +# heart beat interval in seconds |
| 35 | +heart_beat_interval=30 |
| 36 | + |
| 37 | +# disk usage report interval in seconds |
| 38 | +stat_report_interval=60 |
| 39 | + |
| 40 | +# the base path to store data and log files |
| 41 | +base_path=/home/fdfs |
| 42 | + |
| 43 | +# max concurrent connections the server supported |
| 44 | +# default value is 256 |
| 45 | +# more max_connections means more memory will be used |
| 46 | +# you should set this parameter larger, eg. 10240 |
| 47 | +max_connections=1024 |
| 48 | + |
| 49 | +# the buff size to recv / send data |
| 50 | +# this parameter must more than 8KB |
| 51 | +# default value is 64KB |
| 52 | +# since V2.00 |
| 53 | +buff_size = 256KB |
| 54 | + |
| 55 | +# accept thread count |
| 56 | +# default value is 1 |
| 57 | +# since V4.07 |
| 58 | +accept_threads=1 |
| 59 | + |
| 60 | +# work thread count, should <= max_connections |
| 61 | +# work thread deal network io |
| 62 | +# default value is 4 |
| 63 | +# since V2.00 |
| 64 | +work_threads=4 |
| 65 | + |
| 66 | +# if disk read / write separated |
| 67 | +## false for mixed read and write |
| 68 | +## true for separated read and write |
| 69 | +# default value is true |
| 70 | +# since V2.00 |
| 71 | +disk_rw_separated = true |
| 72 | + |
| 73 | +# disk reader thread count per store base path |
| 74 | +# for mixed read / write, this parameter can be 0 |
| 75 | +# default value is 1 |
| 76 | +# since V2.00 |
| 77 | +disk_reader_threads = 1 |
| 78 | + |
| 79 | +# disk writer thread count per store base path |
| 80 | +# for mixed read / write, this parameter can be 0 |
| 81 | +# default value is 1 |
| 82 | +# since V2.00 |
| 83 | +disk_writer_threads = 1 |
| 84 | + |
| 85 | +# when no entry to sync, try read binlog again after X milliseconds |
| 86 | +# must > 0, default value is 200ms |
| 87 | +sync_wait_msec=50 |
| 88 | + |
| 89 | +# after sync a file, usleep milliseconds |
| 90 | +# 0 for sync successively (never call usleep) |
| 91 | +sync_interval=0 |
| 92 | + |
| 93 | +# storage sync start time of a day, time format: Hour:Minute |
| 94 | +# Hour from 0 to 23, Minute from 0 to 59 |
| 95 | +sync_start_time=00:00 |
| 96 | + |
| 97 | +# storage sync end time of a day, time format: Hour:Minute |
| 98 | +# Hour from 0 to 23, Minute from 0 to 59 |
| 99 | +sync_end_time=23:59 |
| 100 | + |
| 101 | +# write to the mark file after sync N files |
| 102 | +# default value is 500 |
| 103 | +write_mark_file_freq=500 |
| 104 | + |
| 105 | +# path(disk or mount point) count, default value is 1 |
| 106 | +store_path_count=1 |
| 107 | + |
| 108 | +# store_path#, based 0, if store_path0 not exists, it's value is base_path |
| 109 | +# the paths must be exist |
| 110 | +store_path0=/home/fdfs |
| 111 | +#store_path1=/home/fdfs2 |
| 112 | + |
| 113 | +# subdir_count * subdir_count directories will be auto created under each |
| 114 | +# store_path (disk), value can be 1 to 256, default value is 256 |
| 115 | +subdir_count_per_path=256 |
| 116 | + |
| 117 | +# tracker_server can ocur more than once, and tracker_server format is |
| 118 | +# "host:port", host can be hostname or ip address |
| 119 | +tracker_server=127.0.0.1:22122 |
| 120 | + |
| 121 | +#standard log level as syslog, case insensitive, value list: |
| 122 | +### emerg for emergency |
| 123 | +### alert |
| 124 | +### crit for critical |
| 125 | +### error |
| 126 | +### warn for warning |
| 127 | +### notice |
| 128 | +### info |
| 129 | +### debug |
| 130 | +log_level=info |
| 131 | + |
| 132 | +#unix group name to run this program, |
| 133 | +#not set (empty) means run by the group of current user |
| 134 | +run_by_group= |
| 135 | + |
| 136 | +#unix username to run this program, |
| 137 | +#not set (empty) means run by current user |
| 138 | +run_by_user= |
| 139 | + |
| 140 | +# allow_hosts can ocur more than once, host can be hostname or ip address, |
| 141 | +# "*" (only one asterisk) means match all ip addresses |
| 142 | +# we can use CIDR ips like 192.168.5.64/26 |
| 143 | +# and also use range like these: 10.0.1.[0-254] and host[01-08,20-25].domain.com |
| 144 | +# for example: |
| 145 | +# allow_hosts=10.0.1.[1-15,20] |
| 146 | +# allow_hosts=host[01-08,20-25].domain.com |
| 147 | +# allow_hosts=192.168.5.64/26 |
| 148 | +allow_hosts=* |
| 149 | + |
| 150 | +# the mode of the files distributed to the data path |
| 151 | +# 0: round robin(default) |
| 152 | +# 1: random, distributted by hash code |
| 153 | +file_distribute_path_mode=0 |
| 154 | + |
| 155 | +# valid when file_distribute_to_path is set to 0 (round robin), |
| 156 | +# when the written file count reaches this number, then rotate to next path |
| 157 | +# default value is 100 |
| 158 | +file_distribute_rotate_count=100 |
| 159 | + |
| 160 | +# call fsync to disk when write big file |
| 161 | +# 0: never call fsync |
| 162 | +# other: call fsync when written bytes >= this bytes |
| 163 | +# default value is 0 (never call fsync) |
| 164 | +fsync_after_written_bytes=0 |
| 165 | + |
| 166 | +# sync log buff to disk every interval seconds |
| 167 | +# must > 0, default value is 10 seconds |
| 168 | +sync_log_buff_interval=10 |
| 169 | + |
| 170 | +# sync binlog buff / cache to disk every interval seconds |
| 171 | +# default value is 60 seconds |
| 172 | +sync_binlog_buff_interval=10 |
| 173 | + |
| 174 | +# sync storage stat info to disk every interval seconds |
| 175 | +# default value is 300 seconds |
| 176 | +sync_stat_file_interval=300 |
| 177 | + |
| 178 | +# thread stack size, should >= 512KB |
| 179 | +# default value is 512KB |
| 180 | +thread_stack_size=512KB |
| 181 | + |
| 182 | +# the priority as a source server for uploading file. |
| 183 | +# the lower this value, the higher its uploading priority. |
| 184 | +# default value is 10 |
| 185 | +upload_priority=10 |
| 186 | + |
| 187 | +# the NIC alias prefix, such as eth in Linux, you can see it by ifconfig -a |
| 188 | +# multi aliases split by comma. empty value means auto set by OS type |
| 189 | +# default values is empty |
| 190 | +if_alias_prefix= |
| 191 | + |
| 192 | +# if check file duplicate, when set to true, use FastDHT to store file indexes |
| 193 | +# 1 or yes: need check |
| 194 | +# 0 or no: do not check |
| 195 | +# default value is 0 |
| 196 | +check_file_duplicate=0 |
| 197 | + |
| 198 | +# file signature method for check file duplicate |
| 199 | +## hash: four 32 bits hash code |
| 200 | +## md5: MD5 signature |
| 201 | +# default value is hash |
| 202 | +# since V4.01 |
| 203 | +file_signature_method=hash |
| 204 | + |
| 205 | +# namespace for storing file indexes (key-value pairs) |
| 206 | +# this item must be set when check_file_duplicate is true / on |
| 207 | +key_namespace=FastDFS |
| 208 | + |
| 209 | +# set keep_alive to 1 to enable persistent connection with FastDHT servers |
| 210 | +# default value is 0 (short connection) |
| 211 | +keep_alive=0 |
| 212 | + |
| 213 | +# you can use "#include filename" (not include double quotes) directive to |
| 214 | +# load FastDHT server list, when the filename is a relative path such as |
| 215 | +# pure filename, the base path is the base path of current/this config file. |
| 216 | +# must set FastDHT server list when check_file_duplicate is true / on |
| 217 | +# please see INSTALL of FastDHT for detail |
| 218 | +##include /home/yuqing/fastdht/conf/fdht_servers.conf |
| 219 | + |
| 220 | +# if log to access log |
| 221 | +# default value is false |
| 222 | +# since V4.00 |
| 223 | +use_access_log = false |
| 224 | + |
| 225 | +# if rotate the access log every day |
| 226 | +# default value is false |
| 227 | +# since V4.00 |
| 228 | +rotate_access_log = false |
| 229 | + |
| 230 | +# rotate access log time base, time format: Hour:Minute |
| 231 | +# Hour from 0 to 23, Minute from 0 to 59 |
| 232 | +# default value is 00:00 |
| 233 | +# since V4.00 |
| 234 | +access_log_rotate_time=00:00 |
| 235 | + |
| 236 | +# if rotate the error log every day |
| 237 | +# default value is false |
| 238 | +# since V4.02 |
| 239 | +rotate_error_log = false |
| 240 | + |
| 241 | +# rotate error log time base, time format: Hour:Minute |
| 242 | +# Hour from 0 to 23, Minute from 0 to 59 |
| 243 | +# default value is 00:00 |
| 244 | +# since V4.02 |
| 245 | +error_log_rotate_time=00:00 |
| 246 | + |
| 247 | +# rotate access log when the log file exceeds this size |
| 248 | +# 0 means never rotates log file by log file size |
| 249 | +# default value is 0 |
| 250 | +# since V4.02 |
| 251 | +rotate_access_log_size = 0 |
| 252 | + |
| 253 | +# rotate error log when the log file exceeds this size |
| 254 | +# 0 means never rotates log file by log file size |
| 255 | +# default value is 0 |
| 256 | +# since V4.02 |
| 257 | +rotate_error_log_size = 0 |
| 258 | + |
| 259 | +# keep days of the log files |
| 260 | +# 0 means do not delete old log files |
| 261 | +# default value is 0 |
| 262 | +log_file_keep_days = 0 |
| 263 | + |
| 264 | +# if skip the invalid record when sync file |
| 265 | +# default value is false |
| 266 | +# since V4.02 |
| 267 | +file_sync_skip_invalid_record=false |
| 268 | + |
| 269 | +# if use connection pool |
| 270 | +# default value is false |
| 271 | +# since V4.05 |
| 272 | +use_connection_pool = false |
| 273 | + |
| 274 | +# connections whose the idle time exceeds this time will be closed |
| 275 | +# unit: second |
| 276 | +# default value is 3600 |
| 277 | +# since V4.05 |
| 278 | +connection_pool_max_idle_time = 3600 |
| 279 | + |
| 280 | +# use the ip address of this storage server if domain_name is empty, |
| 281 | +# else this domain name will ocur in the url redirected by the tracker server |
| 282 | +http.domain_name= |
| 283 | + |
| 284 | +# the port of the web server on this storage server |
| 285 | +http.server_port=9999 |
| 286 | + |
0 commit comments