aria2c.1 43 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656
  1. .\" Title: aria2c
  2. .\" Author:
  3. .\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
  4. .\" Date: 01/19/2009
  5. .\" Manual:
  6. .\" Source:
  7. .\"
  8. .TH "ARIA2C" "1" "01/19/2009" "" ""
  9. .\" disable hyphenation
  10. .nh
  11. .\" disable justification (adjust text to left margin only)
  12. .ad l
  13. .SH "NAME"
  14. aria2c \- The ultra fast download utility
  15. .SH "SYNOPSIS"
  16. aria2c [\fIOPTIONS\fR] [\fIURL\fR | \fITORRENT_FILE\fR | \fIMETALINK_FILE\fR]\&...
  17. .sp
  18. .SH "DESCRIPTION"
  19. aria2 is a utility for downloading files\&. The supported protocols are HTTP(S), FTP, BitTorrent, and Metalink\&. aria2 can download a file from multiple sources/protocols and tries to utilize your maximum download bandwidth\&. It supports downloading a file from HTTP(S)/FTP and BitTorrent at the same time, while the data downloaded from HTTP(S)/FTP is uploaded to the BitTorrent swarm\&. Using Metalink\'s chunk checksums, aria2 automatically validates chunks of data while downloading a file like BitTorrent\&.
  20. .sp
  21. .SH "OPTIONS"
  22. .SS "Basic Options"
  23. .PP
  24. \fB\-d\fR, \fB\-\-dir\fR=DIR
  25. .RS 4
  26. The directory to store the downloaded file\&.
  27. .RE
  28. .PP
  29. \fB\-i\fR, \fB\-\-input\-file\fR=FILE
  30. .RS 4
  31. Downloads URIs found in FILE\&. You can specify multiple URIs for a single entity: separate URIs on a single line using the TAB character\&. Reads input from stdin when
  32. \fI\-\fR
  33. is specified\&. The additional
  34. \fBout\fR
  35. and
  36. \fBdir\fR
  37. options can be specified after each line of URIs\&. This optional line must start with white space(s)\&. See INPUT FILE section for details\&.
  38. .RE
  39. .PP
  40. \fB\-l\fR, \fB\-\-log\fR=LOG
  41. .RS 4
  42. The file name of the log file\&. If
  43. \fI\-\fR
  44. is specified, log is written to stdout\&.
  45. .RE
  46. .PP
  47. \fB\-j\fR, \fB\-\-max\-concurrent\-downloads\fR=N
  48. .RS 4
  49. Set maximum number of parallel downloads for every static (HTTP/FTP) URL, torrent and metalink\&. See also
  50. \fB\-s\fR
  51. and
  52. \fB\-C\fR
  53. option\&. Default:
  54. \fI5\fR
  55. .RE
  56. .PP
  57. \fB\-V\fR, \fB\-\-check\-integrity\fR[=\fItrue\fR|\fIfalse\fR]
  58. .RS 4
  59. Check file integrity by validating piece hashes\&. This option has effect only in BitTorrent and Metalink downloads with chunk checksums\&. Use this option to re\-download a damaged portion of a file\&. Default:
  60. \fIfalse\fR
  61. .RE
  62. .PP
  63. \fB\-c\fR, \fB\-\-continue\fR
  64. .RS 4
  65. Continue downloading a partially downloaded file\&. Use this option to resume a download started by a web browser or another program which downloads files sequentially from the beginning\&. Currently this option is only applicable to HTTP(S)/FTP downloads\&.
  66. .RE
  67. .PP
  68. \fB\-h\fR, \fB\-\-help\fR[=CATEGORY]
  69. .RS 4
  70. Print usage and exit\&. The help messages are classified in several categories\&. For example, type "\fB\-\-help\fR=http" for detailed explanation for the options related to HTTP\&. If no matching category is found, search option name using a given word in middle match and print the result\&. Available Values:
  71. \fIbasic\fR,
  72. \fIadvanced\fR,
  73. \fIhttp\fR,
  74. \fIhttps\fR,
  75. \fIftp\fR,
  76. \fImetalink\fR,
  77. \fIbittorrent\fR,
  78. \fIall\fR
  79. Default:
  80. \fIbasic\fR
  81. .RE
  82. .SS "HTTP/FTP Options"
  83. .PP
  84. \fB\-\-all\-proxy\fR=PROXY
  85. .RS 4
  86. Use this proxy server for all protocols\&. You can override this setting and specify a proxy server for a particular protocol using
  87. \fB\-\-http\-proxy\fR,
  88. \fB\-\-https\-proxy\fR
  89. and
  90. \fB\-\-ftp\-proxy\fR
  91. options\&. This affects all URLs\&. The format of PROXY is [http://][USER:PASSWORD@]HOST[:PORT]
  92. .RE
  93. .PP
  94. \fB\-\-connect\-timeout\fR=SEC
  95. .RS 4
  96. Set the connect timeout in seconds to establish connection to HTTP/FTP/proxy server\&. After the connection is established, this option makes no effect and
  97. \fB\-\-timeout\fR
  98. option is used instead\&. Default:
  99. \fI60\fR
  100. .RE
  101. .PP
  102. \fB\-\-lowest\-speed\-limit\fR=SPEED
  103. .RS 4
  104. Close connection if download speed is lower than or equal to this value(bytes per sec)\&.
  105. \fI0\fR
  106. means aria2 does not have a lowest speed limit\&. You can append
  107. \fIK\fR
  108. or
  109. \fIM\fR(1K = 1024, 1M = 1024K)\&. This option does not affect BitTorrent downloads\&. Default:
  110. \fI0\fR
  111. .RE
  112. .PP
  113. \fB\-\-max\-file\-not\-found\fR=NUM
  114. .RS 4
  115. If aria2 receives `file not found\' status from the remote HTTP/FTP servers NUM times without getting a single byte, then force the download to fail\&. Specify
  116. \fI0\fR
  117. to disable this option\&. This options is effective only when using HTTP/FTP servers\&. Default:
  118. \fI0\fR
  119. .RE
  120. .PP
  121. \fB\-m\fR, \fB\-\-max\-tries\fR=N
  122. .RS 4
  123. Set number of tries\&.
  124. \fI0\fR
  125. means unlimited\&. Default:
  126. \fI5\fR
  127. .RE
  128. .PP
  129. \fB\-\-no\-proxy\fR=DOMAINS
  130. .RS 4
  131. Specify comma separated hostnames or domains where proxy should not be used\&.
  132. .RE
  133. .PP
  134. \fB\-o\fR, \fB\-\-out\fR=FILE
  135. .RS 4
  136. The file name of the downloaded file\&.
  137. .RE
  138. .sp
  139. .it 1 an-trap
  140. .nr an-no-space-flag 1
  141. .nr an-break-flag 1
  142. .br
  143. Note
  144. In Metalink or BitTorrent download you cannot specify file name\&. The file name specified here is only used when the URLs fed to aria2 are done by command line without \fB\-i\fR, \fB\-Z\fR option\&. For example: aria2c \-o myfile\&.zip http://mirror1/file\&.zip http://mirror2/file\&.zip
  145. .PP
  146. \fB\-\-proxy\-method\fR=METHOD
  147. .RS 4
  148. Set the method to use in proxy request\&.
  149. \fIMETHOD\fR
  150. is either
  151. \fIget\fR
  152. or
  153. \fItunnel\fR\&. Default:
  154. \fItunnel\fR
  155. .RE
  156. .PP
  157. \fB\-R\fR, \fB\-\-remote\-time\fR[=\fItrue\fR|\fIfalse\fR]
  158. .RS 4
  159. Retrieve timestamp of the remote file from the remote HTTP/FTP server and if it is available, apply it to the local file\&. Default:
  160. \fIfalse\fR
  161. .RE
  162. .PP
  163. \fB\-\-retry\-wait\fR=SEC
  164. .RS 4
  165. Set the seconds to wait to retry after an error has occured\&. Specify a value between
  166. \fI0\fR
  167. and
  168. \fI60\fR\&. Default:
  169. \fI5\fR
  170. .RE
  171. .PP
  172. \fB\-\-server\-stat\-of\fR=FILE
  173. .RS 4
  174. Specify the filename to which performance profile of the servers is saved\&. You can load saved data using
  175. \fB\-\-server\-stat\-if\fR
  176. option\&. See SERVER PERFORMANCE PROFILE section below for file format\&.
  177. .RE
  178. .PP
  179. \fB\-\-server\-stat\-if\fR=FILE
  180. .RS 4
  181. Specify the filename to load performance profile of the servers\&. The loaded data will be used in some URI selector such as
  182. \fIfeedback\fR\&. See also
  183. \fB\-\-uri\-selector\fR
  184. option\&. See SERVER PERFORMANCE PROFILE section below for file format\&.
  185. .RE
  186. .PP
  187. \fB\-\-server\-stat\-timeout\fR=SEC
  188. .RS 4
  189. Specifies timeout in seconds to invalidate performance profile of the servers since the last contact to them\&. Default:
  190. \fI86400\fR
  191. (24hours)
  192. .RE
  193. .PP
  194. \fB\-s\fR, \fB\-\-split\fR=N
  195. .RS 4
  196. Download a file using N connections\&. If more than N URLs are given, first N URLs are used and remaining URLs are used for backup\&. If less than N URLs are given, those URLs are used more than once so that N connections total are made simultaneously\&. Please see
  197. \fB\-j\fR
  198. option too\&. Please note that in Metalink download, this option has no effect and use
  199. \fB\-C\fR
  200. option instead\&. Default:
  201. \fI5\fR
  202. .RE
  203. .PP
  204. \fB\-t\fR, \fB\-\-timeout\fR=SEC
  205. .RS 4
  206. Set timeout in seconds\&. Default:
  207. \fI60\fR
  208. .RE
  209. .PP
  210. \fB\-\-uri\-selector\fR=SELECTOR
  211. .RS 4
  212. Specify URI selection algorithm\&. Possible values are
  213. \fIinorder\fR
  214. and
  215. \fIfeedback\fR\&. If
  216. \fIinorder\fR
  217. is given, URI is tried in the order appeared in the URI list\&. If
  218. \fIfeedback\fR
  219. is given, aria2 uses download speed observed in the previous downloads and choose fastest server in the URI list\&. This also effectively skips dead mirrors\&. The observed download speed is a part of performance profile of servers mentioned in
  220. \fB\-\-server\-stat\-of\fR
  221. and
  222. \fB\-\-server\-stat\-if\fR
  223. options\&. Default:
  224. \fIinorder\fR
  225. .RE
  226. .SS "HTTP Specific Options"
  227. .PP
  228. \fB\-\-ca\-certificate\fR=FILE
  229. .RS 4
  230. Use the certificate authorities in FILE to verify the peers\&. The certificate file must be in PEM format and can contain multiple CA certificates\&. Use
  231. \fB\-\-check\-certificate\fR
  232. option to enable verification\&.
  233. .RE
  234. .PP
  235. \fB\-\-certificate\fR=FILE
  236. .RS 4
  237. Use the client certificate in FILE\&. The certificate must be in PEM format\&. You may use
  238. \fB\-\-private\-key\fR
  239. option to specify the private key\&.
  240. .RE
  241. .PP
  242. \fB\-\-check\-certificate\fR[=\fItrue\fR|\fIfalse\fR]
  243. .RS 4
  244. Verify the peer using certificates specified in
  245. \fB\-\-ca\-certificate\fR
  246. option\&. Default:
  247. \fItrue\fR
  248. .RE
  249. .PP
  250. \fB\-\-http\-auth\-scheme\fR=SCHEME
  251. .RS 4
  252. Set HTTP authentication scheme\&. Currently,
  253. \fIbasic\fR
  254. is the only supported scheme\&. Default:
  255. \fIbasic\fR
  256. .RE
  257. .PP
  258. \fB\-\-http\-user\fR=USER
  259. .RS 4
  260. Set HTTP user\&. This affects all URLs\&.
  261. .RE
  262. .PP
  263. \fB\-\-http\-passwd\fR=PASSWD
  264. .RS 4
  265. Set HTTP password\&. This affects all URLs\&.
  266. .RE
  267. .PP
  268. \fB\-\-http\-proxy\fR=PROXY
  269. .RS 4
  270. Use this proxy server for HTTP\&. See also
  271. \fB\-\-all\-proxy\fR
  272. option\&. This affects all URLs\&. The format of PROXY is [http://][USER:PASSWORD@]HOST[:PORT]
  273. .RE
  274. .PP
  275. \fB\-\-https\-proxy\fR=PROXY
  276. .RS 4
  277. Use this proxy server for HTTPS\&. See also
  278. \fB\-\-all\-proxy\fR
  279. option\&. This affects all URLs\&. The format of PROXY is [http://][USER:PASSWORD@]HOST[:PORT]
  280. .RE
  281. .PP
  282. \fB\-\-private\-key\fR=FILE
  283. .RS 4
  284. Use the private key in FILE\&. The private key must be decrypted and in PEM format\&. The behavior when encrypted one is given is undefined\&. See also
  285. \fB\-\-certificate\fR
  286. option\&.
  287. .RE
  288. .PP
  289. \fB\-\-referer\fR=REFERER
  290. .RS 4
  291. Set Referer\&. This affects all URLs\&.
  292. .RE
  293. .PP
  294. \fB\-\-enable\-http\-keep\-alive\fR[=\fItrue\fR|\fIfalse\fR]
  295. .RS 4
  296. Enable HTTP/1\&.1 persistent connection\&. Default:
  297. \fItrue\fR
  298. .RE
  299. .PP
  300. \fB\-\-enable\-http\-pipelining\fR[=\fItrue\fR|\fIfalse\fR]
  301. .RS 4
  302. Enable HTTP/1\&.1 pipelining\&. Default:
  303. \fIfalse\fR
  304. .RE
  305. .PP
  306. \fB\-\-header\fR=HEADER
  307. .RS 4
  308. Append HEADER to HTTP request header\&. You can use this option repeatedly to specify more than one header: aria2c
  309. \fB\-\-header\fR="X\-A: b78"
  310. \fB\-\-header\fR="X\-B: 9J1" http://host/file
  311. .RE
  312. .PP
  313. \fB\-\-load\-cookies\fR=FILE
  314. .RS 4
  315. Load Cookies from FILE using the Firefox3 format (SQLite3) and the Mozilla/Firefox(1\&.x/2\&.x)/Netscape format\&.
  316. .RE
  317. .sp
  318. .it 1 an-trap
  319. .nr an-no-space-flag 1
  320. .nr an-break-flag 1
  321. .br
  322. Note
  323. If aria2 is built without libsqlite3, then it doesn\'t support Firefox3 cookie format\&.
  324. .PP
  325. \fB\-\-use\-head\fR[=\fItrue\fR|\fIfalse\fR]
  326. .RS 4
  327. Use HEAD method for the first request to the HTTP server\&. Default:
  328. \fItrue\fR
  329. .RE
  330. .PP
  331. \fB\-U\fR, \fB\-\-user\-agent\fR=USER_AGENT
  332. .RS 4
  333. Set user agent for HTTP(S) downloads\&.
  334. .RE
  335. .SS "FTP Specific Options"
  336. .PP
  337. \fB\-\-ftp\-user\fR=USER
  338. .RS 4
  339. Set FTP user\&. This affects all URLs\&. Default:
  340. \fIanonymous\fR
  341. .RE
  342. .PP
  343. \fB\-\-ftp\-passwd\fR=PASSWD
  344. .RS 4
  345. Set FTP password\&. This affects all URLs\&. Default:
  346. \fIARIA2USER@\fR
  347. .RE
  348. .PP
  349. \fB\-p\fR, \fB\-\-ftp\-pasv\fR[=\fItrue\fR|\fIfalse\fR]
  350. .RS 4
  351. Use the passive mode in FTP\&. If
  352. \fIfalse\fR
  353. is given, the active mode will be used\&. Default:
  354. \fItrue\fR
  355. .RE
  356. .PP
  357. \fB\-\-ftp\-proxy\fR=PROXY
  358. .RS 4
  359. Use this proxy server for FTP\&. See also
  360. \fB\-\-all\-proxy\fR
  361. option\&. This affects all URLs\&. The format of PROXY is [http://][USER:PASSWORD@]HOST[:PORT]
  362. .RE
  363. .PP
  364. \fB\-\-ftp\-type\fR=TYPE
  365. .RS 4
  366. Set FTP transfer type\&. TYPE is either
  367. \fIbinary\fR
  368. or
  369. \fIascii\fR\&. Default:
  370. \fIbinary\fR
  371. .RE
  372. .PP
  373. \fB\-\-ftp\-reuse\-connection\fR[=\fItrue\fR|\fIfalse\fR]
  374. .RS 4
  375. Reuse connection in FTP\&. Default:
  376. \fItrue\fR
  377. .RE
  378. .PP
  379. \fB\-n\fR, \fB\-\-no\-netrc\fR
  380. .RS 4
  381. Disables netrc support\&. netrc support is enabled by default\&.
  382. .RE
  383. .SS "BitTorrent/Metalink Options"
  384. .PP
  385. \fB\-\-select\-file\fR=INDEX\&...
  386. .RS 4
  387. Set file to download by specifying its index\&. You can find the file index using the
  388. \fB\-\-show\-files\fR
  389. option\&. Multiple indexes can be specified by using ",", for example:
  390. \fI3,6\fR\&. You can also use "\-" to specify a range:
  391. \fI1\-5\fR\&. "," and "\-" can be used together:
  392. \fI1\-5,8,9\fR\&. When used with the \-M option, index may vary depending on the query (see
  393. \fB\-\-metalink\-\fR* options)\&.
  394. .RE
  395. .sp
  396. .it 1 an-trap
  397. .nr an-no-space-flag 1
  398. .nr an-break-flag 1
  399. .br
  400. Note
  401. In multi file torrent, the adjacent files specified by this option may also be downloaded\&. This is by design, not a bug\&. A single piece may include several files or part of files, and aria2 writes the piece to the appropriate files\&.
  402. .PP
  403. \fB\-S\fR, \fB\-\-show\-files\fR
  404. .RS 4
  405. Print file listing of \&.torrent or \&.metalink file and exit\&. In case of \&.torrent file, additional information (infohash, piece length, etc) is also printed\&.
  406. .RE
  407. .SS "BitTorrent Specific Options"
  408. .PP
  409. \fB\-\-bt\-max\-open\-files\fR=NUM
  410. .RS 4
  411. Specify maximum number of files to open in each BitTorrent download\&. Default:
  412. \fI100\fR
  413. .RE
  414. .PP
  415. \fB\-\-bt\-min\-crypto\-level\fR=\fIplain\fR|\fIarc4\fR
  416. .RS 4
  417. Set minimum level of encryption method\&. If several encryption methods are provided by a peer, aria2 chooses the lowest one which satisfies the given level\&. Default:
  418. \fIplain\fR
  419. .RE
  420. .PP
  421. \fB\-\-bt\-require\-crypto\fR=\fItrue\fR|\fIfalse\fR
  422. .RS 4
  423. If true is given, aria2 doesn\'t accept and establish connection with legacy BitTorrent handshake(\e19BitTorrent protocol)\&. Thus aria2 always uses Obfuscation handshake\&. Default:
  424. \fIfalse\fR
  425. .RE
  426. .PP
  427. \fB\-\-bt\-request\-peer\-speed\-limit\fR=SPEED
  428. .RS 4
  429. If the whole download speed of every torrent is lower than SPEED, aria2 temporarily increases the number of peers to try for more download speed\&. Configuring this option with your preferred download speed can increase your download speed in some cases\&. You can append
  430. \fIK\fR
  431. or
  432. \fIM\fR(1K = 1024, 1M = 1024K)\&. Default:
  433. \fI50K\fR
  434. .RE
  435. .PP
  436. \fB\-\-bt\-seed\-unverified\fR[=\fItrue\fR|\fIfalse\fR]
  437. .RS 4
  438. Seed previously downloaded files without verifying piece hashes\&. Default:
  439. \fIfalse\fR
  440. .RE
  441. .PP
  442. \fB\-\-dht\-entry\-point\fR=HOST:PORT
  443. .RS 4
  444. Set host and port as an entry point to DHT network\&.
  445. .RE
  446. .PP
  447. \fB\-\-dht\-file\-path\fR=PATH
  448. .RS 4
  449. Change the DHT routing table file to PATH\&. Default:
  450. \fI$HOME/\&.aria2/dht\&.dat\fR
  451. .RE
  452. .PP
  453. \fB\-\-dht\-listen\-port\fR=PORT\&...
  454. .RS 4
  455. Set UDP listening port for DHT\&. Multiple ports can be specified by using ",", for example:
  456. \fI6881,6885\fR\&. You can also use "\-" to specify a range:
  457. \fI6881\-6999\fR\&. "," and "\-" can be used together\&. Default:
  458. \fI6881\-6999\fR
  459. .RE
  460. .sp
  461. .it 1 an-trap
  462. .nr an-no-space-flag 1
  463. .nr an-break-flag 1
  464. .br
  465. Note
  466. Make sure that the specified ports are open for incoming UDP traffic\&.
  467. .PP
  468. \fB\-\-direct\-file\-mapping\fR=\fItrue\fR|\fIfalse\fR
  469. .RS 4
  470. Directly read from and write to each file mentioned in \&.torrent file\&. Use this option if lots of files are listed in \&.torrent file and aria2 complains it cannot open files anymore\&. Default:
  471. \fItrue\fR
  472. .RE
  473. .PP
  474. \fB\-\-enable\-dht\fR[=\fItrue\fR|\fIfalse\fR]
  475. .RS 4
  476. Enable DHT functionality\&. If a private flag is set in a torrent, aria2 doesn\'t use DHT for that download even if
  477. \fItrue\fR
  478. is given\&. Default:
  479. \fIfalse\fR
  480. .RE
  481. .PP
  482. \fB\-\-enable\-peer\-exchange\fR[=\fItrue\fR|\fIfalse\fR]
  483. .RS 4
  484. Enable Peer Exchange extension\&. If a private flag is set in a torrent, this feature is disabled for that download even if
  485. \fItrue\fR
  486. is given\&. Default:
  487. \fItrue\fR
  488. .RE
  489. .PP
  490. \fB\-\-follow\-torrent\fR=\fItrue\fR|\fIfalse\fR|\fImem\fR
  491. .RS 4
  492. If
  493. \fItrue\fR
  494. or
  495. \fImem\fR
  496. is specified, when a file whose suffix is "\&.torrent" or content type is "application/x\-bittorrent" is downloaded, aria2 parses it as a torrent file and downloads files mentioned in it\&. If
  497. \fImem\fR
  498. is specified, a torrent file is not written to the disk, but is just kept in memory\&. If
  499. \fIfalse\fR
  500. is specified, the action mentioned above is not taken\&. Default:
  501. \fItrue\fR
  502. .RE
  503. .PP
  504. \fB\-\-listen\-port\fR=PORT\&...
  505. .RS 4
  506. Set TCP port number for BitTorrent downloads\&. Multiple ports can be specified by using ",", for example:
  507. \fI6881,6885\fR\&. You can also use "\-" to specify a range:
  508. \fI6881\-6999\fR\&. "," and "\-" can be used together:
  509. \fI6881\-6889,6999\fR\&. Default:
  510. \fI6881\-6999\fR
  511. .RE
  512. .sp
  513. .it 1 an-trap
  514. .nr an-no-space-flag 1
  515. .nr an-break-flag 1
  516. .br
  517. Note
  518. Make sure that the specified ports are open for incoming TCP traffic\&.
  519. .PP
  520. \fB\-\-max\-overall\-upload\-limit\fR=SPEED
  521. .RS 4
  522. Set max overall upload speed in bytes/sec\&.
  523. \fI0\fR
  524. means unrestricted\&. You can append
  525. \fIK\fR
  526. or
  527. \fIM\fR(1K = 1024, 1M = 1024K)\&. To limit the upload speed per torrent, use
  528. \fB\-\-max\-upload\-limit\fR
  529. option\&. If non\-zero value is specified,
  530. \fB\-\-max\-upload\-limit\fR
  531. option is ignored\&. Default:
  532. \fI0\fR
  533. .RE
  534. .PP
  535. \fB\-u\fR, \fB\-\-max\-upload\-limit\fR=SPEED
  536. .RS 4
  537. Set max upload speed per each torrent in bytes/sec\&.
  538. \fI0\fR
  539. means unrestricted\&. You can append
  540. \fIK\fR
  541. or
  542. \fIM\fR(1K = 1024, 1M = 1024K)\&. To limit the overall upload speed, use
  543. \fB\-\-max\-overall\-upload\-limit\fR
  544. option\&. Default:
  545. \fI0\fR
  546. .RE
  547. .PP
  548. \fB\-\-peer\-id\-prefix\fR=PEERI_ID_PREFIX
  549. .RS 4
  550. Specify the prefix of peer ID\&. The peer ID in BitTorrent is 20 byte length\&. If more than 20 bytes are specified, only first 20 bytes are used\&. If less than 20 bytes are specified, the random alphabet characters are added to make it\'s length 20 bytes\&. Default:
  551. \fI\-aria2\-\fR
  552. .RE
  553. .PP
  554. \fB\-\-seed\-ratio\fR=RATIO
  555. .RS 4
  556. Specify share ratio\&. Seed completed torrents until share ratio reaches RATIO\&. You are strongly encouraged to specify equals or more than
  557. \fI1\&.0\fR
  558. here\&. Specify
  559. \fI0\&.0\fR
  560. if you intend to do seeding regardless of share ratio\&. If
  561. \fB\-\-seed\-time\fR
  562. option is specified along with this option, seeding ends when at least one of the conditions is satisfied\&. Default:
  563. \fI1\&.0\fR
  564. .RE
  565. .PP
  566. \fB\-\-seed\-time\fR=MINUTES
  567. .RS 4
  568. Specify seeding time in minutes\&. Also see the
  569. \fB\-\-seed\-ratio\fR
  570. option\&.
  571. .RE
  572. .PP
  573. \fB\-T\fR, \fB\-\-torrent\-file\fR=TORRENT_FILE
  574. .RS 4
  575. The path to the \&.torrent file\&. You are not required to use this option because you can specify a torrent file without \-T\&.
  576. .RE
  577. .SS "Metalink Specific Options"
  578. .PP
  579. \fB\-\-follow\-metalink\fR=\fItrue\fR|\fIfalse\fR|\fImem\fR
  580. .RS 4
  581. If
  582. \fItrue\fR
  583. or
  584. \fImem\fR
  585. is specified, when a file whose suffix is "\&.metaink" or content type of "application/metalink+xml" is downloaded, aria2 parses it as a metalink file and downloads files mentioned in it\&. If
  586. \fImem\fR
  587. is specified, a metalink file is not written to the disk, but is just kept in memory\&. If
  588. \fIfalse\fR
  589. is specified, the action mentioned above is not taken\&. Default:
  590. \fItrue\fR
  591. .RE
  592. .PP
  593. \fB\-M\fR, \fB\-\-metalink\-file\fR=METALINK_FILE
  594. .RS 4
  595. The file path to \&.metalink file\&. You are not required to use this option because you can specify a metalink file without \-M\&.
  596. .RE
  597. .PP
  598. \fB\-C\fR, \fB\-\-metalink\-servers\fR=NUM_SERVERS
  599. .RS 4
  600. The number of servers to connect to simultaneously\&. Some Metalinks regulate the number of servers to connect\&. aria2 strictly respects them\&. This means that if Metalink defines the maxconnections attribute lower than NUM_SERVERS, then aria2 uses the value of maxconnections attribute instead of NUM_SERVERS\&. See also
  601. \fB\-s\fR
  602. and
  603. \fB\-j\fR
  604. options\&. Default:
  605. \fI5\fR
  606. .RE
  607. .PP
  608. \fB\-\-metalink\-language\fR=LANGUAGE
  609. .RS 4
  610. The language of the file to download\&.
  611. .RE
  612. .PP
  613. \fB\-\-metalink\-location\fR=LOCATION[,\&...]
  614. .RS 4
  615. The location of the preferred server\&. A comma\-delimited list of locations is acceptable, for example,
  616. \fIJP,US\fR\&.
  617. .RE
  618. .PP
  619. \fB\-\-metalink\-os\fR=OS
  620. .RS 4
  621. The operating system of the file to download\&.
  622. .RE
  623. .PP
  624. \fB\-\-metalink\-version\fR=VERSION
  625. .RS 4
  626. The version of the file to download\&.
  627. .RE
  628. .PP
  629. \fB\-\-metalink\-preferred\-protocol\fR=PROTO
  630. .RS 4
  631. Specify preferred protocol\&. The possible values are
  632. \fIhttp\fR,
  633. \fIhttps\fR,
  634. \fIftp\fR
  635. and
  636. \fInone\fR\&. Specify
  637. \fInone\fR
  638. to disable this feature\&. Default:
  639. \fInone\fR
  640. .RE
  641. .PP
  642. \fB\-\-metalink\-enable\-unique\-protocol\fR=\fItrue\fR|\fIfalse\fR
  643. .RS 4
  644. If
  645. \fItrue\fR
  646. is given and several protocols are available for a mirror in a metalink file, aria2 uses one of them\&. Use
  647. \fB\-\-metalink\-preferred\-protocol\fR
  648. option to specify the preference of protocol\&. Default:
  649. \fItrue\fR
  650. .RE
  651. .SS "Advanced Options"
  652. .PP
  653. \fB\-\-allow\-overwrite\fR=\fItrue\fR|\fIfalse\fR
  654. .RS 4
  655. If
  656. \fIfalse\fR
  657. is given, aria2 doesn\'t download a file which already exists but the corresponding \&.aria2 file doesn\'t exist\&. In HTTP(S)/FTP download, if
  658. \fB\-\-auto\-file\-renaming\fR=\fItrue\fR
  659. then, file name will be renamed\&. See
  660. \fB\-\-auto\-file\-renaming\fR
  661. for details\&. Default:
  662. \fIfalse\fR
  663. .RE
  664. .PP
  665. \fB\-\-allow\-piece\-length\-change\fR=\fItrue\fR|\fIfalse\fR
  666. .RS 4
  667. If false is given, aria2 aborts download when a piece length is different from one in a control file\&. If true is given, you can proceed but some download progress will be lost\&. Default:
  668. \fIfalse\fR
  669. .RE
  670. .PP
  671. \fB\-\-async\-dns\fR[=\fItrue\fR|\fIfalse\fR]
  672. .RS 4
  673. Enable asynchronous DNS\&. Default:
  674. \fItrue\fR
  675. .RE
  676. .PP
  677. \fB\-\-auto\-file\-renaming\fR[=\fItrue\fR|\fIfalse\fR]
  678. .RS 4
  679. Rename file name if the same file already exists\&. This option works only in HTTP(S)/FTP download\&. The new file name has a dot and a number(1\&.\&.9999) appended\&. Default:
  680. \fItrue\fR
  681. .RE
  682. .PP
  683. \fB\-\-auto\-save\-interval\fR=SEC
  684. .RS 4
  685. Save a control file(*\&.aria2) every SEC seconds\&. If
  686. \fI0\fR
  687. is given, a control file is not saved during download\&. aria2 saves a control file when it stops regardless of the value\&. The possible values are between
  688. \fI0\fR
  689. to
  690. \fI600\fR\&. Default:
  691. \fI60\fR
  692. .RE
  693. .PP
  694. \fB\-\-conf\-path\fR=PATH
  695. .RS 4
  696. Change the configuration file path to PATH\&. Default:
  697. \fI$HOME/\&.aria2/aria2\&.conf\fR
  698. .RE
  699. .PP
  700. \fB\-D\fR, \fB\-\-daemon\fR
  701. .RS 4
  702. Run as daemon\&.
  703. .RE
  704. .PP
  705. \fB\-\-enable\-direct\-io\fR[=\fItrue\fR|\fIfalse\fR]
  706. .RS 4
  707. Enable directI/O, which lowers cpu usage while allocating/checking files\&. Turn off if you encounter any error\&. Default:
  708. \fItrue\fR
  709. .RE
  710. .PP
  711. \fB\-\-file\-allocation\fR=METHOD
  712. .RS 4
  713. Specify file allocation method\&. METHOD is either
  714. \fInone\fR
  715. or
  716. \fIprealloc\fR\&.
  717. \fInone\fR
  718. doesn\'t pre\-allocate file space\&.
  719. \fIprealloc\fR
  720. pre\-allocates file space before download begins\&. This may take some time depending on the size of the file\&. Default:
  721. \fIprealloc\fR
  722. .RE
  723. .PP
  724. \fB\-\-log\-level\fR=LEVEL
  725. .RS 4
  726. Set log level to output\&. LEVEL is either
  727. \fIdebug\fR,
  728. \fIinfo\fR,
  729. \fInotice\fR,
  730. \fIwarn\fR
  731. or
  732. \fIerror\fR\&. Default:
  733. \fIdebug\fR
  734. .RE
  735. .PP
  736. \fB\-\-summary\-interval\fR=SEC
  737. .RS 4
  738. Set interval in seconds to output download progress summary\&. Setting
  739. \fI0\fR
  740. suppresses the output\&. Default:
  741. \fI60\fR
  742. .RE
  743. .sp
  744. .it 1 an-trap
  745. .nr an-no-space-flag 1
  746. .nr an-break-flag 1
  747. .br
  748. Note
  749. In multi file torrent downloads, the files adjacent forward to the specified files are also allocated if they share the same piece\&.
  750. .PP
  751. \fB\-Z\fR, \fB\-\-force\-sequential\fR[=\fItrue\fR|\fIfalse\fR]
  752. .RS 4
  753. Fetch URIs in the command\-line sequentially and download each URI in a separate session, like the usual command\-line download utilities\&. Default:
  754. \fIfalse\fR
  755. .RE
  756. .PP
  757. \fB\-\-max\-download\-limit\fR=SPEED
  758. .RS 4
  759. Set max download speed in bytes per sec\&.
  760. \fI0\fR
  761. means unrestricted\&. You can append
  762. \fIK\fR
  763. or
  764. \fIM\fR(1K = 1024, 1M = 1024K)\&. Default:
  765. \fI0\fR
  766. .RE
  767. .PP
  768. \fB\-\-no\-conf\fR
  769. .RS 4
  770. Disable loading aria2\&.conf file\&.
  771. .RE
  772. .PP
  773. \fB\-\-no\-file\-allocation\-limit\fR=SIZE
  774. .RS 4
  775. No file allocation is made for files whose size is smaller than SIZE\&. You can append
  776. \fIK\fR
  777. or
  778. \fIM\fR(1K = 1024, 1M = 1024K)\&. Default:
  779. \fI5M\fR
  780. .RE
  781. .PP
  782. \fB\-P\fR, \fB\-\-parameterized\-uri\fR[=\fItrue\fR|\fIfalse\fR]
  783. .RS 4
  784. Enable parameterized URI support\&. You can specify set of parts:
  785. \fIhttp://{sv1,sv2,sv3}/foo\&.iso\fR\&. Also you can specify numeric sequences with step counter:
  786. \fIhttp://host/image[000\-100:2]\&.img\fR\&. A step counter can be omitted\&. If all URIs do not point to the same file, such as the second example above, \-Z option is required\&. Default:
  787. \fIfalse\fR
  788. .RE
  789. .PP
  790. \fB\-q\fR, \fB\-\-quiet\fR[=\fItrue\fR|\fIfalse\fR]
  791. .RS 4
  792. Make aria2 quiet (no console output)\&. Default:
  793. \fIfalse\fR
  794. .RE
  795. .PP
  796. \fB\-\-realtime\-chunk\-checksum\fR=\fItrue\fR|\fIfalse\fR
  797. .RS 4
  798. Validate chunk of data by calculating checksum while downloading a file if chunk checksums are provided\&. Default:
  799. \fItrue\fR
  800. .RE
  801. .PP
  802. \fB\-\-stop\fR=SEC
  803. .RS 4
  804. Stop application after SEC seconds has passed\&. If
  805. \fI0\fR
  806. is given, this feature is disabled\&. Default:
  807. \fI0\fR
  808. .RE
  809. .PP
  810. \fB\-v\fR, \fB\-\-version\fR
  811. .RS 4
  812. Print the version number, copyright and the configuration information and exit\&.
  813. .RE
  814. .SS "OPTIONS THAT TAKE AN OPTIONAL ARGUMENT"
  815. The options that have its argument surrounded by square brackets([]) take an optional argument\&. Usually omiting the argument is evaluated to \fItrue\fR\&. If you use short form of these options(such as \fI\-V\fR) and give an argument, then the option name and its argument should be concatenated(e\&.g\&. \fI\-Vfalse\fR)\&. If any spaces are inserted between the option name and the argument, the argument will be treated as URI and usually this is not what you expect\&.
  816. .sp
  817. .SS "URL, TORRENT_FILE, METALINK_FILE"
  818. You can specify multiple URLs in command\-line\&. Unless you specify \fB\-Z\fR option, all URLs must point to the same file or downloading will fail\&.
  819. .sp
  820. You can also specify arbitrary number of torrent files and metalink files stored on a local drive\&. Please note that they are always treated as a separate download\&.
  821. .sp
  822. You can specify both torrent file with \-T option and URLs\&. By doing this, you can download a file from both torrent swarm and HTTP(S)/FTP server at the same time, while the data from HTTP(S)/FTP are uploaded to the torrent swarm\&. Note that only single file torrent can be integrated with HTTP(S)/FTP\&.
  823. .sp
  824. .sp
  825. .it 1 an-trap
  826. .nr an-no-space-flag 1
  827. .nr an-break-flag 1
  828. .br
  829. Note
  830. Make sure that URL is quoted with single(\') or double(") quotation if it contains "&" or any characters that have special meaning in shell\&.
  831. .sp
  832. .SH "EXAMPLES"
  833. .SS "HTTP/FTP Segmented Download"
  834. .sp
  835. .it 1 an-trap
  836. .nr an-no-space-flag 1
  837. .nr an-break-flag 1
  838. .br
  839. Download a file
  840. .RS
  841. .sp
  842. .RS 4
  843. .nf
  844. aria2c http://host/file\&.zip
  845. .fi
  846. .RE
  847. .sp
  848. .it 1 an-trap
  849. .nr an-no-space-flag 1
  850. .nr an-break-flag 1
  851. .br
  852. Note
  853. aria2 uses 5 connections to download 1 file by default\&.
  854. .sp
  855. .RE
  856. .sp
  857. .it 1 an-trap
  858. .nr an-no-space-flag 1
  859. .nr an-break-flag 1
  860. .br
  861. Download a file using 1 connection
  862. .RS
  863. .sp
  864. .RS 4
  865. .nf
  866. aria2c \-s1 http://host/file\&.zip
  867. .fi
  868. .RE
  869. .sp
  870. .it 1 an-trap
  871. .nr an-no-space-flag 1
  872. .nr an-break-flag 1
  873. .br
  874. Note
  875. aria2 uses 5 connections to download 1 file by default\&. \-s1 limits the number of connections to just 1\&.
  876. .sp
  877. .sp
  878. .it 1 an-trap
  879. .nr an-no-space-flag 1
  880. .nr an-break-flag 1
  881. .br
  882. Note
  883. To pause a download, press Ctrl\-C\&. You can resume the transfer by running aria2c with the same argument in the same directory\&. You can change URLs as long as they are pointing to the same file\&.
  884. .sp
  885. .RE
  886. .sp
  887. .it 1 an-trap
  888. .nr an-no-space-flag 1
  889. .nr an-break-flag 1
  890. .br
  891. Download a file from 2 different HTTP servers
  892. .RS
  893. .sp
  894. .RS 4
  895. .nf
  896. aria2c http://host/file\&.zip http://mirror/file\&.zip
  897. .fi
  898. .RE
  899. .RE
  900. .sp
  901. .it 1 an-trap
  902. .nr an-no-space-flag 1
  903. .nr an-break-flag 1
  904. .br
  905. Download a file from HTTP and FTP servers
  906. .RS
  907. .sp
  908. .RS 4
  909. .nf
  910. aria2c http://host1/file\&.zip ftp://host2/file\&.zip
  911. .fi
  912. .RE
  913. .RE
  914. .sp
  915. .it 1 an-trap
  916. .nr an-no-space-flag 1
  917. .nr an-break-flag 1
  918. .br
  919. Download files listed in a text file concurrently
  920. .RS
  921. .sp
  922. .RS 4
  923. .nf
  924. aria2c \-ifiles\&.txt \-j2
  925. .fi
  926. .RE
  927. .sp
  928. .it 1 an-trap
  929. .nr an-no-space-flag 1
  930. .nr an-break-flag 1
  931. .br
  932. Note
  933. \-j option specifies the number of parallel downloads\&.
  934. .sp
  935. .RE
  936. .sp
  937. .it 1 an-trap
  938. .nr an-no-space-flag 1
  939. .nr an-break-flag 1
  940. .br
  941. Using proxy
  942. .RS
  943. For HTTP:
  944. .sp
  945. .sp
  946. .RS 4
  947. .nf
  948. aria2c \-\-http\-proxy=http://proxy:8080 http://host/file
  949. .fi
  950. .RE
  951. For FTP:
  952. .sp
  953. .sp
  954. .RS 4
  955. .nf
  956. aria2c \-\-ftp\-proxy=http://proxy:8080 ftp://host/file
  957. .fi
  958. .RE
  959. .sp
  960. .it 1 an-trap
  961. .nr an-no-space-flag 1
  962. .nr an-break-flag 1
  963. .br
  964. Note
  965. See \fB\-\-http\-proxy\fR, \fB\-\-https\-proxy\fR, \fB\-\-ftp\-proxy\fR and \fB\-\-all\-proxy\fR for details\&. You can specify proxy in the environment variables\&. See ENVIRONMENT section\&.
  966. .sp
  967. .RE
  968. .sp
  969. .it 1 an-trap
  970. .nr an-no-space-flag 1
  971. .nr an-break-flag 1
  972. .br
  973. Proxy with authorization
  974. .RS
  975. .sp
  976. .RS 4
  977. .nf
  978. aria2c \-\-http\-proxy=http://username:password@proxy:8080 http://host/file
  979. .fi
  980. .RE
  981. .RE
  982. .SS "Metalink Download"
  983. .sp
  984. .it 1 an-trap
  985. .nr an-no-space-flag 1
  986. .nr an-break-flag 1
  987. .br
  988. Download files with remote Metalink
  989. .RS
  990. .sp
  991. .RS 4
  992. .nf
  993. aria2c \-\-follow\-metalink=mem http://host/file\&.metalink
  994. .fi
  995. .RE
  996. .RE
  997. .sp
  998. .it 1 an-trap
  999. .nr an-no-space-flag 1
  1000. .nr an-break-flag 1
  1001. .br
  1002. Download using a local metalink file
  1003. .RS
  1004. .sp
  1005. .RS 4
  1006. .nf
  1007. aria2c \-p \-\-lowest\-speed\-limit=4000 file\&.metalink
  1008. .fi
  1009. .RE
  1010. .sp
  1011. .it 1 an-trap
  1012. .nr an-no-space-flag 1
  1013. .nr an-break-flag 1
  1014. .br
  1015. Note
  1016. To pause a download, press Ctrl\-C\&. You can resume the transfer by running aria2c with the same argument in the same directory\&.
  1017. .sp
  1018. .RE
  1019. .sp
  1020. .it 1 an-trap
  1021. .nr an-no-space-flag 1
  1022. .nr an-break-flag 1
  1023. .br
  1024. Download several local metalink files
  1025. .RS
  1026. .sp
  1027. .RS 4
  1028. .nf
  1029. aria2c \-j2 file1\&.metalink file2\&.metalink
  1030. .fi
  1031. .RE
  1032. .RE
  1033. .sp
  1034. .it 1 an-trap
  1035. .nr an-no-space-flag 1
  1036. .nr an-break-flag 1
  1037. .br
  1038. Download only selected files using index
  1039. .RS
  1040. .sp
  1041. .RS 4
  1042. .nf
  1043. aria2c \-\-select\-file=1\-4,8 file\&.metalink
  1044. .fi
  1045. .RE
  1046. .sp
  1047. .it 1 an-trap
  1048. .nr an-no-space-flag 1
  1049. .nr an-break-flag 1
  1050. .br
  1051. Note
  1052. The index is printed to the console using \-S option\&.
  1053. .sp
  1054. .RE
  1055. .sp
  1056. .it 1 an-trap
  1057. .nr an-no-space-flag 1
  1058. .nr an-break-flag 1
  1059. .br
  1060. Download a file using a local .metalink file with user preference
  1061. .RS
  1062. .sp
  1063. .RS 4
  1064. .nf
  1065. aria2c \-\-metalink\-location=JP,US \-\-metalink\-version=1\&.1 \-\-metalink\-language=en\-US file\&.metalink
  1066. .fi
  1067. .RE
  1068. .RE
  1069. .SS "BitTorrent Download"
  1070. .sp
  1071. .it 1 an-trap
  1072. .nr an-no-space-flag 1
  1073. .nr an-break-flag 1
  1074. .br
  1075. Download files from remote BitTorrent file
  1076. .RS
  1077. .sp
  1078. .RS 4
  1079. .nf
  1080. aria2c \-\-follow\-torrent=mem http://host/file\&.torrent
  1081. .fi
  1082. .RE
  1083. .RE
  1084. .sp
  1085. .it 1 an-trap
  1086. .nr an-no-space-flag 1
  1087. .nr an-break-flag 1
  1088. .br
  1089. Download using a local torrent file
  1090. .RS
  1091. .sp
  1092. .RS 4
  1093. .nf
  1094. aria2c \-\-max\-upload\-limit=40K file\&.torrent
  1095. .fi
  1096. .RE
  1097. .sp
  1098. .it 1 an-trap
  1099. .nr an-no-space-flag 1
  1100. .nr an-break-flag 1
  1101. .br
  1102. Note
  1103. \-\-max\-upload\-limit specifies the max of upload rate\&.
  1104. .sp
  1105. .sp
  1106. .it 1 an-trap
  1107. .nr an-no-space-flag 1
  1108. .nr an-break-flag 1
  1109. .br
  1110. Note
  1111. To pause a download, press Ctrl\-C\&. You can resume the transfer by run aria2c with the same argument in the same directory\&.
  1112. .sp
  1113. .RE
  1114. .sp
  1115. .it 1 an-trap
  1116. .nr an-no-space-flag 1
  1117. .nr an-break-flag 1
  1118. .br
  1119. Download 2 torrents
  1120. .RS
  1121. .sp
  1122. .RS 4
  1123. .nf
  1124. aria2c \-j2 file1\&.torrent file2\&.torrent
  1125. .fi
  1126. .RE
  1127. .RE
  1128. .sp
  1129. .it 1 an-trap
  1130. .nr an-no-space-flag 1
  1131. .nr an-break-flag 1
  1132. .br
  1133. Download a file using torrent and HTTP/FTP server
  1134. .RS
  1135. .sp
  1136. .RS 4
  1137. .nf
  1138. aria2c \-Ttest\&.torrent http://host1/file ftp://host2/file
  1139. .fi
  1140. .RE
  1141. .sp
  1142. .it 1 an-trap
  1143. .nr an-no-space-flag 1
  1144. .nr an-break-flag 1
  1145. .br
  1146. Note
  1147. Downloading multi file torrent with HTTP/FTP is not supported\&.
  1148. .sp
  1149. .RE
  1150. .sp
  1151. .it 1 an-trap
  1152. .nr an-no-space-flag 1
  1153. .nr an-break-flag 1
  1154. .br
  1155. Download only selected files using index(usually called "selectable download")
  1156. .RS
  1157. .sp
  1158. .RS 4
  1159. .nf
  1160. aria2c \-\-select\-file=1\-4,8 file\&.torrent
  1161. .fi
  1162. .RE
  1163. .sp
  1164. .it 1 an-trap
  1165. .nr an-no-space-flag 1
  1166. .nr an-break-flag 1
  1167. .br
  1168. Note
  1169. The index is printed to the console using \-S option\&.
  1170. .sp
  1171. .RE
  1172. .sp
  1173. .it 1 an-trap
  1174. .nr an-no-space-flag 1
  1175. .nr an-break-flag 1
  1176. .br
  1177. Change the listening port for incoming peer
  1178. .RS
  1179. .sp
  1180. .RS 4
  1181. .nf
  1182. aria2c \-\-listen\-port=7000\-7001,8000 file\&.torrent
  1183. .fi
  1184. .RE
  1185. .sp
  1186. .it 1 an-trap
  1187. .nr an-no-space-flag 1
  1188. .nr an-break-flag 1
  1189. .br
  1190. Note
  1191. Since aria2 doesn\'t configure firewall or router for port forwarding, it\'s up to you to do it manually\&.
  1192. .sp
  1193. .RE
  1194. .sp
  1195. .it 1 an-trap
  1196. .nr an-no-space-flag 1
  1197. .nr an-break-flag 1
  1198. .br
  1199. Specify the condition to stop program after torrent download finished
  1200. .RS
  1201. .sp
  1202. .RS 4
  1203. .nf
  1204. aria2c \-\-seed\-time=120 \-\-seed\-ratio=1\&.0 file\&.torrent
  1205. .fi
  1206. .RE
  1207. .sp
  1208. .it 1 an-trap
  1209. .nr an-no-space-flag 1
  1210. .nr an-break-flag 1
  1211. .br
  1212. Note
  1213. In the above example, the program exits when the 120 minutes has elapsed since download completed or seed ratio reaches 1\&.0\&.
  1214. .sp
  1215. .RE
  1216. .sp
  1217. .it 1 an-trap
  1218. .nr an-no-space-flag 1
  1219. .nr an-break-flag 1
  1220. .br
  1221. Throttle upload speed
  1222. .RS
  1223. .sp
  1224. .RS 4
  1225. .nf
  1226. aria2c \-\-max\-upload\-limit=100K file\&.torrent
  1227. .fi
  1228. .RE
  1229. .RE
  1230. .sp
  1231. .it 1 an-trap
  1232. .nr an-no-space-flag 1
  1233. .nr an-break-flag 1
  1234. .br
  1235. Enable DHT
  1236. .RS
  1237. .sp
  1238. .RS 4
  1239. .nf
  1240. aria2c \-\-enable\-dht \-\-dht\-listen\-port=6881 file\&.torrent
  1241. .fi
  1242. .RE
  1243. .sp
  1244. .it 1 an-trap
  1245. .nr an-no-space-flag 1
  1246. .nr an-break-flag 1
  1247. .br
  1248. Note
  1249. DHT uses udp port\&. Since aria2 doesn\'t configure firewall or router for port forwarding, it\'s up to you to do it manually\&.
  1250. .sp
  1251. .RE
  1252. .SS "More advanced HTTP features"
  1253. .sp
  1254. .it 1 an-trap
  1255. .nr an-no-space-flag 1
  1256. .nr an-break-flag 1
  1257. .br
  1258. Load cookies
  1259. .RS
  1260. .sp
  1261. .RS 4
  1262. .nf
  1263. aria2c \-\-load\-cookies=cookies\&.txt http://host/file\&.zip
  1264. .fi
  1265. .RE
  1266. .sp
  1267. .it 1 an-trap
  1268. .nr an-no-space-flag 1
  1269. .nr an-break-flag 1
  1270. .br
  1271. Note
  1272. You can use Firefox/Mozilla\'s cookie file without modification\&.
  1273. .sp
  1274. .RE
  1275. .sp
  1276. .it 1 an-trap
  1277. .nr an-no-space-flag 1
  1278. .nr an-break-flag 1
  1279. .br
  1280. Resume download started by web browsers or another programs
  1281. .RS
  1282. .sp
  1283. .RS 4
  1284. .nf
  1285. aria2c \-c \-s2 http://host/partiallydownloadedfile\&.zip
  1286. .fi
  1287. .RE
  1288. .RE
  1289. .sp
  1290. .it 1 an-trap
  1291. .nr an-no-space-flag 1
  1292. .nr an-break-flag 1
  1293. .br
  1294. Client certificate authorization for SSL/TLS
  1295. .RS
  1296. .sp
  1297. .RS 4
  1298. .nf
  1299. aria2c \-\-certificate=/path/to/mycert\&.pem \-\-private\-key=/path/to/mykey\&.pem https://host/file
  1300. .fi
  1301. .RE
  1302. .sp
  1303. .it 1 an-trap
  1304. .nr an-no-space-flag 1
  1305. .nr an-break-flag 1
  1306. .br
  1307. Note
  1308. The file specified in \fB\-\-private\-key\fR must be decrypted\&. The behavior when encrypted one is given is undefined\&.
  1309. .sp
  1310. .RE
  1311. .sp
  1312. .it 1 an-trap
  1313. .nr an-no-space-flag 1
  1314. .nr an-break-flag 1
  1315. .br
  1316. Verify peer in SSL/TLS using given CA certificates
  1317. .RS
  1318. .sp
  1319. .RS 4
  1320. .nf
  1321. aria2c \-\-ca\-certificate=/path/to/ca\-certificates\&.crt \-\-check\-certificate https://host/file
  1322. .fi
  1323. .RE
  1324. .RE
  1325. .SS "And more advanced features"
  1326. .sp
  1327. .it 1 an-trap
  1328. .nr an-no-space-flag 1
  1329. .nr an-break-flag 1
  1330. .br
  1331. Throttle download speed
  1332. .RS
  1333. .sp
  1334. .RS 4
  1335. .nf
  1336. aria2c \-\-max\-download\-limit=100K file\&.metalink
  1337. .fi
  1338. .RE
  1339. .RE
  1340. .sp
  1341. .it 1 an-trap
  1342. .nr an-no-space-flag 1
  1343. .nr an-break-flag 1
  1344. .br
  1345. Repair a damaged download using -V option
  1346. .RS
  1347. .sp
  1348. .RS 4
  1349. .nf
  1350. aria2c \-V file\&.metalink
  1351. .fi
  1352. .RE
  1353. .sp
  1354. .it 1 an-trap
  1355. .nr an-no-space-flag 1
  1356. .nr an-break-flag 1
  1357. .br
  1358. Note
  1359. This option is only available used with BitTorrent or metalink with chunk checksums\&.
  1360. .sp
  1361. .RE
  1362. .sp
  1363. .it 1 an-trap
  1364. .nr an-no-space-flag 1
  1365. .nr an-break-flag 1
  1366. .br
  1367. Drop connection if download speed is lower than specified value
  1368. .RS
  1369. .sp
  1370. .RS 4
  1371. .nf
  1372. aria2c \-\-lowest\-speed\-limit=10K file\&.metalink
  1373. .fi
  1374. .RE
  1375. .RE
  1376. .sp
  1377. .it 1 an-trap
  1378. .nr an-no-space-flag 1
  1379. .nr an-break-flag 1
  1380. .br
  1381. Parameterized URI support
  1382. .RS
  1383. You can specify set of parts:
  1384. .sp
  1385. .sp
  1386. .RS 4
  1387. .nf
  1388. aria2c \-P http://{host1,host2,host3}/file\&.iso
  1389. .fi
  1390. .RE
  1391. You can specify numeric sequence:
  1392. .sp
  1393. .sp
  1394. .RS 4
  1395. .nf
  1396. aria2c \-Z \-P http://host/image[000\-100]\&.png
  1397. .fi
  1398. .RE
  1399. .sp
  1400. .it 1 an-trap
  1401. .nr an-no-space-flag 1
  1402. .nr an-break-flag 1
  1403. .br
  1404. Note
  1405. \-Z option is required if the all URIs don\'t point to the same file, such as the above example\&.
  1406. .sp
  1407. You can specify step counter:
  1408. .sp
  1409. .sp
  1410. .RS 4
  1411. .nf
  1412. aria2c \-Z \-P http://host/image[A\-Z:2]\&.png
  1413. .fi
  1414. .RE
  1415. .RE
  1416. .sp
  1417. .it 1 an-trap
  1418. .nr an-no-space-flag 1
  1419. .nr an-break-flag 1
  1420. .br
  1421. Parallel downloads of arbitrary number of URL,metalink,torrent
  1422. .RS
  1423. .sp
  1424. .RS 4
  1425. .nf
  1426. aria2c \-j3 \-Z http://host/file1 file2\&.torrent file3\&.metalink
  1427. .fi
  1428. .RE
  1429. .RE
  1430. .sp
  1431. .it 1 an-trap
  1432. .nr an-no-space-flag 1
  1433. .nr an-break-flag 1
  1434. .br
  1435. BitTorrent Encryption
  1436. .RS
  1437. Encrypt whole payload using ARC4:
  1438. .sp
  1439. .sp
  1440. .RS 4
  1441. .nf
  1442. aria2c \-\-bt\-min\-crypto\-level=arc4 \-\-bt\-require\-crypto=true file\&.torrent
  1443. .fi
  1444. .RE
  1445. .RE
  1446. .SH "RESUME DOWNLOAD"
  1447. Usually, you can resume transfer by just issuing same command(aria2c URL) if the previous transfer is made by aria2\&.
  1448. .sp
  1449. If the previous transfer is made by a browser or wget like sequential download manager, then use \-c option to continue the transfer(aria2c \-c URL)\&.
  1450. .sp
  1451. .SH "CONTROL FILE"
  1452. aria2 uses a control file to track the progress of a download\&. A control file is placed in the same directory as the downloading file and its filename is the filename of downloading file with "\&.aria2" appended\&. For example, if you are downloading file\&.zip, then the control file should be file\&.zip\&.aria2\&. (There is a exception for this naming convention\&. If you are downloading a multi torrent, its control file is the "top directory" name of the torrent with "\&.aria2" appended\&. The "top directory" name is a value of "name" key in "info" directory in a torrent file\&.)
  1453. .sp
  1454. Usually a control file is deleted once download completed\&. If aria2 decides that download cannot be resumed(for example, when downloading a file from a HTTP server which doesn\'t support resume), a control file is not created\&.
  1455. .sp
  1456. Normally if you lose a control file, you cannot resume download\&. But if you have a torrent or metalink with chunk checksums for the file, you can resume the download without a control file by giving \-V option to aria2c in command\-line\&.
  1457. .sp
  1458. .SH "SEEDING DOWNLOADED FILE IN BITTORRENT"
  1459. You can seed downloaded file using \-V option\&.
  1460. .sp
  1461. .sp
  1462. .RS 4
  1463. .nf
  1464. aria2c \-V file\&.torrent
  1465. .fi
  1466. .RE
  1467. .SH "INPUT FILE"
  1468. The input file can contain a list of URIs for aria2 to download\&. You can specify multiple URIs for a single entity: separate URIs on a single line using the TAB character\&.
  1469. .sp
  1470. Each line is treated as if it is provided in command\-line argument\&. Therefore they are affected by \fB\-Z\fR and \fB\-P\fR options\&. The additional \fBout\fR and \fBdir\fR options can be specified after each line of URIs\&. This optional line must start with white space(s)\&.
  1471. .sp
  1472. For example, the content of uri\&.txt is
  1473. .sp
  1474. .sp
  1475. .RS 4
  1476. .nf
  1477. http://server/file\&.iso http://mirror/file\&.iso
  1478. dir=/iso_images
  1479. out=file\&.img
  1480. http://foo/bar
  1481. .fi
  1482. .RE
  1483. If aria2 is executed with \fB\-i\fR uri\&.txt \fB\-d\fR /tmp options, then \fIfile\&.iso\fR is saved as \fI/iso_images/file\&.img\fR and it is downloaded from http://server/file\&.iso and http://mirror/file\&.iso\&. The file \fIbar\fR is downloaded from http://foo/bar and saved as \fI/tmp/bar\fR\&.
  1484. .sp
  1485. In some cases, \fBout\fR parameter has no effect\&. See note of \fB\-\-out\fR option for the restrictions\&.
  1486. .sp
  1487. .SH "SERVER PERFORMANCE PROFILE"
  1488. This section describes the format of server performance profile\&. The file is plain text and each line has several NAME=VALUE pair, delimited by comma\&. Currently following NAMEs are recognized:
  1489. .PP
  1490. host
  1491. .RS 4
  1492. Hostname of the server\&. Required\&.
  1493. .RE
  1494. .PP
  1495. protocol
  1496. .RS 4
  1497. Protocol for this profile, such as ftp, http\&. Required\&.
  1498. .RE
  1499. .PP
  1500. dl_speed
  1501. .RS 4
  1502. The average download speed observed in the previous download in bytes per sec\&. Required\&.
  1503. .RE
  1504. .PP
  1505. last_updated
  1506. .RS 4
  1507. Last contact time in GMT with this server, specified in the seconds from the Epoch\&. Required\&.
  1508. .RE
  1509. .PP
  1510. status
  1511. .RS 4
  1512. ERROR is set when server cannot be reached or out\-of\-service or timeout occurred\&. Otherwise, OK is set\&.
  1513. .RE
  1514. Those fields must exist in one line\&. The order of the fields is not significant\&. You can put pairs other than the above; they are simply ignored\&.
  1515. .sp
  1516. An example follows:
  1517. .sp
  1518. .sp
  1519. .RS 4
  1520. .nf
  1521. host=localhost, protocol=http, dl_speed=32000, last_updated=1222491640, status=OK
  1522. host=localhost, protocol=ftp, dl_speed=0, last_updated=1222491632, status=ERROR
  1523. .fi
  1524. .RE
  1525. .SH "FILES"
  1526. .SS "aria2\&.conf"
  1527. User configuration file\&. It must be placed under $HOME/\&.aria2 and must be named aria2\&.conf\&. In each line, there is 1 parameter whose syntax is name=value pair, where name is the long command\-line option name without \fI\-\-\fR prefix\&. The lines beginning \fI#\fR are treated as comments\&.
  1528. .sp
  1529. .sp
  1530. .RS 4
  1531. .nf
  1532. # sample configuration file for aria2c
  1533. listen\-port=60000
  1534. dht\-listen\-port=60000
  1535. seed\-ratio=1\&.0
  1536. max\-upload\-limit=50K
  1537. ftp\-pasv=true
  1538. .fi
  1539. .RE
  1540. .SS "dht\&.dat"
  1541. By default, the routing table of DHT is saved to the path $HOME/\&.aria2/dht\&.dat\&.
  1542. .sp
  1543. .SH "ENVIRONMENT"
  1544. aria2 recognizes the following environment variables\&.
  1545. .PP
  1546. http_proxy [http://][USER:PASSWORD@]HOST[:PORT]
  1547. .RS 4
  1548. Specify proxy server for use in HTTP\&. Overrides http\-proxy value in configuration file\&. The command\-line option
  1549. \fB\-\-http\-proxy\fR
  1550. overrides this value\&.
  1551. .RE
  1552. .PP
  1553. https_proxy [http://][USER:PASSWORD@]HOST[:PORT]
  1554. .RS 4
  1555. Specify proxy server for use in HTTPS\&. Overrides https\-proxy value in configuration file\&. The command\-line option
  1556. \fB\-\-https\-proxy\fR
  1557. overrides this value\&.
  1558. .RE
  1559. .PP
  1560. ftp_proxy [http://][USER:PASSWORD@]HOST[:PORT]
  1561. .RS 4
  1562. Specify proxy server for use in FTP\&. Overrides ftp\-proxy value in configuration file\&. The command\-line option
  1563. \fB\-\-ftp\-proxy\fR
  1564. overrides this value\&.
  1565. .RE
  1566. .PP
  1567. all_proxy [http://][USER:PASSWORD@]HOST[:PORT]
  1568. .RS 4
  1569. Specify proxy server for use if no protocol\-specific proxy is specified\&. Overrides all\-proxy value in configuration file\&. The command\-line option
  1570. \fB\-\-all\-proxy\fR
  1571. overrides this value\&.
  1572. .RE
  1573. .PP
  1574. no_proxy [DOMAIN,\&...]
  1575. .RS 4
  1576. Specify comma\-separated hostname or domains to which proxy should not be used\&. Overrides no\-proxy value in configuration file\&. The command\-line option
  1577. \fB\-\-no\-proxy\fR
  1578. overrides this value\&.
  1579. .RE
  1580. .SH "EXIT CODES"
  1581. Because aria2 can handle multiple downloads at once, it encounters lots of errors in a session\&. aria2 returns the following exit codes based on the last error encountered\&.
  1582. .PP
  1583. 0
  1584. .RS 4
  1585. If all downloads are successful\&.
  1586. .RE
  1587. .PP
  1588. 1
  1589. .RS 4
  1590. If an unknown error occurs\&.
  1591. .RE
  1592. .PP
  1593. 2
  1594. .RS 4
  1595. If time out occurs\&.
  1596. .RE
  1597. .PP
  1598. 3
  1599. .RS 4
  1600. If a resource is not found\&.
  1601. .RE
  1602. .PP
  1603. 4
  1604. .RS 4
  1605. If aria2 sees the specfied number of "resource not found" error\&. See
  1606. \fB\-\-max\-file\-not\-found\fR
  1607. option)\&.
  1608. .RE
  1609. .PP
  1610. 5
  1611. .RS 4
  1612. If a download aborts because download speed is too slow\&. See
  1613. \fB\-\-lowest\-speed\-limit\fR
  1614. option)
  1615. .RE
  1616. .PP
  1617. 6
  1618. .RS 4
  1619. If network problem occurs\&.
  1620. .RE
  1621. .PP
  1622. 7
  1623. .RS 4
  1624. If there are unfinished downloads\&. This error is only reported if all finished downloads are successful and there are unfinished downloads in a queue when aria2 exits by pressing Ctrl\-C by an user or sending TERM or INT signal\&.
  1625. .RE
  1626. .sp
  1627. .it 1 an-trap
  1628. .nr an-no-space-flag 1
  1629. .nr an-break-flag 1
  1630. .br
  1631. Note
  1632. An error occurred in a finished download will not be reported as exit status\&.
  1633. .sp
  1634. .SH "RESOURCES"
  1635. Project web site: http://aria2\&.sourceforge\&.net/
  1636. .sp
  1637. metalink: http://www\&.metalinker\&.org/
  1638. .sp
  1639. .SH "REPORTING BUGS"
  1640. Report bugs to Tatsuhiro Tsujikawa <t\-tujikawa at users\&.sourceforge\&.net>
  1641. .sp
  1642. .SH "AUTHOR"
  1643. Tatsuhiro Tsujikawa <t\-tujikawa at users\&.sourceforge\&.net>
  1644. .sp
  1645. .SH "COPYRIGHT"
  1646. Copyright \(co 2006, 2008 Tatsuhiro Tsujikawa
  1647. .sp
  1648. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version\&.
  1649. .sp
  1650. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE\&. See the GNU General Public License for more details\&.
  1651. .sp
  1652. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc\&., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA
  1653. .sp
  1654. In addition, as a special exception, the copyright holders give permission to link the code of portions of this program with the OpenSSL library under certain conditions as described in each individual source file, and distribute linked combinations including the two\&. You must obey the GNU General Public License in all respects for all of the code used other than OpenSSL\&. If you modify file(s) with this exception, you may extend this exception to your version of the file(s), but you are not obligated to do so\&. If you do not wish to do so, delete this exception statement from your version\&. If you delete this exception statement from all source files in the program, then also delete it here\&.
  1655. .sp