aria2c.1.html 97 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
  2. "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  6. <meta name="generator" content="AsciiDoc 8.5.1" />
  7. <title>ARIA2C(1)</title>
  8. <style type="text/css">
  9. /* Debug borders */
  10. p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 {
  11. /*
  12. border: 1px solid red;
  13. */
  14. }
  15. body {
  16. margin: 1em 5% 1em 5%;
  17. }
  18. a {
  19. color: blue;
  20. text-decoration: underline;
  21. }
  22. a:visited {
  23. color: fuchsia;
  24. }
  25. em {
  26. font-style: italic;
  27. color: navy;
  28. }
  29. strong {
  30. font-weight: bold;
  31. color: #083194;
  32. }
  33. tt {
  34. color: navy;
  35. }
  36. h1, h2, h3, h4, h5, h6 {
  37. color: #527bbd;
  38. font-family: sans-serif;
  39. margin-top: 1.2em;
  40. margin-bottom: 0.5em;
  41. line-height: 1.3;
  42. }
  43. h1, h2, h3 {
  44. border-bottom: 2px solid silver;
  45. }
  46. h2 {
  47. padding-top: 0.5em;
  48. }
  49. h3 {
  50. float: left;
  51. }
  52. h3 + * {
  53. clear: left;
  54. }
  55. div.sectionbody {
  56. font-family: serif;
  57. margin-left: 0;
  58. }
  59. hr {
  60. border: 1px solid silver;
  61. }
  62. p {
  63. margin-top: 0.5em;
  64. margin-bottom: 0.5em;
  65. }
  66. ul, ol, li > p {
  67. margin-top: 0;
  68. }
  69. pre {
  70. padding: 0;
  71. margin: 0;
  72. }
  73. span#author {
  74. color: #527bbd;
  75. font-family: sans-serif;
  76. font-weight: bold;
  77. font-size: 1.1em;
  78. }
  79. span#email {
  80. }
  81. span#revnumber, span#revdate, span#revremark {
  82. font-family: sans-serif;
  83. }
  84. div#footer {
  85. font-family: sans-serif;
  86. font-size: small;
  87. border-top: 2px solid silver;
  88. padding-top: 0.5em;
  89. margin-top: 4.0em;
  90. }
  91. div#footer-text {
  92. float: left;
  93. padding-bottom: 0.5em;
  94. }
  95. div#footer-badges {
  96. float: right;
  97. padding-bottom: 0.5em;
  98. }
  99. div#preamble {
  100. margin-top: 1.5em;
  101. margin-bottom: 1.5em;
  102. }
  103. div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
  104. div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
  105. div.admonitionblock {
  106. margin-top: 0.25em;
  107. margin-bottom: 1.5em;
  108. }
  109. div.admonitionblock {
  110. margin-top: 2.5em;
  111. margin-bottom: 2.5em;
  112. }
  113. div.content { /* Block element content. */
  114. padding: 0;
  115. }
  116. /* Block element titles. */
  117. div.title, caption.title {
  118. color: #527bbd;
  119. font-family: sans-serif;
  120. font-weight: bold;
  121. text-align: left;
  122. margin-top: 1.0em;
  123. margin-bottom: 0.5em;
  124. }
  125. div.title + * {
  126. margin-top: 0;
  127. }
  128. td div.title:first-child {
  129. margin-top: 0.0em;
  130. }
  131. div.content div.title:first-child {
  132. margin-top: 0.0em;
  133. }
  134. div.content + div.title {
  135. margin-top: 0.0em;
  136. }
  137. div.sidebarblock > div.content {
  138. background: #ffffee;
  139. border: 1px solid silver;
  140. padding: 0.5em;
  141. }
  142. div.listingblock > div.content {
  143. border: 1px solid silver;
  144. background: #f4f4f4;
  145. padding: 0.5em;
  146. }
  147. div.quoteblock {
  148. padding-left: 2.0em;
  149. margin-right: 10%;
  150. }
  151. div.quoteblock > div.attribution {
  152. padding-top: 0.5em;
  153. text-align: right;
  154. }
  155. div.verseblock {
  156. padding-left: 2.0em;
  157. margin-right: 10%;
  158. }
  159. div.verseblock > div.content {
  160. white-space: pre;
  161. }
  162. div.verseblock > div.attribution {
  163. padding-top: 0.75em;
  164. text-align: left;
  165. }
  166. /* DEPRECATED: Pre version 8.2.7 verse style literal block. */
  167. div.verseblock + div.attribution {
  168. text-align: left;
  169. }
  170. div.admonitionblock .icon {
  171. vertical-align: top;
  172. font-size: 1.1em;
  173. font-weight: bold;
  174. text-decoration: underline;
  175. color: #527bbd;
  176. padding-right: 0.5em;
  177. }
  178. div.admonitionblock td.content {
  179. padding-left: 0.5em;
  180. border-left: 2px solid silver;
  181. }
  182. div.exampleblock > div.content {
  183. border-left: 2px solid silver;
  184. padding: 0.5em;
  185. }
  186. div.imageblock div.content { padding-left: 0; }
  187. span.image img { border-style: none; }
  188. a.image:visited { color: white; }
  189. dl {
  190. margin-top: 0.8em;
  191. margin-bottom: 0.8em;
  192. }
  193. dt {
  194. margin-top: 0.5em;
  195. margin-bottom: 0;
  196. font-style: normal;
  197. color: navy;
  198. }
  199. dd > *:first-child {
  200. margin-top: 0.1em;
  201. }
  202. ul, ol {
  203. list-style-position: outside;
  204. }
  205. ol.arabic {
  206. list-style-type: decimal;
  207. }
  208. ol.loweralpha {
  209. list-style-type: lower-alpha;
  210. }
  211. ol.upperalpha {
  212. list-style-type: upper-alpha;
  213. }
  214. ol.lowerroman {
  215. list-style-type: lower-roman;
  216. }
  217. ol.upperroman {
  218. list-style-type: upper-roman;
  219. }
  220. div.compact ul, div.compact ol,
  221. div.compact p, div.compact p,
  222. div.compact div, div.compact div {
  223. margin-top: 0.1em;
  224. margin-bottom: 0.1em;
  225. }
  226. div.tableblock > table {
  227. border: 3px solid #527bbd;
  228. }
  229. thead {
  230. font-family: sans-serif;
  231. font-weight: bold;
  232. }
  233. tfoot {
  234. font-weight: bold;
  235. }
  236. td > div.verse {
  237. white-space: pre;
  238. }
  239. p.table {
  240. margin-top: 0;
  241. }
  242. /* Because the table frame attribute is overriden by CSS in most browsers. */
  243. div.tableblock > table[frame="void"] {
  244. border-style: none;
  245. }
  246. div.tableblock > table[frame="hsides"] {
  247. border-left-style: none;
  248. border-right-style: none;
  249. }
  250. div.tableblock > table[frame="vsides"] {
  251. border-top-style: none;
  252. border-bottom-style: none;
  253. }
  254. div.hdlist {
  255. margin-top: 0.8em;
  256. margin-bottom: 0.8em;
  257. }
  258. div.hdlist tr {
  259. padding-bottom: 15px;
  260. }
  261. dt.hdlist1.strong, td.hdlist1.strong {
  262. font-weight: bold;
  263. }
  264. td.hdlist1 {
  265. vertical-align: top;
  266. font-style: normal;
  267. padding-right: 0.8em;
  268. color: navy;
  269. }
  270. td.hdlist2 {
  271. vertical-align: top;
  272. }
  273. div.hdlist.compact tr {
  274. margin: 0;
  275. padding-bottom: 0;
  276. }
  277. .comment {
  278. background: yellow;
  279. }
  280. .footnote, .footnoteref {
  281. font-size: 0.8em;
  282. }
  283. span.footnote, span.footnoteref {
  284. vertical-align: super;
  285. }
  286. #footnotes {
  287. margin: 20px 0 20px 0;
  288. padding: 7px 0 0 0;
  289. }
  290. #footnotes div.footnote {
  291. margin: 0 0 5px 0;
  292. }
  293. #footnotes hr {
  294. border: none;
  295. border-top: 1px solid silver;
  296. height: 1px;
  297. text-align: left;
  298. margin-left: 0;
  299. width: 20%;
  300. min-width: 100px;
  301. }
  302. @media print {
  303. div#footer-badges { display: none; }
  304. }
  305. div#toctitle {
  306. color: #527bbd;
  307. font-family: sans-serif;
  308. font-size: 1.1em;
  309. font-weight: bold;
  310. margin-top: 1.0em;
  311. margin-bottom: 0.1em;
  312. }
  313. div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
  314. margin-top: 0;
  315. margin-bottom: 0;
  316. }
  317. div.toclevel2 {
  318. margin-left: 2em;
  319. font-size: 0.9em;
  320. }
  321. div.toclevel3 {
  322. margin-left: 4em;
  323. font-size: 0.9em;
  324. }
  325. div.toclevel4 {
  326. margin-left: 6em;
  327. font-size: 0.9em;
  328. }
  329. /* Overrides for manpage documents */
  330. h1 {
  331. padding-top: 0.5em;
  332. padding-bottom: 0.5em;
  333. border-top: 2px solid silver;
  334. border-bottom: 2px solid silver;
  335. }
  336. h2 {
  337. border-style: none;
  338. }
  339. div.sectionbody {
  340. margin-left: 5%;
  341. }
  342. @media print {
  343. div#toc { display: none; }
  344. }
  345. /* Workarounds for IE6's broken and incomplete CSS2. */
  346. div.sidebar-content {
  347. background: #ffffee;
  348. border: 1px solid silver;
  349. padding: 0.5em;
  350. }
  351. div.sidebar-title, div.image-title {
  352. color: #527bbd;
  353. font-family: sans-serif;
  354. font-weight: bold;
  355. margin-top: 0.0em;
  356. margin-bottom: 0.5em;
  357. }
  358. div.listingblock div.content {
  359. border: 1px solid silver;
  360. background: #f4f4f4;
  361. padding: 0.5em;
  362. }
  363. div.quoteblock-attribution {
  364. padding-top: 0.5em;
  365. text-align: right;
  366. }
  367. div.verseblock-content {
  368. white-space: pre;
  369. }
  370. div.verseblock-attribution {
  371. padding-top: 0.75em;
  372. text-align: left;
  373. }
  374. div.exampleblock-content {
  375. border-left: 2px solid silver;
  376. padding-left: 0.5em;
  377. }
  378. /* IE6 sets dynamically generated links as visited. */
  379. div#toc a:visited { color: blue; }
  380. </style>
  381. <script type="text/javascript">
  382. /*<![CDATA[*/
  383. window.onload = function(){asciidoc.footnotes();}
  384. var asciidoc = { // Namespace.
  385. /////////////////////////////////////////////////////////////////////
  386. // Table Of Contents generator
  387. /////////////////////////////////////////////////////////////////////
  388. /* Author: Mihai Bazon, September 2002
  389. * http://students.infoiasi.ro/~mishoo
  390. *
  391. * Table Of Content generator
  392. * Version: 0.4
  393. *
  394. * Feel free to use this script under the terms of the GNU General Public
  395. * License, as long as you do not remove or alter this notice.
  396. */
  397. /* modified by Troy D. Hanson, September 2006. License: GPL */
  398. /* modified by Stuart Rackham, 2006, 2009. License: GPL */
  399. // toclevels = 1..4.
  400. toc: function (toclevels) {
  401. function getText(el) {
  402. var text = "";
  403. for (var i = el.firstChild; i != null; i = i.nextSibling) {
  404. if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
  405. text += i.data;
  406. else if (i.firstChild != null)
  407. text += getText(i);
  408. }
  409. return text;
  410. }
  411. function TocEntry(el, text, toclevel) {
  412. this.element = el;
  413. this.text = text;
  414. this.toclevel = toclevel;
  415. }
  416. function tocEntries(el, toclevels) {
  417. var result = new Array;
  418. var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
  419. // Function that scans the DOM tree for header elements (the DOM2
  420. // nodeIterator API would be a better technique but not supported by all
  421. // browsers).
  422. var iterate = function (el) {
  423. for (var i = el.firstChild; i != null; i = i.nextSibling) {
  424. if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
  425. var mo = re.exec(i.tagName);
  426. if (mo)
  427. result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
  428. iterate(i);
  429. }
  430. }
  431. }
  432. iterate(el);
  433. return result;
  434. }
  435. var toc = document.getElementById("toc");
  436. var entries = tocEntries(document.getElementById("content"), toclevels);
  437. for (var i = 0; i < entries.length; ++i) {
  438. var entry = entries[i];
  439. if (entry.element.id == "")
  440. entry.element.id = "_toc_" + i;
  441. var a = document.createElement("a");
  442. a.href = "#" + entry.element.id;
  443. a.appendChild(document.createTextNode(entry.text));
  444. var div = document.createElement("div");
  445. div.appendChild(a);
  446. div.className = "toclevel" + entry.toclevel;
  447. toc.appendChild(div);
  448. }
  449. if (entries.length == 0)
  450. toc.parentNode.removeChild(toc);
  451. },
  452. /////////////////////////////////////////////////////////////////////
  453. // Footnotes generator
  454. /////////////////////////////////////////////////////////////////////
  455. /* Based on footnote generation code from:
  456. * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
  457. */
  458. footnotes: function () {
  459. var cont = document.getElementById("content");
  460. var noteholder = document.getElementById("footnotes");
  461. var spans = cont.getElementsByTagName("span");
  462. var refs = {};
  463. var n = 0;
  464. for (i=0; i<spans.length; i++) {
  465. if (spans[i].className == "footnote") {
  466. n++;
  467. // Use [\s\S] in place of . so multi-line matches work.
  468. // Because JavaScript has no s (dotall) regex flag.
  469. note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
  470. noteholder.innerHTML +=
  471. "<div class='footnote' id='_footnote_" + n + "'>" +
  472. "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
  473. n + "</a>. " + note + "</div>";
  474. spans[i].innerHTML =
  475. "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
  476. "' title='View footnote' class='footnote'>" + n + "</a>]";
  477. var id =spans[i].getAttribute("id");
  478. if (id != null) refs["#"+id] = n;
  479. }
  480. }
  481. if (n == 0)
  482. noteholder.parentNode.removeChild(noteholder);
  483. else {
  484. // Process footnoterefs.
  485. for (i=0; i<spans.length; i++) {
  486. if (spans[i].className == "footnoteref") {
  487. var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
  488. href = href.match(/#.*/)[0]; // Because IE return full URL.
  489. n = refs[href];
  490. spans[i].innerHTML =
  491. "[<a href='#_footnote_" + n +
  492. "' title='View footnote' class='footnote'>" + n + "</a>]";
  493. }
  494. }
  495. }
  496. }
  497. }
  498. /*]]>*/
  499. </script>
  500. </head>
  501. <body>
  502. <div id="header">
  503. <h1>
  504. ARIA2C(1) Manual Page
  505. </h1>
  506. <h2>NAME</h2>
  507. <div class="sectionbody">
  508. <p>aria2c -
  509. The ultra fast download utility
  510. </p>
  511. </div>
  512. </div>
  513. <div id="content">
  514. <h2 id="_synopsis">SYNOPSIS</h2>
  515. <div class="sectionbody">
  516. <div class="paragraph"><p>aria2c [<em>OPTIONS</em>] [<em>URI</em> | <em>MAGNET</em> | <em>TORRENT_FILE</em> | <em>METALINK_FILE</em>]&#8230;</p></div>
  517. </div>
  518. <h2 id="_description">DESCRIPTION</h2>
  519. <div class="sectionbody">
  520. <div class="paragraph"><p>aria2 is a utility for downloading files. The supported protocols are
  521. HTTP(S), FTP, BitTorrent, and Metalink. aria2 can download a file from
  522. multiple sources/protocols and tries to utilize your maximum download
  523. bandwidth. It supports downloading a file from HTTP(S)/FTP and
  524. BitTorrent at the same time, while the data downloaded from
  525. HTTP(S)/FTP is uploaded to the BitTorrent swarm. Using Metalink&#8217;s
  526. chunk checksums, aria2 automatically validates chunks of data while
  527. downloading a file like BitTorrent.</p></div>
  528. </div>
  529. <h2 id="_options">OPTIONS</h2>
  530. <div class="sectionbody">
  531. <h3 id="_basic_options">Basic Options</h3><div style="clear:left"></div>
  532. <div class="dlist"><dl>
  533. <dt class="hdlist1">
  534. <strong>-d</strong>, <strong>--dir</strong>=DIR
  535. </dt>
  536. <dd>
  537. <p>
  538. The directory to store the downloaded file.
  539. </p>
  540. </dd>
  541. <dt class="hdlist1">
  542. <strong>-i</strong>, <strong>--input-file</strong>=FILE
  543. </dt>
  544. <dd>
  545. <p>
  546. Downloads URIs found in FILE. You can specify multiple URIs for a single
  547. entity: separate URIs on a single line using the TAB character.
  548. Reads input from stdin when <em>-</em> is specified.
  549. The additional <strong>out</strong> and <strong>dir</strong> options can be specified after each line of
  550. URIs. This optional line must start with white space(s).
  551. See <strong>Input File</strong> subsection for details.
  552. </p>
  553. </dd>
  554. <dt class="hdlist1">
  555. <strong>-l</strong>, <strong>--log</strong>=LOG
  556. </dt>
  557. <dd>
  558. <p>
  559. The file name of the log file. If <em>-</em> is specified, log is written to
  560. stdout.
  561. </p>
  562. </dd>
  563. <dt class="hdlist1">
  564. <strong>-j</strong>, <strong>--max-concurrent-downloads</strong>=N
  565. </dt>
  566. <dd>
  567. <p>
  568. Set maximum number of parallel downloads for every static (HTTP/FTP) URL,
  569. torrent and metalink. See also <strong>-s</strong> and <strong>-C</strong> option.
  570. Default: <em>5</em>
  571. </p>
  572. </dd>
  573. <dt class="hdlist1">
  574. <strong>-V</strong>, <strong>--check-integrity</strong>[=<em>true</em>|<em>false</em>]
  575. </dt>
  576. <dd>
  577. <p>
  578. Check file integrity by validating piece hashes.
  579. This option has effect only in BitTorrent and Metalink downloads with
  580. chunk checksums.
  581. Use this option to re-download a damaged portion of a file.
  582. Default: <em>false</em>
  583. </p>
  584. </dd>
  585. <dt class="hdlist1">
  586. <strong>-c</strong>, <strong>--continue</strong>
  587. </dt>
  588. <dd>
  589. <p>
  590. Continue downloading a partially downloaded file.
  591. Use this option to resume a download started by a web browser or another
  592. program which downloads files sequentially from the beginning.
  593. Currently this option is only applicable to HTTP(S)/FTP downloads.
  594. </p>
  595. </dd>
  596. <dt class="hdlist1">
  597. <strong>-h</strong>, <strong>--help</strong>[=TAG|KEYWORD]
  598. </dt>
  599. <dd>
  600. <p>
  601. The help messages are classified with tags. A tag starts with
  602. "#". For example, type "--help=#http" to get the usage for the
  603. options tagged with "#http". If non-tag word is given, print the
  604. usage for the options whose name includes that word.
  605. Available Values: <em>#basic</em>, <em>#advanced</em>, <em>#http</em>, <em>#https</em>, <em>#ftp</em>,
  606. <em>#metalink</em>, <em>#bittorrent</em>, <em>#cookie</em>, <em>#hook</em>, <em>#file</em>,
  607. <em>#xml-rpc</em>, <em>#experimental</em>, <em>#all</em>
  608. Default: <em>#basic</em>
  609. </p>
  610. </dd>
  611. </dl></div>
  612. <h3 id="_http_ftp_options">HTTP/FTP Options</h3><div style="clear:left"></div>
  613. <div class="dlist"><dl>
  614. <dt class="hdlist1">
  615. <strong>--all-proxy</strong>=PROXY
  616. </dt>
  617. <dd>
  618. <p>
  619. Use this proxy server for all protocols.
  620. You can override this setting and specify a proxy server for a particular
  621. protocol using <strong>--http-proxy</strong>, <strong>--https-proxy</strong> and <strong>--ftp-proxy</strong> options.
  622. This affects all URLs.
  623. The format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  624. </p>
  625. </dd>
  626. <dt class="hdlist1">
  627. <strong>--connect-timeout</strong>=SEC
  628. </dt>
  629. <dd>
  630. <p>
  631. Set the connect timeout in seconds to establish connection to
  632. HTTP/FTP/proxy server. After the connection is established, this
  633. option makes no effect and <strong>--timeout</strong> option is used instead.
  634. Default: <em>60</em>
  635. </p>
  636. </dd>
  637. <dt class="hdlist1">
  638. <strong>--dry-run</strong>[=<em>true</em>|<em>false</em>]
  639. </dt>
  640. <dd>
  641. <p>
  642. If <em>true</em> is given, aria2 just checks whether the remote file is
  643. available and doesn&#8217;t download data. This option has effect on
  644. HTTP/FTP download. BitTorrent downloads are canceled if <em>true</em> is
  645. specified. Default: <em>false</em>
  646. </p>
  647. </dd>
  648. <dt class="hdlist1">
  649. <strong>--lowest-speed-limit</strong>=SPEED
  650. </dt>
  651. <dd>
  652. <p>
  653. Close connection if download speed is lower than or equal to this
  654. value(bytes per sec).
  655. <em>0</em> means aria2 does not have a lowest speed limit.
  656. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  657. This option does not affect BitTorrent downloads.
  658. Default: <em>0</em>
  659. </p>
  660. </dd>
  661. <dt class="hdlist1">
  662. <strong>--max-file-not-found</strong>=NUM
  663. </dt>
  664. <dd>
  665. <p>
  666. If aria2 receives &#8216;file not found&#8217; status from the remote HTTP/FTP
  667. servers NUM times without getting a single byte, then force the
  668. download to fail. Specify <em>0</em> to disable this option. This options is
  669. effective only when using HTTP/FTP servers.
  670. Default: <em>0</em>
  671. </p>
  672. </dd>
  673. <dt class="hdlist1">
  674. <strong>-m</strong>, <strong>--max-tries</strong>=N
  675. </dt>
  676. <dd>
  677. <p>
  678. Set number of tries. <em>0</em> means unlimited.
  679. Default: <em>5</em>
  680. </p>
  681. </dd>
  682. <dt class="hdlist1">
  683. <strong>-n</strong>, <strong>--no-netrc</strong>
  684. </dt>
  685. <dd>
  686. <p>
  687. Disables netrc support. netrc support is enabled by default.
  688. </p>
  689. </dd>
  690. <dt class="hdlist1">
  691. <strong>--no-proxy</strong>=DOMAINS
  692. </dt>
  693. <dd>
  694. <p>
  695. Specify comma separated hostnames or domains where proxy should not be
  696. used.
  697. </p>
  698. </dd>
  699. <dt class="hdlist1">
  700. <strong>-o</strong>, <strong>--out</strong>=FILE
  701. </dt>
  702. <dd>
  703. <p>
  704. The file name of the downloaded file.
  705. </p>
  706. </dd>
  707. </dl></div>
  708. <div class="admonitionblock">
  709. <table><tr>
  710. <td class="icon">
  711. <div class="title">Note</div>
  712. </td>
  713. <td class="content">In Metalink or BitTorrent download you cannot specify file name.
  714. The file name specified here is only used when the URLs fed to aria2
  715. are done by command line without <strong>-i</strong>, <strong>-Z</strong> option. For example:
  716. aria2c -o myfile.zip "http://mirror1/file.zip" "http://mirror2/file.zip"</td>
  717. </tr></table>
  718. </div>
  719. <div class="dlist"><dl>
  720. <dt class="hdlist1">
  721. <strong>--proxy-method</strong>=METHOD
  722. </dt>
  723. <dd>
  724. <p>
  725. Set the method to use in proxy request. <em>METHOD</em> is either <em>get</em> or
  726. <em>tunnel</em>. HTTPS downloads always use <em>tunnel</em> regardless of this
  727. option.
  728. Default: <em>get</em>
  729. </p>
  730. </dd>
  731. <dt class="hdlist1">
  732. <strong>-R</strong>, <strong>--remote-time</strong>[=<em>true</em>|<em>false</em>]
  733. </dt>
  734. <dd>
  735. <p>
  736. Retrieve timestamp of the remote file from the remote HTTP/FTP
  737. server and if it is available, apply it to the local file.
  738. Default: <em>false</em>
  739. </p>
  740. </dd>
  741. <dt class="hdlist1">
  742. <strong>--server-stat-of</strong>=FILE
  743. </dt>
  744. <dd>
  745. <p>
  746. Specify the filename to which performance profile of the servers is
  747. saved. You can load saved data using <strong>--server-stat-if</strong> option. See
  748. <strong>Server Performance Profile</strong> subsection below for file format.
  749. </p>
  750. </dd>
  751. <dt class="hdlist1">
  752. <strong>--server-stat-if</strong>=FILE
  753. </dt>
  754. <dd>
  755. <p>
  756. Specify the filename to load performance profile of the servers. The
  757. loaded data will be used in some URI selector such as <em>feedback</em>.
  758. See also <strong>--uri-selector</strong> option. See <strong>Server Performance Profile</strong>
  759. subsection below for file format.
  760. </p>
  761. </dd>
  762. <dt class="hdlist1">
  763. <strong>--server-stat-timeout</strong>=SEC
  764. </dt>
  765. <dd>
  766. <p>
  767. Specifies timeout in seconds to invalidate performance profile of
  768. the servers since the last contact to them.
  769. Default: <em>86400</em> (24hours)
  770. </p>
  771. </dd>
  772. <dt class="hdlist1">
  773. <strong>-s</strong>, <strong>--split</strong>=N
  774. </dt>
  775. <dd>
  776. <p>
  777. Download a file using N connections.
  778. If more than N URLs are given, first N URLs are used and remaining URLs are
  779. used for backup.
  780. If less than N URLs are given, those URLs are used more than once so that N
  781. connections total are made simultaneously.
  782. Please see <strong>-j</strong> option too.
  783. Please note that in Metalink download, this option has no effect and use
  784. <strong>-C</strong> option instead.
  785. Default: <em>5</em>
  786. </p>
  787. </dd>
  788. <dt class="hdlist1">
  789. <strong>-t</strong>, <strong>--timeout</strong>=SEC
  790. </dt>
  791. <dd>
  792. <p>
  793. Set timeout in seconds.
  794. Default: <em>60</em>
  795. </p>
  796. </dd>
  797. <dt class="hdlist1">
  798. <strong>--uri-selector</strong>=SELECTOR
  799. </dt>
  800. <dd>
  801. <p>
  802. Specify URI selection algorithm. The possible values are <em>inorder</em>,
  803. <em>feedback</em> and <em>adaptive</em>. If <em>inorder</em> is given, URI is tried in
  804. the order appeared in the URI list. If <em>feedback</em> is given, aria2
  805. uses download speed observed in the previous downloads and choose
  806. fastest server in the URI list. This also effectively skips dead
  807. mirrors. The observed download speed is a part of performance
  808. profile of servers mentioned in <strong>--server-stat-of</strong> and
  809. <strong>--server-stat-if</strong> options. If <em>adaptive</em> is given, selects one of
  810. the best mirrors for the first and reserved connections. For
  811. supplementary ones, it returns mirrors which has not been tested
  812. yet, and if each of them has already been tested, returns mirrors
  813. which has to be tested again. Otherwise, it doesn&#8217;t select anymore
  814. mirrors. Like <em>feedback</em>, it uses a performance profile of servers.
  815. Default: <em>feedback</em>
  816. </p>
  817. </dd>
  818. </dl></div>
  819. <h3 id="_http_specific_options">HTTP Specific Options</h3><div style="clear:left"></div>
  820. <div class="dlist"><dl>
  821. <dt class="hdlist1">
  822. <strong>--ca-certificate</strong>=FILE
  823. </dt>
  824. <dd>
  825. <p>
  826. Use the certificate authorities in FILE to verify the peers.
  827. The certificate file must be in PEM format and can contain multiple CA
  828. certificates.
  829. Use <strong>--check-certificate</strong> option to enable verification.
  830. </p>
  831. </dd>
  832. <dt class="hdlist1">
  833. <strong>--certificate</strong>=FILE
  834. </dt>
  835. <dd>
  836. <p>
  837. Use the client certificate in FILE.
  838. The certificate must be in PEM format.
  839. You may use <strong>--private-key</strong> option to specify the private key.
  840. </p>
  841. </dd>
  842. <dt class="hdlist1">
  843. <strong>--check-certificate</strong>[=<em>true</em>|<em>false</em>]
  844. </dt>
  845. <dd>
  846. <p>
  847. Verify the peer using certificates specified in <strong>--ca-certificate</strong> option.
  848. Default: <em>true</em>
  849. </p>
  850. </dd>
  851. <dt class="hdlist1">
  852. <strong>--http-auth-challenge</strong>[=<em>true</em>|<em>false</em>]
  853. </dt>
  854. <dd>
  855. <p>
  856. Send HTTP authorization header only when it is requested by the
  857. server. If <em>false</em> is set, then authorization header is always sent
  858. to the server. There is an exception: if username and password are
  859. embedded in URI, authorization header is always sent to the server
  860. regardless of this option. Default: <em>false</em>
  861. </p>
  862. </dd>
  863. <dt class="hdlist1">
  864. <strong>--http-auth-scheme</strong>=SCHEME
  865. </dt>
  866. <dd>
  867. <p>
  868. Set HTTP authentication scheme.
  869. Currently, <em>basic</em> is the only supported scheme.
  870. Default: <em>basic</em>
  871. </p>
  872. </dd>
  873. <dt class="hdlist1">
  874. <strong>--http-user</strong>=USER
  875. </dt>
  876. <dd>
  877. <p>
  878. Set HTTP user. This affects all URLs.
  879. </p>
  880. </dd>
  881. <dt class="hdlist1">
  882. <strong>--http-passwd</strong>=PASSWD
  883. </dt>
  884. <dd>
  885. <p>
  886. Set HTTP password. This affects all URLs.
  887. </p>
  888. </dd>
  889. <dt class="hdlist1">
  890. <strong>--http-proxy</strong>=PROXY
  891. </dt>
  892. <dd>
  893. <p>
  894. Use this proxy server for HTTP. See also <strong>--all-proxy</strong> option.
  895. This affects all URLs.
  896. The format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  897. </p>
  898. </dd>
  899. <dt class="hdlist1">
  900. <strong>--https-proxy</strong>=PROXY
  901. </dt>
  902. <dd>
  903. <p>
  904. Use this proxy server for HTTPS. See also <strong>--all-proxy</strong> option.
  905. This affects all URLs.
  906. The format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  907. </p>
  908. </dd>
  909. <dt class="hdlist1">
  910. <strong>--private-key</strong>=FILE
  911. </dt>
  912. <dd>
  913. <p>
  914. Use the private key in FILE.
  915. The private key must be decrypted and in PEM format.
  916. The behavior when encrypted one is given is undefined.
  917. See also <strong>--certificate</strong> option.
  918. </p>
  919. </dd>
  920. <dt class="hdlist1">
  921. <strong>--referer</strong>=REFERER
  922. </dt>
  923. <dd>
  924. <p>
  925. Set Referer. This affects all URLs.
  926. </p>
  927. </dd>
  928. <dt class="hdlist1">
  929. <strong>--enable-http-keep-alive</strong>[=<em>true</em>|<em>false</em>]
  930. </dt>
  931. <dd>
  932. <p>
  933. Enable HTTP/1.1 persistent connection.
  934. Default: <em>true</em>
  935. </p>
  936. </dd>
  937. <dt class="hdlist1">
  938. <strong>--enable-http-pipelining</strong>[=<em>true</em>|<em>false</em>]
  939. </dt>
  940. <dd>
  941. <p>
  942. Enable HTTP/1.1 pipelining.
  943. Default: <em>false</em>
  944. </p>
  945. </dd>
  946. <dt class="hdlist1">
  947. <strong>--header</strong>=HEADER
  948. </dt>
  949. <dd>
  950. <p>
  951. Append HEADER to HTTP request header.
  952. You can use this option repeatedly to specify more than one header:
  953. aria2c <strong>--header</strong>="X-A: b78" <strong>--header</strong>="X-B: 9J1" "http://host/file"
  954. </p>
  955. </dd>
  956. <dt class="hdlist1">
  957. <strong>--load-cookies</strong>=FILE
  958. </dt>
  959. <dd>
  960. <p>
  961. Load Cookies from FILE using the Firefox3 format (SQLite3) and the
  962. Mozilla/Firefox(1.x/2.x)/Netscape format.
  963. </p>
  964. </dd>
  965. </dl></div>
  966. <div class="admonitionblock">
  967. <table><tr>
  968. <td class="icon">
  969. <div class="title">Note</div>
  970. </td>
  971. <td class="content">If aria2 is built without libsqlite3, then it doesn&#8217;t support Firefox3 cookie format.</td>
  972. </tr></table>
  973. </div>
  974. <div class="dlist"><dl>
  975. <dt class="hdlist1">
  976. <strong>--save-cookies</strong>=FILE
  977. </dt>
  978. <dd>
  979. <p>
  980. Save Cookies to FILE in Mozilla/Firefox(1.x/2.x)/ Netscape
  981. format. If FILE already exists, it is overwritten. Session Cookies
  982. are also saved and their expiry values are treated as 0. Possible
  983. Values: <em>/path/to/file</em>
  984. </p>
  985. </dd>
  986. <dt class="hdlist1">
  987. <strong>--use-head</strong>[=<em>true</em>|<em>false</em>]
  988. </dt>
  989. <dd>
  990. <p>
  991. Use HEAD method for the first request to the HTTP server.
  992. Default: <em>false</em>
  993. </p>
  994. </dd>
  995. <dt class="hdlist1">
  996. <strong>-U</strong>, <strong>--user-agent</strong>=USER_AGENT
  997. </dt>
  998. <dd>
  999. <p>
  1000. Set user agent for HTTP(S) downloads.
  1001. Default: <em>aria2/$VERSION</em>, $VERSION is replaced by package version.
  1002. </p>
  1003. </dd>
  1004. </dl></div>
  1005. <h3 id="_ftp_specific_options">FTP Specific Options</h3><div style="clear:left"></div>
  1006. <div class="dlist"><dl>
  1007. <dt class="hdlist1">
  1008. <strong>--ftp-user</strong>=USER
  1009. </dt>
  1010. <dd>
  1011. <p>
  1012. Set FTP user. This affects all URLs.
  1013. Default: <em>anonymous</em>
  1014. </p>
  1015. </dd>
  1016. <dt class="hdlist1">
  1017. <strong>--ftp-passwd</strong>=PASSWD
  1018. </dt>
  1019. <dd>
  1020. <p>
  1021. Set FTP password. This affects all URLs.
  1022. If user name is embedded but password is missing in URI, aria2 tries
  1023. to resolve password using .netrc. If password is found in .netrc,
  1024. then use it as password. If not, use the password specified in this
  1025. option.
  1026. Default: <em>ARIA2USER@</em>
  1027. </p>
  1028. </dd>
  1029. <dt class="hdlist1">
  1030. <strong>-p</strong>, <strong>--ftp-pasv</strong>[=<em>true</em>|<em>false</em>]
  1031. </dt>
  1032. <dd>
  1033. <p>
  1034. Use the passive mode in FTP.
  1035. If <em>false</em> is given, the active mode will be used.
  1036. Default: <em>true</em>
  1037. </p>
  1038. </dd>
  1039. <dt class="hdlist1">
  1040. <strong>--ftp-proxy</strong>=PROXY
  1041. </dt>
  1042. <dd>
  1043. <p>
  1044. Use this proxy server for FTP. See also <strong>--all-proxy</strong> option.
  1045. This affects all URLs.
  1046. The format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  1047. </p>
  1048. </dd>
  1049. <dt class="hdlist1">
  1050. <strong>--ftp-type</strong>=TYPE
  1051. </dt>
  1052. <dd>
  1053. <p>
  1054. Set FTP transfer type. TYPE is either <em>binary</em> or <em>ascii</em>.
  1055. Default: <em>binary</em>
  1056. </p>
  1057. </dd>
  1058. <dt class="hdlist1">
  1059. <strong>--ftp-reuse-connection</strong>[=<em>true</em>|<em>false</em>]
  1060. </dt>
  1061. <dd>
  1062. <p>
  1063. Reuse connection in FTP.
  1064. Default: <em>true</em>
  1065. </p>
  1066. </dd>
  1067. </dl></div>
  1068. <h3 id="_bittorrent_metalink_options">BitTorrent/Metalink Options</h3><div style="clear:left"></div>
  1069. <div class="dlist"><dl>
  1070. <dt class="hdlist1">
  1071. <strong>--select-file</strong>=INDEX&#8230;
  1072. </dt>
  1073. <dd>
  1074. <p>
  1075. Set file to download by specifying its index.
  1076. You can find the file index using the <strong>--show-files</strong> option.
  1077. Multiple indexes can be specified by using ",", for example: <em>3,6</em>.
  1078. You can also use "-" to specify a range: <em>1-5</em>.
  1079. "," and "-" can be used together: <em>1-5,8,9</em>.
  1080. When used with the -M option, index may vary depending on the query
  1081. (see <strong>--metalink-</strong>* options).
  1082. </p>
  1083. </dd>
  1084. </dl></div>
  1085. <div class="admonitionblock">
  1086. <table><tr>
  1087. <td class="icon">
  1088. <div class="title">Note</div>
  1089. </td>
  1090. <td class="content">In multi file torrent, the adjacent files specified by this option may
  1091. also be downloaded. This is by design, not a bug.
  1092. A single piece may include several files or part of files, and aria2
  1093. writes the piece to the appropriate files.</td>
  1094. </tr></table>
  1095. </div>
  1096. <div class="dlist"><dl>
  1097. <dt class="hdlist1">
  1098. <strong>-S</strong>, <strong>--show-files</strong>
  1099. </dt>
  1100. <dd>
  1101. <p>
  1102. Print file listing of .torrent or .metalink file and exit.
  1103. In case of .torrent file, additional information
  1104. (infohash, piece length, etc) is also printed.
  1105. </p>
  1106. </dd>
  1107. </dl></div>
  1108. <h3 id="_bittorrent_specific_options">BitTorrent Specific Options</h3><div style="clear:left"></div>
  1109. <div class="dlist"><dl>
  1110. <dt class="hdlist1">
  1111. <strong>--bt-external-ip</strong>=IPADDRESS
  1112. </dt>
  1113. <dd>
  1114. <p>
  1115. Specify the external IP address to report to a BitTorrent
  1116. tracker. Although this function is named "external", it can accept
  1117. any kind of IP addresses. IPADDRESS must be a numeric IP address.
  1118. </p>
  1119. </dd>
  1120. <dt class="hdlist1">
  1121. <strong>--bt-hash-check-seed</strong>[=<em>true</em>|<em>false</em>]
  1122. </dt>
  1123. <dd>
  1124. <p>
  1125. If <em>true</em> is given, after hash check using <strong>--check-integrity</strong> option and
  1126. file is complete, continue to seed file. If you want to check file
  1127. and download it only when it is damaged or incomplete, set this
  1128. option to <em>false</em>. This option has effect only on BitTorrent download.
  1129. Default: <em>true</em>
  1130. </p>
  1131. </dd>
  1132. <dt class="hdlist1">
  1133. <strong>--bt-max-open-files</strong>=NUM
  1134. </dt>
  1135. <dd>
  1136. <p>
  1137. Specify maximum number of files to open in each BitTorrent download.
  1138. Default: <em>100</em>
  1139. </p>
  1140. </dd>
  1141. <dt class="hdlist1">
  1142. <strong>--bt-max-peers</strong>=NUM
  1143. </dt>
  1144. <dd>
  1145. <p>
  1146. Specify the maximum number of peers per torrent. <em>0</em> means
  1147. unlimited. See also <strong>--bt-request-peer-speed-limit</strong> option.
  1148. Default: <em>55</em>
  1149. </p>
  1150. </dd>
  1151. <dt class="hdlist1">
  1152. <strong>--bt-min-crypto-level</strong>=<em>plain</em>|<em>arc4</em>
  1153. </dt>
  1154. <dd>
  1155. <p>
  1156. Set minimum level of encryption method.
  1157. If several encryption methods are provided by a peer, aria2 chooses the lowest
  1158. one which satisfies the given level.
  1159. Default: <em>plain</em>
  1160. </p>
  1161. </dd>
  1162. <dt class="hdlist1">
  1163. <strong>--bt-prioritize-piece</strong>=<em>head</em>[=SIZE],<em>tail</em>[=SIZE]
  1164. </dt>
  1165. <dd>
  1166. <p>
  1167. Try to download first and last pieces of each file first. The
  1168. argument can contain 2 keywords: <em>head</em> and <em>tail</em>. To include both
  1169. keywords, they must be separated by comma. These keywords can take
  1170. one parameter, SIZE. For example , if <em>head</em>=SIZE is specified,
  1171. pieces in the range of first SIZE bytes of each file get higher
  1172. priority. <em>tail</em>=SIZE means the range of last SIZE bytes of each
  1173. file. SIZE can include <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1174. </p>
  1175. </dd>
  1176. <dt class="hdlist1">
  1177. <strong>--bt-require-crypto</strong>=<em>true</em>|<em>false</em>
  1178. </dt>
  1179. <dd>
  1180. <p>
  1181. If true is given, aria2 doesn&#8217;t accept and establish connection with legacy
  1182. BitTorrent handshake(\19BitTorrent protocol).
  1183. Thus aria2 always uses Obfuscation handshake.
  1184. Default: <em>false</em>
  1185. </p>
  1186. </dd>
  1187. <dt class="hdlist1">
  1188. <strong>--bt-request-peer-speed-limit</strong>=SPEED
  1189. </dt>
  1190. <dd>
  1191. <p>
  1192. If the whole download speed of every torrent is lower than SPEED,
  1193. aria2 temporarily increases the number of peers to try for more
  1194. download speed. Configuring this option with your preferred download
  1195. speed can increase your download speed in some cases.
  1196. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1197. Default: <em>50K</em>
  1198. </p>
  1199. </dd>
  1200. <dt class="hdlist1">
  1201. <strong>--bt-seed-unverified</strong>[=<em>true</em>|<em>false</em>]
  1202. </dt>
  1203. <dd>
  1204. <p>
  1205. Seed previously downloaded files without verifying piece hashes.
  1206. Default: <em>false</em>
  1207. </p>
  1208. </dd>
  1209. <dt class="hdlist1">
  1210. <strong>--bt-stop-timeout</strong>=SEC
  1211. </dt>
  1212. <dd>
  1213. <p>
  1214. Stop BitTorrent download if download speed is 0 in consecutive SEC
  1215. seconds. If <em>0</em> is given, this feature is disabled. Default: <em>0</em>
  1216. </p>
  1217. </dd>
  1218. <dt class="hdlist1">
  1219. <strong>--bt-tracker-interval</strong>=SEC
  1220. </dt>
  1221. <dd>
  1222. <p>
  1223. Set the interval in seconds between tracker requests. This
  1224. completely overrides interval value and aria2 just uses this value
  1225. and ignores the min interval and interval value in the response of
  1226. tracker. If <em>0</em> is set, aria2 determines interval based on the
  1227. response of tracker and the download progress. Default: <em>0</em>
  1228. </p>
  1229. </dd>
  1230. <dt class="hdlist1">
  1231. <strong>--dht-entry-point</strong>=HOST:PORT
  1232. </dt>
  1233. <dd>
  1234. <p>
  1235. Set host and port as an entry point to DHT network.
  1236. </p>
  1237. </dd>
  1238. <dt class="hdlist1">
  1239. <strong>--dht-file-path</strong>=PATH
  1240. </dt>
  1241. <dd>
  1242. <p>
  1243. Change the DHT routing table file to PATH.
  1244. Default: <em>$HOME/.aria2/dht.dat</em>
  1245. </p>
  1246. </dd>
  1247. <dt class="hdlist1">
  1248. <strong>--dht-listen-port</strong>=PORT&#8230;
  1249. </dt>
  1250. <dd>
  1251. <p>
  1252. Set UDP listening port for DHT.
  1253. Multiple ports can be specified by using ",", for example: <em>6881,6885</em>.
  1254. You can also use "-" to specify a range: <em>6881-6999</em>. "," and "-" can be used
  1255. together.
  1256. Default: <em>6881-6999</em>
  1257. </p>
  1258. </dd>
  1259. </dl></div>
  1260. <div class="admonitionblock">
  1261. <table><tr>
  1262. <td class="icon">
  1263. <div class="title">Note</div>
  1264. </td>
  1265. <td class="content">Make sure that the specified ports are open for incoming UDP traffic.</td>
  1266. </tr></table>
  1267. </div>
  1268. <div class="dlist"><dl>
  1269. <dt class="hdlist1">
  1270. <strong>--enable-dht</strong>[=<em>true</em>|<em>false</em>]
  1271. </dt>
  1272. <dd>
  1273. <p>
  1274. Enable DHT functionality. If a private flag is set in a torrent, aria2
  1275. doesn&#8217;t use DHT for that download even if <em>true</em> is given.
  1276. Default: <em>false</em>
  1277. </p>
  1278. </dd>
  1279. <dt class="hdlist1">
  1280. <strong>--enable-peer-exchange</strong>[=<em>true</em>|<em>false</em>]
  1281. </dt>
  1282. <dd>
  1283. <p>
  1284. Enable Peer Exchange extension. If a private flag is set in a torrent, this
  1285. feature is disabled for that download even if <em>true</em> is given.
  1286. Default: <em>true</em>
  1287. </p>
  1288. </dd>
  1289. <dt class="hdlist1">
  1290. <strong>--follow-torrent</strong>=<em>true</em>|<em>false</em>|<em>mem</em>
  1291. </dt>
  1292. <dd>
  1293. <p>
  1294. If <em>true</em> or <em>mem</em> is specified, when a file whose suffix is ".torrent" or content
  1295. type is "application/x-bittorrent" is downloaded, aria2 parses it as a torrent
  1296. file and downloads files mentioned in it.
  1297. If <em>mem</em> is specified, a torrent file is not written to the disk, but is just
  1298. kept in memory.
  1299. If <em>false</em> is specified, the action mentioned above is not taken.
  1300. Default: <em>true</em>
  1301. </p>
  1302. </dd>
  1303. <dt class="hdlist1">
  1304. <strong>-O</strong>, <strong>--index-out</strong>=INDEX=PATH
  1305. </dt>
  1306. <dd>
  1307. <p>
  1308. Set file path for file with index=INDEX. You can find the file index
  1309. using the <strong>--show-files</strong> option. PATH is a relative path to the
  1310. path specified in <strong>--dir</strong> option. You can use this option multiple
  1311. times. Using this option, you can specify the output filenames of
  1312. BitTorrent downloads.
  1313. </p>
  1314. </dd>
  1315. <dt class="hdlist1">
  1316. <strong>--listen-port</strong>=PORT&#8230;
  1317. </dt>
  1318. <dd>
  1319. <p>
  1320. Set TCP port number for BitTorrent downloads.
  1321. Multiple ports can be specified by using ",", for example: <em>6881,6885</em>.
  1322. You can also use "-" to specify a range: <em>6881-6999</em>.
  1323. "," and "-" can be used together: <em>6881-6889,6999</em>.
  1324. Default: <em>6881-6999</em>
  1325. </p>
  1326. </dd>
  1327. </dl></div>
  1328. <div class="admonitionblock">
  1329. <table><tr>
  1330. <td class="icon">
  1331. <div class="title">Note</div>
  1332. </td>
  1333. <td class="content">Make sure that the specified ports are open for incoming TCP traffic.</td>
  1334. </tr></table>
  1335. </div>
  1336. <div class="dlist"><dl>
  1337. <dt class="hdlist1">
  1338. <strong>--max-overall-upload-limit</strong>=SPEED
  1339. </dt>
  1340. <dd>
  1341. <p>
  1342. Set max overall upload speed in bytes/sec.
  1343. <em>0</em> means unrestricted.
  1344. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1345. To limit the upload speed per torrent, use <strong>--max-upload-limit</strong> option.
  1346. Default: <em>0</em>
  1347. </p>
  1348. </dd>
  1349. <dt class="hdlist1">
  1350. <strong>-u</strong>, <strong>--max-upload-limit</strong>=SPEED
  1351. </dt>
  1352. <dd>
  1353. <p>
  1354. Set max upload speed per each torrent in bytes/sec.
  1355. <em>0</em> means unrestricted.
  1356. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1357. To limit the overall upload speed, use <strong>--max-overall-upload-limit</strong> option.
  1358. Default: <em>0</em>
  1359. </p>
  1360. </dd>
  1361. <dt class="hdlist1">
  1362. <strong>--peer-id-prefix</strong>=PEER_ID_PREFIX
  1363. </dt>
  1364. <dd>
  1365. <p>
  1366. Specify the prefix of peer ID. The peer ID in
  1367. BitTorrent is 20 byte length. If more than 20
  1368. bytes are specified, only first 20 bytes are
  1369. used. If less than 20 bytes are specified, random
  1370. byte data are added to make its length 20 bytes.
  1371. Default: <em>aria2/$VERSION-</em>, $VERSION is replaced by package version.
  1372. </p>
  1373. </dd>
  1374. <dt class="hdlist1">
  1375. <strong>--seed-ratio</strong>=RATIO
  1376. </dt>
  1377. <dd>
  1378. <p>
  1379. Specify share ratio. Seed completed torrents until share ratio reaches
  1380. RATIO.
  1381. You are strongly encouraged to specify equals or more than <em>1.0</em> here.
  1382. Specify <em>0.0</em> if you intend to do seeding regardless of share ratio.
  1383. If <strong>--seed-time</strong> option is specified along with this option, seeding ends when
  1384. at least one of the conditions is satisfied.
  1385. Default: <em>1.0</em>
  1386. </p>
  1387. </dd>
  1388. <dt class="hdlist1">
  1389. <strong>--seed-time</strong>=MINUTES
  1390. </dt>
  1391. <dd>
  1392. <p>
  1393. Specify seeding time in minutes. Also see the <strong>--seed-ratio</strong> option.
  1394. </p>
  1395. </dd>
  1396. <dt class="hdlist1">
  1397. <strong>-T</strong>, <strong>--torrent-file</strong>=TORRENT_FILE
  1398. </dt>
  1399. <dd>
  1400. <p>
  1401. The path to the .torrent file.
  1402. You are not required to use this option because you can specify a torrent file without -T.
  1403. </p>
  1404. </dd>
  1405. </dl></div>
  1406. <h3 id="_metalink_specific_options">Metalink Specific Options</h3><div style="clear:left"></div>
  1407. <div class="dlist"><dl>
  1408. <dt class="hdlist1">
  1409. <strong>--follow-metalink</strong>=<em>true</em>|<em>false</em>|<em>mem</em>
  1410. </dt>
  1411. <dd>
  1412. <p>
  1413. If <em>true</em> or <em>mem</em> is specified, when a file whose suffix is ".metalink" or content
  1414. type of "application/metalink+xml" is downloaded, aria2 parses it as a metalink
  1415. file and downloads files mentioned in it.
  1416. If <em>mem</em> is specified, a metalink file is not written to the disk, but is just
  1417. kept in memory.
  1418. If <em>false</em> is specified, the action mentioned above is not taken.
  1419. Default: <em>true</em>
  1420. </p>
  1421. </dd>
  1422. <dt class="hdlist1">
  1423. <strong>-M</strong>, <strong>--metalink-file</strong>=METALINK_FILE
  1424. </dt>
  1425. <dd>
  1426. <p>
  1427. The file path to .metalink file. You are not required to use this option because you can
  1428. specify a metalink file without -M.
  1429. </p>
  1430. </dd>
  1431. <dt class="hdlist1">
  1432. <strong>-C</strong>, <strong>--metalink-servers</strong>=NUM_SERVERS
  1433. </dt>
  1434. <dd>
  1435. <p>
  1436. The number of servers to connect to simultaneously.
  1437. Some Metalinks regulate the number of servers to connect.
  1438. aria2 strictly respects them.
  1439. This means that if Metalink defines the maxconnections attribute lower
  1440. than NUM_SERVERS, then aria2 uses the value of maxconnections attribute
  1441. instead of NUM_SERVERS.
  1442. See also <strong>-s</strong> and <strong>-j</strong> options.
  1443. Default: <em>5</em>
  1444. </p>
  1445. </dd>
  1446. <dt class="hdlist1">
  1447. <strong>--metalink-language</strong>=LANGUAGE
  1448. </dt>
  1449. <dd>
  1450. <p>
  1451. The language of the file to download.
  1452. </p>
  1453. </dd>
  1454. <dt class="hdlist1">
  1455. <strong>--metalink-location</strong>=LOCATION[,&#8230;]
  1456. </dt>
  1457. <dd>
  1458. <p>
  1459. The location of the preferred server.
  1460. A comma-delimited list of locations is acceptable, for example, <em>JP,US</em>.
  1461. </p>
  1462. </dd>
  1463. <dt class="hdlist1">
  1464. <strong>--metalink-os</strong>=OS
  1465. </dt>
  1466. <dd>
  1467. <p>
  1468. The operating system of the file to download.
  1469. </p>
  1470. </dd>
  1471. <dt class="hdlist1">
  1472. <strong>--metalink-version</strong>=VERSION
  1473. </dt>
  1474. <dd>
  1475. <p>
  1476. The version of the file to download.
  1477. </p>
  1478. </dd>
  1479. <dt class="hdlist1">
  1480. <strong>--metalink-preferred-protocol</strong>=PROTO
  1481. </dt>
  1482. <dd>
  1483. <p>
  1484. Specify preferred protocol.
  1485. The possible values are <em>http</em>, <em>https</em>, <em>ftp</em> and <em>none</em>.
  1486. Specify <em>none</em> to disable this feature.
  1487. Default: <em>none</em>
  1488. </p>
  1489. </dd>
  1490. <dt class="hdlist1">
  1491. <strong>--metalink-enable-unique-protocol</strong>=<em>true</em>|<em>false</em>
  1492. </dt>
  1493. <dd>
  1494. <p>
  1495. If <em>true</em> is given and several protocols are available for a mirror in a
  1496. metalink file, aria2 uses one of them.
  1497. Use <strong>--metalink-preferred-protocol</strong> option to specify the preference of
  1498. protocol.
  1499. Default: <em>true</em>
  1500. </p>
  1501. </dd>
  1502. </dl></div>
  1503. <h3 id="_xml_rpc_options">XML-RPC Options</h3><div style="clear:left"></div>
  1504. <div class="dlist"><dl>
  1505. <dt class="hdlist1">
  1506. <strong>--enable-xml-rpc</strong>[=<em>true</em>|<em>false</em>]
  1507. </dt>
  1508. <dd>
  1509. <p>
  1510. Enable XML-RPC server. It is strongly recommended to set username
  1511. and password using <strong>--xml-rpc-user</strong> and <strong>--xml-rpc-passwd</strong>
  1512. option. See also <strong>--xml-rpc-listen-port</strong> option. Default: <em>false</em>
  1513. </p>
  1514. </dd>
  1515. <dt class="hdlist1">
  1516. <strong>--xml-rpc-listen-all</strong>[=<em>true</em>|<em>false</em>]
  1517. </dt>
  1518. <dd>
  1519. <p>
  1520. Listen incoming XML-RPC requests on all network interfaces. If false
  1521. is given, listen only on local loopback interface. Default: <em>false</em>
  1522. </p>
  1523. </dd>
  1524. <dt class="hdlist1">
  1525. <strong>--xml-rpc-listen-port</strong>=PORT
  1526. </dt>
  1527. <dd>
  1528. <p>
  1529. Specify a port number for XML-RPC server to listen to. Possible
  1530. Values: <em>1024</em>-<em>65535</em> Default: <em>6800</em>
  1531. </p>
  1532. </dd>
  1533. <dt class="hdlist1">
  1534. <strong>--xml-rpc-max-request-size</strong>=SIZE
  1535. </dt>
  1536. <dd>
  1537. <p>
  1538. Set max size of XML-RPC request. If aria2 detects the request is
  1539. more than SIZE bytes, it drops connection. Default: <em>2M</em>
  1540. </p>
  1541. </dd>
  1542. <dt class="hdlist1">
  1543. <strong>--xml-rpc-passwd</strong>=PASSWD
  1544. </dt>
  1545. <dd>
  1546. <p>
  1547. Set XML-RPC password.
  1548. </p>
  1549. </dd>
  1550. <dt class="hdlist1">
  1551. <strong>--xml-rpc-user</strong>=USER
  1552. </dt>
  1553. <dd>
  1554. <p>
  1555. Set XML-RPC user.
  1556. </p>
  1557. </dd>
  1558. </dl></div>
  1559. <h3 id="_advanced_options">Advanced Options</h3><div style="clear:left"></div>
  1560. <div class="dlist"><dl>
  1561. <dt class="hdlist1">
  1562. <strong>--allow-overwrite</strong>=<em>true</em>|<em>false</em>
  1563. </dt>
  1564. <dd>
  1565. <p>
  1566. If <em>false</em> is given, and a file already exists but the corresponding
  1567. control file (filename.aria2) doesn&#8217;t exist, then aria2 will not
  1568. re-download the file. See also <strong>--auto-file-renaming</strong> option.
  1569. Default: <em>false</em>
  1570. </p>
  1571. </dd>
  1572. <dt class="hdlist1">
  1573. <strong>--allow-piece-length-change</strong>=<em>true</em>|<em>false</em>
  1574. </dt>
  1575. <dd>
  1576. <p>
  1577. If false is given, aria2 aborts download when a piece length is different
  1578. from one in a control file.
  1579. If true is given, you can proceed but some download progress will be lost.
  1580. Default: <em>false</em>
  1581. </p>
  1582. </dd>
  1583. <dt class="hdlist1">
  1584. <strong>--async-dns</strong>[=<em>true</em>|<em>false</em>]
  1585. </dt>
  1586. <dd>
  1587. <p>
  1588. Enable asynchronous DNS.
  1589. Default: <em>true</em>
  1590. </p>
  1591. </dd>
  1592. <dt class="hdlist1">
  1593. <strong>--auto-file-renaming</strong>[=<em>true</em>|<em>false</em>]
  1594. </dt>
  1595. <dd>
  1596. <p>
  1597. Rename file name if the same file already exists.
  1598. This option works only in HTTP(S)/FTP download.
  1599. The new file name has a dot and a number(1..9999) appended.
  1600. Default: <em>true</em>
  1601. </p>
  1602. </dd>
  1603. <dt class="hdlist1">
  1604. <strong>--auto-save-interval</strong>=SEC
  1605. </dt>
  1606. <dd>
  1607. <p>
  1608. Save a control file(*.aria2) every SEC seconds.
  1609. If <em>0</em> is given, a control file is not saved during download. aria2 saves a
  1610. control file when it stops regardless of the value.
  1611. The possible values are between <em>0</em> to <em>600</em>.
  1612. Default: <em>60</em>
  1613. </p>
  1614. </dd>
  1615. <dt class="hdlist1">
  1616. <strong>--conf-path</strong>=PATH
  1617. </dt>
  1618. <dd>
  1619. <p>
  1620. Change the configuration file path to PATH.
  1621. Default: <em>$HOME/.aria2/aria2.conf</em>
  1622. </p>
  1623. </dd>
  1624. <dt class="hdlist1">
  1625. <strong>-D</strong>, <strong>--daemon</strong>
  1626. </dt>
  1627. <dd>
  1628. <p>
  1629. Run as daemon. The current working directory will be changed to <em>/</em>
  1630. and standard input, standard output and standard error will be
  1631. redirected to <em>/dev/null</em>. Default: <em>false</em>
  1632. </p>
  1633. </dd>
  1634. <dt class="hdlist1">
  1635. <strong>--enable-direct-io</strong>[=<em>true</em>|<em>false</em>]
  1636. </dt>
  1637. <dd>
  1638. <p>
  1639. Enable directI/O, which lowers cpu usage while allocating/checking files.
  1640. Turn off if you encounter any error.
  1641. Default: <em>true</em>
  1642. </p>
  1643. </dd>
  1644. <dt class="hdlist1">
  1645. <strong>--event-poll</strong>=POLL
  1646. </dt>
  1647. <dd>
  1648. <p>
  1649. Specify the method for polling events. The possible Values are
  1650. <em>epoll</em> and <em>select</em>. If you use recent Linux that has epoll, then
  1651. the default value is <em>epoll</em>. Otherwise, the default value is
  1652. <em>select</em>.
  1653. </p>
  1654. </dd>
  1655. <dt class="hdlist1">
  1656. <strong>--file-allocation</strong>=METHOD
  1657. </dt>
  1658. <dd>
  1659. <p>
  1660. Specify file allocation method.
  1661. <em>none</em> doesn&#8217;t pre-allocate file space. <em>prealloc</em> pre-allocates file space
  1662. before download begins. This may take some time depending on the size of the
  1663. file.
  1664. If you are using newer file systems such as ext4
  1665. (with extents support), btrfs or xfs, <em>falloc</em> is
  1666. your best choice. It allocates large(few GiB)
  1667. files almost instantly. Don&#8217;t use <em>falloc</em> with
  1668. legacy file systems such as ext3 because it takes
  1669. almost same time as <em>prealloc</em> and it blocks aria2
  1670. entirely until allocation finishes. <em>falloc</em> may
  1671. not be available if your system doesn&#8217;t have
  1672. <strong>posix_fallocate</strong>() function.
  1673. Possible Values: <em>none</em>, <em>prealloc</em>, <em>falloc</em>
  1674. Default: <em>prealloc</em>
  1675. </p>
  1676. </dd>
  1677. <dt class="hdlist1">
  1678. <strong>--log-level</strong>=LEVEL
  1679. </dt>
  1680. <dd>
  1681. <p>
  1682. Set log level to output.
  1683. LEVEL is either <em>debug</em>, <em>info</em>, <em>notice</em>, <em>warn</em> or <em>error</em>.
  1684. Default: <em>debug</em>
  1685. </p>
  1686. </dd>
  1687. <dt class="hdlist1">
  1688. <strong>--on-download-complete</strong>=COMMAND
  1689. </dt>
  1690. <dd>
  1691. <p>
  1692. Set the command to be executed when download completes. See
  1693. <strong>--on-download-start</strong> option for the requirement of COMMAND. See
  1694. also <strong>--on-download-stop</strong> option. Possible Values:
  1695. <em>/path/to/command</em>
  1696. </p>
  1697. </dd>
  1698. <dt class="hdlist1">
  1699. <strong>--on-download-error</strong>=COMMAND
  1700. </dt>
  1701. <dd>
  1702. <p>
  1703. Set the command to be executed when download aborts due to error.
  1704. See <strong>--on-download-start</strong> option for the requirement of COMMAND.
  1705. See also <strong>--on-download-stop</strong> option. Possible Values:
  1706. <em>/path/to/command</em>
  1707. </p>
  1708. </dd>
  1709. <dt class="hdlist1">
  1710. <strong>--on-download-start</strong>=COMMAND
  1711. </dt>
  1712. <dd>
  1713. <p>
  1714. Set the command to be executed when download starts up. COMMAND must
  1715. take just one argument and GID is passed to COMMAND as a first
  1716. argument. Possible Values: <em>/path/to/command</em>
  1717. </p>
  1718. </dd>
  1719. <dt class="hdlist1">
  1720. <strong>--on-download-stop</strong>=COMMAND
  1721. </dt>
  1722. <dd>
  1723. <p>
  1724. Set the command to be executed when download stops. You can override
  1725. the command to be executed for particular download result using
  1726. <strong>--on-download-complete</strong> and <strong>--on-download-error</strong>. If they are
  1727. specified, command specified in this option is not executed. See
  1728. <strong>--on-download-start</strong> option for the requirement of COMMAND.
  1729. Possible Values: <em>/path/to/command</em>
  1730. </p>
  1731. </dd>
  1732. <dt class="hdlist1">
  1733. <strong>--summary-interval</strong>=SEC
  1734. </dt>
  1735. <dd>
  1736. <p>
  1737. Set interval in seconds to output download progress summary.
  1738. Setting <em>0</em> suppresses the output.
  1739. Default: <em>60</em>
  1740. </p>
  1741. </dd>
  1742. </dl></div>
  1743. <div class="admonitionblock">
  1744. <table><tr>
  1745. <td class="icon">
  1746. <div class="title">Note</div>
  1747. </td>
  1748. <td class="content">In multi file torrent downloads, the files adjacent forward to the specified files
  1749. are also allocated if they share the same piece.</td>
  1750. </tr></table>
  1751. </div>
  1752. <div class="dlist"><dl>
  1753. <dt class="hdlist1">
  1754. <strong>-Z</strong>, <strong>--force-sequential</strong>[=<em>true</em>|<em>false</em>]
  1755. </dt>
  1756. <dd>
  1757. <p>
  1758. Fetch URIs in the command-line sequentially and download each URI in a
  1759. separate session, like the usual command-line download utilities.
  1760. Default: <em>false</em>
  1761. </p>
  1762. </dd>
  1763. <dt class="hdlist1">
  1764. <strong>--max-overall-download-limit</strong>=SPEED
  1765. </dt>
  1766. <dd>
  1767. <p>
  1768. Set max overall download speed in bytes/sec. <em>0</em> means
  1769. unrestricted. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K). To
  1770. limit the download speed per download, use <strong>--max-download-limit</strong>
  1771. option. Default: <em>0</em>
  1772. </p>
  1773. </dd>
  1774. <dt class="hdlist1">
  1775. <strong>--max-download-limit</strong>=SPEED
  1776. </dt>
  1777. <dd>
  1778. <p>
  1779. Set max download speed per each download in bytes/sec. <em>0</em> means
  1780. unrestricted. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K). To
  1781. limit the overall download speed, use <strong>--max-overall-download-limit</strong>
  1782. option. Default: <em>0</em>
  1783. </p>
  1784. </dd>
  1785. <dt class="hdlist1">
  1786. <strong>--no-conf</strong>
  1787. </dt>
  1788. <dd>
  1789. <p>
  1790. Disable loading aria2.conf file.
  1791. </p>
  1792. </dd>
  1793. <dt class="hdlist1">
  1794. <strong>--no-file-allocation-limit</strong>=SIZE
  1795. </dt>
  1796. <dd>
  1797. <p>
  1798. No file allocation is made for files whose size is smaller than SIZE.
  1799. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1800. Default: <em>5M</em>
  1801. </p>
  1802. </dd>
  1803. <dt class="hdlist1">
  1804. <strong>-P</strong>, <strong>--parameterized-uri</strong>[=<em>true</em>|<em>false</em>]
  1805. </dt>
  1806. <dd>
  1807. <p>
  1808. Enable parameterized URI support.
  1809. You can specify set of parts: <em>http://{sv1,sv2,sv3}/foo.iso</em>.
  1810. Also you can specify numeric sequences with step counter:
  1811. <em>http://host/image[000-100:2].img</em>.
  1812. A step counter can be omitted.
  1813. If all URIs do not point to the same file, such as the second example above,
  1814. -Z option is required.
  1815. Default: <em>false</em>
  1816. </p>
  1817. </dd>
  1818. <dt class="hdlist1">
  1819. <strong>-q</strong>, <strong>--quiet</strong>[=<em>true</em>|<em>false</em>]
  1820. </dt>
  1821. <dd>
  1822. <p>
  1823. Make aria2 quiet (no console output).
  1824. Default: <em>false</em>
  1825. </p>
  1826. </dd>
  1827. <dt class="hdlist1">
  1828. <strong>--realtime-chunk-checksum</strong>=<em>true</em>|<em>false</em>
  1829. </dt>
  1830. <dd>
  1831. <p>
  1832. Validate chunk of data by calculating checksum while downloading a file if
  1833. chunk checksums are provided.
  1834. Default: <em>true</em>
  1835. </p>
  1836. </dd>
  1837. <dt class="hdlist1">
  1838. <strong>--stop</strong>=SEC
  1839. </dt>
  1840. <dd>
  1841. <p>
  1842. Stop application after SEC seconds has passed.
  1843. If <em>0</em> is given, this feature is disabled.
  1844. Default: <em>0</em>
  1845. </p>
  1846. </dd>
  1847. <dt class="hdlist1">
  1848. <strong>-v</strong>, <strong>--version</strong>
  1849. </dt>
  1850. <dd>
  1851. <p>
  1852. Print the version number, copyright and the configuration information and
  1853. exit.
  1854. </p>
  1855. </dd>
  1856. </dl></div>
  1857. <h3 id="_options_that_take_an_optional_argument">Options That Take An Optional Argument</h3><div style="clear:left"></div>
  1858. <div class="paragraph"><p>The options that have its argument surrounded by square brackets([])
  1859. take an optional argument. Usually omiting the argument is evaluated to <em>true</em>.
  1860. If you use short form of these options(such as <em>-V</em>) and give
  1861. an argument, then the option name and its argument should be concatenated(e.g.
  1862. <em>-Vfalse</em>). If any spaces are inserted between the option name and the argument,
  1863. the argument will be treated as URI and usually this is not what you expect.</p></div>
  1864. <h3 id="_uri_magnet_torrent_file_metalink_file">URI, MAGNET, TORRENT_FILE, METALINK_FILE</h3><div style="clear:left"></div>
  1865. <div class="paragraph"><p>You can specify multiple URLs in command-line. Unless you specify
  1866. <strong>-Z</strong> option, all URLs must point to the same file or downloading will
  1867. fail.</p></div>
  1868. <div class="paragraph"><p>You can specify arbitrary number of BitTorrent Magnet URI. Please note
  1869. that they are always treated as a separate download. Both hex encoded
  1870. 40 characters Info Hash and Base32 encoded 32 characters Info Hash are
  1871. supported. The multiple "tr" paramters are supported. Because
  1872. BitTorrent Magnet URI is likely to contain "&amp;" character, it is highly
  1873. recommended to always quote URI with single(') or double(") quotation.
  1874. See <a href="http://www.bittorrent.org/beps/bep_0009.html">http://www.bittorrent.org/beps/bep_0009.html</a> for more details
  1875. about BitTorrent Magnet URI.</p></div>
  1876. <div class="paragraph"><p>You can also specify arbitrary number of torrent files and metalink files
  1877. stored on a local drive. Please note that they are always treated as a
  1878. separate download.</p></div>
  1879. <div class="paragraph"><p>You can specify both torrent file with -T option and URLs. By doing
  1880. this, you can download a file from both torrent swarm and HTTP(S)/FTP
  1881. server at the same time, while the data from HTTP(S)/FTP are uploaded
  1882. to the torrent swarm. For single file torrents, URL can be a complete
  1883. URL pointing to the resource or if URL ends with /, name in torrent
  1884. file in torrent is added. For multi-file torrents, name and path are
  1885. added to form a URL for each file.</p></div>
  1886. <div class="admonitionblock">
  1887. <table><tr>
  1888. <td class="icon">
  1889. <div class="title">Note</div>
  1890. </td>
  1891. <td class="content">Make sure that URL is quoted with single(') or double(") quotation if it
  1892. contains "&amp;" or any characters that have special meaning in shell.</td>
  1893. </tr></table>
  1894. </div>
  1895. <h3 id="_resuming_download">Resuming Download</h3><div style="clear:left"></div>
  1896. <div class="paragraph"><p>Usually, you can resume transfer by just issuing same command(aria2c
  1897. URL) if the previous transfer is made by aria2.</p></div>
  1898. <div class="paragraph"><p>If the previous transfer is made by a browser or wget like sequential
  1899. download manager, then use -c option to continue the transfer(aria2c
  1900. <strong>-c</strong> URL).</p></div>
  1901. </div>
  1902. <h2 id="_exit_status">EXIT STATUS</h2>
  1903. <div class="sectionbody">
  1904. <div class="paragraph"><p>Because aria2 can handle multiple downloads at once, it encounters
  1905. lots of errors in a session. aria2 returns the following exit status
  1906. based on the last error encountered.</p></div>
  1907. <div class="dlist"><dl>
  1908. <dt class="hdlist1">
  1909. <strong>0</strong>
  1910. </dt>
  1911. <dd>
  1912. <p>
  1913. If all downloads are successful.
  1914. </p>
  1915. </dd>
  1916. <dt class="hdlist1">
  1917. <strong>1</strong>
  1918. </dt>
  1919. <dd>
  1920. <p>
  1921. If an unknown error occurs.
  1922. </p>
  1923. </dd>
  1924. <dt class="hdlist1">
  1925. <strong>2</strong>
  1926. </dt>
  1927. <dd>
  1928. <p>
  1929. If time out occurs.
  1930. </p>
  1931. </dd>
  1932. <dt class="hdlist1">
  1933. <strong>3</strong>
  1934. </dt>
  1935. <dd>
  1936. <p>
  1937. If a resource is not found.
  1938. </p>
  1939. </dd>
  1940. <dt class="hdlist1">
  1941. <strong>4</strong>
  1942. </dt>
  1943. <dd>
  1944. <p>
  1945. If aria2 sees the specfied number of "resource not found" error.
  1946. See <strong>--max-file-not-found</strong> option).
  1947. </p>
  1948. </dd>
  1949. <dt class="hdlist1">
  1950. <strong>5</strong>
  1951. </dt>
  1952. <dd>
  1953. <p>
  1954. If a download aborts because download speed is too slow.
  1955. See <strong>--lowest-speed-limit</strong> option)
  1956. </p>
  1957. </dd>
  1958. <dt class="hdlist1">
  1959. <strong>6</strong>
  1960. </dt>
  1961. <dd>
  1962. <p>
  1963. If network problem occurs.
  1964. </p>
  1965. </dd>
  1966. <dt class="hdlist1">
  1967. <strong>7</strong>
  1968. </dt>
  1969. <dd>
  1970. <p>
  1971. If there are unfinished downloads. This error is only reported if
  1972. all finished downloads are successful and there are unfinished
  1973. downloads in a queue when aria2 exits by pressing Ctrl-C by an user
  1974. or sending TERM or INT signal.
  1975. </p>
  1976. </dd>
  1977. </dl></div>
  1978. <div class="admonitionblock">
  1979. <table><tr>
  1980. <td class="icon">
  1981. <div class="title">Note</div>
  1982. </td>
  1983. <td class="content">An error occurred in a finished download will not be reported
  1984. as exit status.</td>
  1985. </tr></table>
  1986. </div>
  1987. </div>
  1988. <h2 id="_environment">ENVIRONMENT</h2>
  1989. <div class="sectionbody">
  1990. <div class="paragraph"><p>aria2 recognizes the following environment variables.</p></div>
  1991. <div class="dlist"><dl>
  1992. <dt class="hdlist1">
  1993. http_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  1994. </dt>
  1995. <dd>
  1996. <p>
  1997. Specify proxy server for use in HTTP.
  1998. Overrides http-proxy value in configuration file.
  1999. The command-line option <strong>--http-proxy</strong> overrides this value.
  2000. </p>
  2001. </dd>
  2002. <dt class="hdlist1">
  2003. https_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2004. </dt>
  2005. <dd>
  2006. <p>
  2007. Specify proxy server for use in HTTPS.
  2008. Overrides https-proxy value in configuration file.
  2009. The command-line option <strong>--https-proxy</strong> overrides this value.
  2010. </p>
  2011. </dd>
  2012. <dt class="hdlist1">
  2013. ftp_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2014. </dt>
  2015. <dd>
  2016. <p>
  2017. Specify proxy server for use in FTP.
  2018. Overrides ftp-proxy value in configuration file.
  2019. The command-line option <strong>--ftp-proxy</strong> overrides this value.
  2020. </p>
  2021. </dd>
  2022. <dt class="hdlist1">
  2023. all_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2024. </dt>
  2025. <dd>
  2026. <p>
  2027. Specify proxy server for use if no protocol-specific proxy is specified.
  2028. Overrides all-proxy value in configuration file.
  2029. The command-line option <strong>--all-proxy</strong> overrides this value.
  2030. </p>
  2031. </dd>
  2032. <dt class="hdlist1">
  2033. no_proxy [DOMAIN,&#8230;]
  2034. </dt>
  2035. <dd>
  2036. <p>
  2037. Specify comma-separated hostname or domains to which proxy should not be used.
  2038. Overrides no-proxy value in configuration file.
  2039. The command-line option <strong>--no-proxy</strong> overrides this value.
  2040. </p>
  2041. </dd>
  2042. </dl></div>
  2043. </div>
  2044. <h2 id="_files">FILES</h2>
  2045. <div class="sectionbody">
  2046. <h3 id="_aria2_conf">aria2.conf</h3><div style="clear:left"></div>
  2047. <div class="paragraph"><p>By default, aria2 parses <em>$HOME/.aria2/aria2.conf</em> as a configuraiton
  2048. file. You can specify the path to configuration file using
  2049. <strong>--conf-path</strong> option. If you don&#8217;t want to use the configuraitonf
  2050. file, use <strong>--no-conf</strong> option.</p></div>
  2051. <div class="paragraph"><p>The configuration file is a text file and has 1 option per each
  2052. line. In each line, you can specify name-value pair in the format:
  2053. NAME=VALUE, where name is the long command-line option name without
  2054. "--" prefix. You can use same syntax for the command-line option. The
  2055. lines beginning "#" are treated as comments.</p></div>
  2056. <div class="listingblock">
  2057. <div class="content">
  2058. <pre><tt># sample configuration file for aria2c
  2059. listen-port=60000
  2060. dht-listen-port=60000
  2061. seed-ratio=1.0
  2062. max-upload-limit=50K
  2063. ftp-pasv=true</tt></pre>
  2064. </div></div>
  2065. <h3 id="_dht_dat">dht.dat</h3><div style="clear:left"></div>
  2066. <div class="paragraph"><p>By default, the routing table of DHT is saved to the path $HOME/.aria2/dht.dat.</p></div>
  2067. <h3 id="_control_file">Control File</h3><div style="clear:left"></div>
  2068. <div class="paragraph"><p>aria2 uses a control file to track the progress of a download. A
  2069. control file is placed in the same directory as the downloading file
  2070. and its filename is the filename of downloading file with ".aria2"
  2071. appended. For example, if you are downloading file.zip, then the
  2072. control file should be file.zip.aria2. (There is a exception for this
  2073. naming convention. If you are downloading a multi torrent, its
  2074. control file is the "top directory" name of the torrent with ".aria2"
  2075. appended. The "top directory" name is a value of "name" key in "info"
  2076. directory in a torrent file.)</p></div>
  2077. <div class="paragraph"><p>Usually a control file is deleted once download completed. If aria2
  2078. decides that download cannot be resumed(for example, when downloading
  2079. a file from a HTTP server which doesn&#8217;t support resume), a control
  2080. file is not created.</p></div>
  2081. <div class="paragraph"><p>Normally if you lose a control file, you cannot resume download. But
  2082. if you have a torrent or metalink with chunk checksums for the file,
  2083. you can resume the download without a control file by giving -V option
  2084. to aria2c in command-line.</p></div>
  2085. <h3 id="_input_file">Input File</h3><div style="clear:left"></div>
  2086. <div class="paragraph"><p>The input file can contain a list of URIs for aria2 to download. You
  2087. can specify multiple URIs for a single entity: separate URIs on a
  2088. single line using the TAB character.</p></div>
  2089. <div class="paragraph"><p>Each line is treated as if it is provided in command-line argument.
  2090. Therefore they are affected by <strong>-Z</strong> and <strong>-P</strong> options.</p></div>
  2091. <div class="paragraph"><p>Additionally, the following options can be specified after each line
  2092. of URIs. These optional lines must start with white space(s).</p></div>
  2093. <div class="ulist"><ul>
  2094. <li>
  2095. <p>
  2096. dir
  2097. </p>
  2098. </li>
  2099. <li>
  2100. <p>
  2101. check-integrity
  2102. </p>
  2103. </li>
  2104. <li>
  2105. <p>
  2106. continue
  2107. </p>
  2108. </li>
  2109. <li>
  2110. <p>
  2111. all-proxy
  2112. </p>
  2113. </li>
  2114. <li>
  2115. <p>
  2116. connect-timeout
  2117. </p>
  2118. </li>
  2119. <li>
  2120. <p>
  2121. dry-run
  2122. </p>
  2123. </li>
  2124. <li>
  2125. <p>
  2126. lowest-speed-limit
  2127. </p>
  2128. </li>
  2129. <li>
  2130. <p>
  2131. max-file-not-found
  2132. </p>
  2133. </li>
  2134. <li>
  2135. <p>
  2136. max-tries
  2137. </p>
  2138. </li>
  2139. <li>
  2140. <p>
  2141. no-proxy
  2142. </p>
  2143. </li>
  2144. <li>
  2145. <p>
  2146. out
  2147. </p>
  2148. </li>
  2149. <li>
  2150. <p>
  2151. proxy-method
  2152. </p>
  2153. </li>
  2154. <li>
  2155. <p>
  2156. remote-time
  2157. </p>
  2158. </li>
  2159. <li>
  2160. <p>
  2161. split
  2162. </p>
  2163. </li>
  2164. <li>
  2165. <p>
  2166. timeout
  2167. </p>
  2168. </li>
  2169. <li>
  2170. <p>
  2171. http-auth-challenge
  2172. </p>
  2173. </li>
  2174. <li>
  2175. <p>
  2176. http-user
  2177. </p>
  2178. </li>
  2179. <li>
  2180. <p>
  2181. http-passwd
  2182. </p>
  2183. </li>
  2184. <li>
  2185. <p>
  2186. http-proxy
  2187. </p>
  2188. </li>
  2189. <li>
  2190. <p>
  2191. https-proxy
  2192. </p>
  2193. </li>
  2194. <li>
  2195. <p>
  2196. referer
  2197. </p>
  2198. </li>
  2199. <li>
  2200. <p>
  2201. enable-http-keep-alive
  2202. </p>
  2203. </li>
  2204. <li>
  2205. <p>
  2206. enable-http-pipelining
  2207. </p>
  2208. </li>
  2209. <li>
  2210. <p>
  2211. header
  2212. </p>
  2213. </li>
  2214. <li>
  2215. <p>
  2216. use-head
  2217. </p>
  2218. </li>
  2219. <li>
  2220. <p>
  2221. user-agent
  2222. </p>
  2223. </li>
  2224. <li>
  2225. <p>
  2226. ftp-user
  2227. </p>
  2228. </li>
  2229. <li>
  2230. <p>
  2231. ftp-passwd
  2232. </p>
  2233. </li>
  2234. <li>
  2235. <p>
  2236. ftp-pasv
  2237. </p>
  2238. </li>
  2239. <li>
  2240. <p>
  2241. ftp-proxy
  2242. </p>
  2243. </li>
  2244. <li>
  2245. <p>
  2246. ftp-type
  2247. </p>
  2248. </li>
  2249. <li>
  2250. <p>
  2251. ftp-reuse-connection
  2252. </p>
  2253. </li>
  2254. <li>
  2255. <p>
  2256. no-netrc
  2257. </p>
  2258. </li>
  2259. <li>
  2260. <p>
  2261. select-file
  2262. </p>
  2263. </li>
  2264. <li>
  2265. <p>
  2266. bt-external-ip
  2267. </p>
  2268. </li>
  2269. <li>
  2270. <p>
  2271. bt-hash-check-seed
  2272. </p>
  2273. </li>
  2274. <li>
  2275. <p>
  2276. bt-max-open-files
  2277. </p>
  2278. </li>
  2279. <li>
  2280. <p>
  2281. bt-max-peers
  2282. </p>
  2283. </li>
  2284. <li>
  2285. <p>
  2286. bt-min-crypto-level
  2287. </p>
  2288. </li>
  2289. <li>
  2290. <p>
  2291. bt-require-crypto
  2292. </p>
  2293. </li>
  2294. <li>
  2295. <p>
  2296. bt-request-peer-speed-limit
  2297. </p>
  2298. </li>
  2299. <li>
  2300. <p>
  2301. bt-seed-unverified
  2302. </p>
  2303. </li>
  2304. <li>
  2305. <p>
  2306. bt-stop-timeout
  2307. </p>
  2308. </li>
  2309. <li>
  2310. <p>
  2311. bt-tracker-interval
  2312. </p>
  2313. </li>
  2314. <li>
  2315. <p>
  2316. enable-peer-exchange
  2317. </p>
  2318. </li>
  2319. <li>
  2320. <p>
  2321. follow-torrent
  2322. </p>
  2323. </li>
  2324. <li>
  2325. <p>
  2326. index-out
  2327. </p>
  2328. </li>
  2329. <li>
  2330. <p>
  2331. max-upload-limit
  2332. </p>
  2333. </li>
  2334. <li>
  2335. <p>
  2336. seed-ratio
  2337. </p>
  2338. </li>
  2339. <li>
  2340. <p>
  2341. seed-time
  2342. </p>
  2343. </li>
  2344. <li>
  2345. <p>
  2346. follow-metalink
  2347. </p>
  2348. </li>
  2349. <li>
  2350. <p>
  2351. metalink-servers
  2352. </p>
  2353. </li>
  2354. <li>
  2355. <p>
  2356. metalink-language
  2357. </p>
  2358. </li>
  2359. <li>
  2360. <p>
  2361. metalink-location
  2362. </p>
  2363. </li>
  2364. <li>
  2365. <p>
  2366. metalink-os
  2367. </p>
  2368. </li>
  2369. <li>
  2370. <p>
  2371. metalink-version
  2372. </p>
  2373. </li>
  2374. <li>
  2375. <p>
  2376. metalink-preferred-protocol
  2377. </p>
  2378. </li>
  2379. <li>
  2380. <p>
  2381. metalink-enable-unique-protocol
  2382. </p>
  2383. </li>
  2384. <li>
  2385. <p>
  2386. allow-overwrite
  2387. </p>
  2388. </li>
  2389. <li>
  2390. <p>
  2391. allow-piece-length-change
  2392. </p>
  2393. </li>
  2394. <li>
  2395. <p>
  2396. async-dns
  2397. </p>
  2398. </li>
  2399. <li>
  2400. <p>
  2401. auto-file-renaming
  2402. </p>
  2403. </li>
  2404. <li>
  2405. <p>
  2406. file-allocation
  2407. </p>
  2408. </li>
  2409. <li>
  2410. <p>
  2411. max-download-limit
  2412. </p>
  2413. </li>
  2414. <li>
  2415. <p>
  2416. no-file-allocation-limit
  2417. </p>
  2418. </li>
  2419. <li>
  2420. <p>
  2421. parameterized-uri
  2422. </p>
  2423. </li>
  2424. <li>
  2425. <p>
  2426. realtime-chunk-checksum
  2427. </p>
  2428. </li>
  2429. </ul></div>
  2430. <div class="paragraph"><p>These options have exactly same meaning of the ones in the
  2431. command-line options, but it just applies to the URIs it belongs to.</p></div>
  2432. <div class="paragraph"><p>For example, the content of uri.txt is</p></div>
  2433. <div class="listingblock">
  2434. <div class="content">
  2435. <pre><tt>http://server/file.iso http://mirror/file.iso
  2436. dir=/iso_images
  2437. out=file.img
  2438. http://foo/bar</tt></pre>
  2439. </div></div>
  2440. <div class="paragraph"><p>If aria2 is executed with <strong>-i</strong> uri.txt <strong>-d</strong> /tmp options, then
  2441. <em>file.iso</em> is saved as <em>/iso_images/file.img</em> and it is downloaded
  2442. from http://server/file.iso and http://mirror/file.iso. The file
  2443. <em>bar</em> is downloaded from http://foo/bar and saved as <em>/tmp/bar</em>.</p></div>
  2444. <div class="paragraph"><p>In some cases, <strong>out</strong> parameter has no effect. See note of <strong>--out</strong>
  2445. option for the restrictions.</p></div>
  2446. <h3 id="_server_performance_profile">Server Performance Profile</h3><div style="clear:left"></div>
  2447. <div class="paragraph"><p>This section describes the format of server performance profile. The
  2448. file is plain text and each line has several NAME=VALUE pair,
  2449. delimited by comma. Currently following NAMEs are recognized:</p></div>
  2450. <div class="dlist"><dl>
  2451. <dt class="hdlist1">
  2452. host
  2453. </dt>
  2454. <dd>
  2455. <p>
  2456. Hostname of the server. Required.
  2457. </p>
  2458. </dd>
  2459. <dt class="hdlist1">
  2460. protocol
  2461. </dt>
  2462. <dd>
  2463. <p>
  2464. Protocol for this profile, such as ftp, http. Required.
  2465. </p>
  2466. </dd>
  2467. <dt class="hdlist1">
  2468. dl_speed
  2469. </dt>
  2470. <dd>
  2471. <p>
  2472. The average download speed observed in the previous download in
  2473. bytes per sec. Required.
  2474. </p>
  2475. </dd>
  2476. <dt class="hdlist1">
  2477. sc_avg_speed
  2478. </dt>
  2479. <dd>
  2480. <p>
  2481. The average download speed observed in the previous download in
  2482. bytes per sec. This value is only updated if the download is done in
  2483. single connection environment and only used by
  2484. AdaptiveURISelector. Optional.
  2485. </p>
  2486. </dd>
  2487. <dt class="hdlist1">
  2488. mc_avg_speed
  2489. </dt>
  2490. <dd>
  2491. <p>
  2492. The average download speed observed in the previous download in
  2493. bytes per sec. This value is only updated if the download is done in
  2494. multi connection environment and only used by
  2495. AdaptiveURISelector. Optional.
  2496. </p>
  2497. </dd>
  2498. <dt class="hdlist1">
  2499. counter
  2500. </dt>
  2501. <dd>
  2502. <p>
  2503. How many times the server is used. Currently this value is only used
  2504. by AdaptiveURISelector. Optional.
  2505. </p>
  2506. </dd>
  2507. <dt class="hdlist1">
  2508. last_updated
  2509. </dt>
  2510. <dd>
  2511. <p>
  2512. Last contact time in GMT with this server, specified in the seconds
  2513. from the Epoch. Required.
  2514. </p>
  2515. </dd>
  2516. <dt class="hdlist1">
  2517. status
  2518. </dt>
  2519. <dd>
  2520. <p>
  2521. ERROR is set when server cannot be reached or out-of-service or
  2522. timeout occurred. Otherwise, OK is set.
  2523. </p>
  2524. </dd>
  2525. </dl></div>
  2526. <div class="paragraph"><p>Those fields must exist in one line. The order of the fields is not
  2527. significant. You can put pairs other than the above; they are simply
  2528. ignored.</p></div>
  2529. <div class="paragraph"><p>An example follows:</p></div>
  2530. <div class="listingblock">
  2531. <div class="content">
  2532. <pre><tt>host=localhost, protocol=http, dl_speed=32000, last_updated=1222491640, status=OK
  2533. host=localhost, protocol=ftp, dl_speed=0, last_updated=1222491632, status=ERROR</tt></pre>
  2534. </div></div>
  2535. </div>
  2536. <h2 id="_xml_rpc_interface">XML-RPC INTERFACE</h2>
  2537. <div class="sectionbody">
  2538. <h3 id="_terminology">Terminology</h3><div style="clear:left"></div>
  2539. <div class="dlist"><dl>
  2540. <dt class="hdlist1">
  2541. GID
  2542. </dt>
  2543. <dd>
  2544. <p>
  2545. GID(or gid) is the key to manage each download. Each download has an
  2546. unique GID. Currently GID looks like an integer, but don&#8217;t treat it
  2547. as integer because it may be changed to another type in the future
  2548. release.
  2549. </p>
  2550. </dd>
  2551. </dl></div>
  2552. <h3 id="_methods">Methods</h3><div style="clear:left"></div>
  2553. <div class="paragraph"><p><strong>aria2.addUri</strong> <em>uris[, options[, position]]</em></p></div>
  2554. <div class="paragraph"><p>This method adds new HTTP(S)/FTP/BitTorrent Magnet URI with this
  2555. method. <em>uris</em> is of type array and its element is URI which is of
  2556. type string. For BitTorrent Magnet URI, <em>uris</em> must have one element
  2557. only and it should be BitTorrent Magnet URI. <em>options</em> is of type
  2558. struct and its members are a pair of option name and value. See
  2559. <strong>Options</strong> below for more details. If <em>position</em> is given as an
  2560. integer starting from 0, the new download is inserted at <em>position</em> in
  2561. the waiting queue. If <em>position</em> is not given or <em>position</em> is larger
  2562. than the size of the queue, it is appended at the end of the queue.
  2563. This method returns GID of registered download.</p></div>
  2564. <div class="paragraph"><p><strong>aria2.addTorrent</strong> <em>torrent[, uris[, options[, position]]]</em></p></div>
  2565. <div class="paragraph"><p>This method adds BitTorrent download by uploading .torrent file.
  2566. <em>torrent</em> is of type base64 which contains Base64-encoded .torrent
  2567. file. <em>uris</em> is of type array and its element is URI which is of type
  2568. string. <em>uris</em> is used for Web-seeding. For single file torrents, URI
  2569. can be a complete URI pointing to the resource or if URI ends with /,
  2570. name in torrent file is added. For multi-file torrents, name and path
  2571. in torrent are added to form a URI for each file. <em>options</em> is of
  2572. type struct and its members are a pair of option name and value. See
  2573. <strong>Options</strong> below for more details. If <em>position</em> is given as an
  2574. integer starting from 0, the new download is inserted at <em>position</em> in
  2575. the waiting queue. If <em>position</em> is not given or <em>position</em> is larger
  2576. than the size of the queue, it is appended at the end of the queue.
  2577. This method returns GID of registered download.</p></div>
  2578. <div class="paragraph"><p><strong>aria2.addMetalink</strong> <em>metalink[, options[, position]]</em></p></div>
  2579. <div class="paragraph"><p>This method adds Metalink download by uploading .metalink file.
  2580. <em>metalink</em> is of type base64 which contains Base64-encoded .metalink
  2581. file. <em>options</em> is of type struct and its members are a pair of
  2582. option name and value. See <strong>Options</strong> below for more details. If
  2583. <em>position</em> is given as an integer starting from 0, the new download is
  2584. inserted at <em>position</em> in the waiting queue. If <em>position</em> is not
  2585. given or <em>position</em> is larger than the size of the queue, it is
  2586. appended at the end of the queue. This method returns array of GID of
  2587. registered download.</p></div>
  2588. <div class="paragraph"><p><strong>aria2.remove</strong> <em>gid</em></p></div>
  2589. <div class="paragraph"><p>This method removes the download denoted by <em>gid</em>. <em>gid</em> is of type
  2590. string. If specified download is in progress, it is stopped at
  2591. first. The status of removed download becomes "removed". This method
  2592. returns GID of removed download.</p></div>
  2593. <div class="paragraph"><p><strong>aria2.tellStatus</strong> <em>gid</em></p></div>
  2594. <div class="paragraph"><p>This method returns download progress of the download denoted by
  2595. <em>gid</em>. <em>gid</em> is of type string. The response is of type struct and it
  2596. contains following keys. The value type is string.</p></div>
  2597. <div class="dlist"><dl>
  2598. <dt class="hdlist1">
  2599. gid
  2600. </dt>
  2601. <dd>
  2602. <p>
  2603. GID of this download.
  2604. </p>
  2605. </dd>
  2606. <dt class="hdlist1">
  2607. status
  2608. </dt>
  2609. <dd>
  2610. <p>
  2611. "active" for currently downloading/seeding entry. "waiting" for the
  2612. entry in the queue; download is not started. "error" for the stopped
  2613. download because of error. "complete" for the stopped and completed
  2614. download. "removed" for the download removed by user.
  2615. </p>
  2616. </dd>
  2617. <dt class="hdlist1">
  2618. totalLength
  2619. </dt>
  2620. <dd>
  2621. <p>
  2622. Total length of this download in bytes.
  2623. </p>
  2624. </dd>
  2625. <dt class="hdlist1">
  2626. completedLength
  2627. </dt>
  2628. <dd>
  2629. <p>
  2630. Completed length of this download in bytes.
  2631. </p>
  2632. </dd>
  2633. <dt class="hdlist1">
  2634. uploadLength
  2635. </dt>
  2636. <dd>
  2637. <p>
  2638. Uploaded length of this download in bytes.
  2639. </p>
  2640. </dd>
  2641. <dt class="hdlist1">
  2642. bitfield
  2643. </dt>
  2644. <dd>
  2645. <p>
  2646. Hexadecimal representation of the download progress. The highest bit
  2647. corresponds to piece index 0. The set bits indicate the piece is
  2648. available and unset bits indicate the piece is missing. The spare
  2649. bits at the end are set to zero.
  2650. </p>
  2651. </dd>
  2652. <dt class="hdlist1">
  2653. downloadSpeed
  2654. </dt>
  2655. <dd>
  2656. <p>
  2657. Download speed of this download measured in bytes/sec.
  2658. </p>
  2659. </dd>
  2660. <dt class="hdlist1">
  2661. uploadSpeed
  2662. </dt>
  2663. <dd>
  2664. <p>
  2665. Upload speed of this download measured in bytes/sec.
  2666. </p>
  2667. </dd>
  2668. <dt class="hdlist1">
  2669. infoHash
  2670. </dt>
  2671. <dd>
  2672. <p>
  2673. InfoHash. BitTorrent only.
  2674. </p>
  2675. </dd>
  2676. <dt class="hdlist1">
  2677. numSeeders
  2678. </dt>
  2679. <dd>
  2680. <p>
  2681. The number of seeders the client has connected to. BitTorrent only.
  2682. </p>
  2683. </dd>
  2684. <dt class="hdlist1">
  2685. pieceLength
  2686. </dt>
  2687. <dd>
  2688. <p>
  2689. Piece length in bytes.
  2690. </p>
  2691. </dd>
  2692. <dt class="hdlist1">
  2693. numPieces
  2694. </dt>
  2695. <dd>
  2696. <p>
  2697. The number of pieces.
  2698. </p>
  2699. </dd>
  2700. <dt class="hdlist1">
  2701. connections
  2702. </dt>
  2703. <dd>
  2704. <p>
  2705. The number of peers/servers the client has connected to.
  2706. </p>
  2707. </dd>
  2708. <dt class="hdlist1">
  2709. errorCode
  2710. </dt>
  2711. <dd>
  2712. <p>
  2713. The last error code occurred in this download. The value is of type
  2714. string. The error codes are defined in EXIT STATUS section. This
  2715. value is only available for stopped/completed downloads.
  2716. </p>
  2717. </dd>
  2718. </dl></div>
  2719. <div class="paragraph"><p><strong>aria2.getUris</strong> <em>gid</em></p></div>
  2720. <div class="paragraph"><p>This method returns URIs used in the download denoted by <em>gid</em>. <em>gid</em>
  2721. is of type string. The response is of type array and its element is of
  2722. type struct and it contains following keys. The value type is string.</p></div>
  2723. <div class="dlist"><dl>
  2724. <dt class="hdlist1">
  2725. uri
  2726. </dt>
  2727. <dd>
  2728. <p>
  2729. URI
  2730. </p>
  2731. </dd>
  2732. </dl></div>
  2733. <div class="paragraph"><p><strong>aria2.getFiles</strong> <em>gid</em></p></div>
  2734. <div class="paragraph"><p>This method returns file list of the download denoted by <em>gid</em>. <em>gid</em>
  2735. is of type string. The response is of type array and its element is of
  2736. type struct and it contains following keys. The value type is string.</p></div>
  2737. <div class="dlist"><dl>
  2738. <dt class="hdlist1">
  2739. index
  2740. </dt>
  2741. <dd>
  2742. <p>
  2743. Index of file. Starting with 1. This is the same order with the
  2744. files in multi-file torrent.
  2745. </p>
  2746. </dd>
  2747. <dt class="hdlist1">
  2748. path
  2749. </dt>
  2750. <dd>
  2751. <p>
  2752. File path.
  2753. </p>
  2754. </dd>
  2755. <dt class="hdlist1">
  2756. length
  2757. </dt>
  2758. <dd>
  2759. <p>
  2760. File size in bytes.
  2761. </p>
  2762. </dd>
  2763. <dt class="hdlist1">
  2764. selected
  2765. </dt>
  2766. <dd>
  2767. <p>
  2768. "true" if this file is selected by <strong>--select-file</strong> option. If
  2769. <strong>--select-file</strong> is not specified or this is single torrent or no
  2770. torrent download, this value is always "true". Otherwise "false".
  2771. </p>
  2772. </dd>
  2773. </dl></div>
  2774. <div class="paragraph"><p><strong>aria2.getPeers</strong> <em>gid</em></p></div>
  2775. <div class="paragraph"><p>This method returns peer list of the download denoted by <em>gid</em>. <em>gid</em>
  2776. is of type string. This method is for BitTorrent only. The response
  2777. is of type array and its element is of type struct and it contains
  2778. following keys. The value type is string.</p></div>
  2779. <div class="dlist"><dl>
  2780. <dt class="hdlist1">
  2781. peerId
  2782. </dt>
  2783. <dd>
  2784. <p>
  2785. Percent-encoded peer ID.
  2786. </p>
  2787. </dd>
  2788. <dt class="hdlist1">
  2789. ip
  2790. </dt>
  2791. <dd>
  2792. <p>
  2793. IP address of the peer.
  2794. </p>
  2795. </dd>
  2796. <dt class="hdlist1">
  2797. port
  2798. </dt>
  2799. <dd>
  2800. <p>
  2801. Port number of the peer.
  2802. </p>
  2803. </dd>
  2804. <dt class="hdlist1">
  2805. bitfield
  2806. </dt>
  2807. <dd>
  2808. <p>
  2809. Hexadecimal representation of the download progress of the peer. The
  2810. highest bit corresponds to piece index 0. The set bits indicate the
  2811. piece is available and unset bits indicate the piece is missing. The
  2812. spare bits at the end are set to zero.
  2813. </p>
  2814. </dd>
  2815. <dt class="hdlist1">
  2816. amChoking
  2817. </dt>
  2818. <dd>
  2819. <p>
  2820. "true" if this client is choking the peer. Otherwise "false".
  2821. </p>
  2822. </dd>
  2823. <dt class="hdlist1">
  2824. peerChoking
  2825. </dt>
  2826. <dd>
  2827. <p>
  2828. "true" if the peer is choking this client. Otherwise "false".
  2829. </p>
  2830. </dd>
  2831. <dt class="hdlist1">
  2832. downloadSpeed
  2833. </dt>
  2834. <dd>
  2835. <p>
  2836. Download speed (byte/sec) that this client obtains from the peer.
  2837. </p>
  2838. </dd>
  2839. <dt class="hdlist1">
  2840. uploadSpeed
  2841. </dt>
  2842. <dd>
  2843. <p>
  2844. Upload speed(byte/sec) that this client uploads to the peer.
  2845. </p>
  2846. </dd>
  2847. <dt class="hdlist1">
  2848. seeder
  2849. </dt>
  2850. <dd>
  2851. <p>
  2852. "true" is this client is a seeder. Otherwise "false".
  2853. </p>
  2854. </dd>
  2855. </dl></div>
  2856. <div class="paragraph"><p><strong>aria2.tellActive</strong></p></div>
  2857. <div class="paragraph"><p>This method returns the list of active downloads. The respose is of
  2858. type array and its element is the same struct returned by
  2859. <strong>aria2.tellStatus</strong> method.</p></div>
  2860. <div class="paragraph"><p><strong>aria2.tellWaiting</strong> <em>offset, num</em></p></div>
  2861. <div class="paragraph"><p>This method returns the list of waiting download in the range of
  2862. [<em>offset</em>, <em>offset</em>+<em>num</em>). <em>offset</em> is of type integer and specifies
  2863. the offset from the download waiting at the front. <em>num</em> is of type
  2864. integer and specifies the number of downloads to be returned. For
  2865. example, imagine that three downloads "A","B" and "C" are waiting in
  2866. this order. aria2.tellWaiting(0, 1) returns "A". aria2.tellWaiting(1,
  2867. 2) returns "B" and "C". The respose is of type array and its element
  2868. is the same struct returned by <strong>aria2.tellStatus</strong> method.</p></div>
  2869. <div class="paragraph"><p><strong>aria2.changeOption</strong> <em>gid, options</em></p></div>
  2870. <div class="paragraph"><p>This method changes options of the download denoted by <em>gid</em>
  2871. dynamically. <em>gid</em> is of type string. <em>options</em> is of type struct
  2872. and the available options are: <strong>bt-max-peers</strong>,
  2873. <strong>bt-request-peer-speed-limit</strong>, <strong>max-download-limit</strong> and
  2874. <strong>max-upload-limit</strong>. This method returns "OK" for success.</p></div>
  2875. <div class="paragraph"><p><strong>aria2.changeGlobalOption</strong> <em>options</em></p></div>
  2876. <div class="paragraph"><p>This method changes global options dynamically. <em>options</em> is of type
  2877. struct and the available options are <strong>max-concurrent-downloads</strong>,
  2878. <strong>max-overall-download-limit</strong> and <strong>max-overall-upload-limit</strong>. This
  2879. method returns "OK" for success.</p></div>
  2880. <div class="paragraph"><p><strong>aria2.purgeDownloadResult</strong></p></div>
  2881. <div class="paragraph"><p>This method purges completed/error/removed downloads to free memory.
  2882. This method returns "OK".</p></div>
  2883. <div class="paragraph"><p><strong>aria2.getVersion</strong></p></div>
  2884. <div class="paragraph"><p>This method returns version of the program and the list of enabled
  2885. features. The response is of type struct and contains following keys.</p></div>
  2886. <div class="dlist"><dl>
  2887. <dt class="hdlist1">
  2888. version
  2889. </dt>
  2890. <dd>
  2891. <p>
  2892. Version number of the program in string.
  2893. </p>
  2894. </dd>
  2895. <dt class="hdlist1">
  2896. enabledFeatures
  2897. </dt>
  2898. <dd>
  2899. <p>
  2900. List of enabled features. Each feature name is of type string.
  2901. </p>
  2902. </dd>
  2903. </dl></div>
  2904. <h3 id="_error_handling">Error Handling</h3><div style="clear:left"></div>
  2905. <div class="paragraph"><p>In case of error, aria2 returns faultCode=1 and the error message in
  2906. faultString.</p></div>
  2907. <h3 id="_options_2">Options</h3><div style="clear:left"></div>
  2908. <div class="paragraph"><p>Same options for <strong>-i</strong> list are available. See <strong>Input File</strong> subsection
  2909. for complete list of options.</p></div>
  2910. <div class="paragraph"><p>In the option struct, name element is option name(without preceeding
  2911. "--") and value element is argument as string.</p></div>
  2912. <div class="listingblock">
  2913. <div class="content">
  2914. <pre><tt>&lt;struct&gt;
  2915. &lt;member&gt;
  2916. &lt;name&gt;split&lt;/name&gt;
  2917. &lt;value&gt;&lt;string&gt;1&lt;/string&gt;&lt;/value&gt;
  2918. &lt;/member&gt;
  2919. &lt;member&gt;
  2920. &lt;name&gt;http-proxy&lt;/name&gt;
  2921. &lt;value&gt;&lt;string&gt;http://proxy/&lt;/string&gt;&lt;/value&gt;
  2922. &lt;/member&gt;
  2923. &lt;/struct&gt;</tt></pre>
  2924. </div></div>
  2925. <div class="paragraph"><p><strong>header</strong> and <strong>index-out</strong> option are allowed multiple times in
  2926. command-line. Since name should be unique in struct(many XML-RPC
  2927. library implementation uses hash or dict for struct), single string is
  2928. not enough. To overcome this situation, they can take array as value
  2929. as well as string.</p></div>
  2930. <div class="listingblock">
  2931. <div class="content">
  2932. <pre><tt>&lt;struct&gt;
  2933. &lt;member&gt;
  2934. &lt;name&gt;header&lt;/name&gt;
  2935. &lt;value&gt;
  2936. &lt;array&gt;
  2937. &lt;data&gt;
  2938. &lt;value&gt;&lt;string&gt;Accept-Language: ja&lt;/string&gt;&lt;/value&gt;
  2939. &lt;value&gt;&lt;string&gt;Accept-Charset: utf-8&lt;/string&gt;&lt;/value&gt;
  2940. &lt;/data&gt;
  2941. &lt;/array&gt;
  2942. &lt;/value&gt;
  2943. &lt;/member&gt;
  2944. &lt;/struct&gt;</tt></pre>
  2945. </div></div>
  2946. <h3 id="_sample_xml_rpc_client_code">Sample XML-RPC Client Code</h3><div style="clear:left"></div>
  2947. <div class="paragraph"><p>The following Ruby script adds <em>http://localhost/aria2.tar.bz2</em> to
  2948. aria2c operated on localhost with option <strong>--dir</strong>=<em>/downloads</em> and
  2949. prints its reponse.</p></div>
  2950. <div class="listingblock">
  2951. <div class="content">
  2952. <pre><tt>#!/usr/bin/env ruby
  2953. require 'xmlrpc/client'
  2954. require 'pp'
  2955. client=XMLRPC::Client.new2("http://localhost:6800/rpc")
  2956. options={ "dir" =&gt; "/downloads" }
  2957. result=client.call("aria2.addUri", [ "http://localhost/aria2.tar.bz2" ], options)
  2958. pp result</tt></pre>
  2959. </div></div>
  2960. </div>
  2961. <h2 id="_example">EXAMPLE</h2>
  2962. <div class="sectionbody">
  2963. <h3 id="_http_ftp_segmented_download">HTTP/FTP Segmented Download</h3><div style="clear:left"></div>
  2964. <h4 id="_download_a_file">Download a file</h4>
  2965. <div class="listingblock">
  2966. <div class="content">
  2967. <pre><tt>aria2c "http://host/file.zip"</tt></pre>
  2968. </div></div>
  2969. <div class="admonitionblock">
  2970. <table><tr>
  2971. <td class="icon">
  2972. <div class="title">Note</div>
  2973. </td>
  2974. <td class="content">aria2 uses 5 connections to download 1 file by default.</td>
  2975. </tr></table>
  2976. </div>
  2977. <h4 id="_download_a_file_using_1_connection">Download a file using 1 connection</h4>
  2978. <div class="listingblock">
  2979. <div class="content">
  2980. <pre><tt>aria2c -s1 "http://host/file.zip"</tt></pre>
  2981. </div></div>
  2982. <div class="admonitionblock">
  2983. <table><tr>
  2984. <td class="icon">
  2985. <div class="title">Note</div>
  2986. </td>
  2987. <td class="content">aria2 uses 5 connections to download 1 file by default.
  2988. -s1 limits the number of connections to just 1.</td>
  2989. </tr></table>
  2990. </div>
  2991. <div class="admonitionblock">
  2992. <table><tr>
  2993. <td class="icon">
  2994. <div class="title">Note</div>
  2995. </td>
  2996. <td class="content">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.</td>
  2997. </tr></table>
  2998. </div>
  2999. <h4 id="_download_a_file_from_2_different_http_servers">Download a file from 2 different HTTP servers</h4>
  3000. <div class="listingblock">
  3001. <div class="content">
  3002. <pre><tt>aria2c "http://host/file.zip" "http://mirror/file.zip"</tt></pre>
  3003. </div></div>
  3004. <h4 id="_download_a_file_from_http_and_ftp_servers">Download a file from HTTP and FTP servers</h4>
  3005. <div class="listingblock">
  3006. <div class="content">
  3007. <pre><tt>aria2c "http://host1/file.zip" "ftp://host2/file.zip"</tt></pre>
  3008. </div></div>
  3009. <h4 id="_download_files_listed_in_a_text_file_concurrently">Download files listed in a text file concurrently</h4>
  3010. <div class="listingblock">
  3011. <div class="content">
  3012. <pre><tt>aria2c -ifiles.txt -j2</tt></pre>
  3013. </div></div>
  3014. <div class="admonitionblock">
  3015. <table><tr>
  3016. <td class="icon">
  3017. <div class="title">Note</div>
  3018. </td>
  3019. <td class="content">-j option specifies the number of parallel downloads.</td>
  3020. </tr></table>
  3021. </div>
  3022. <h4 id="_using_proxy">Using proxy</h4>
  3023. <div class="paragraph"><p>For HTTP:</p></div>
  3024. <div class="listingblock">
  3025. <div class="content">
  3026. <pre><tt>aria2c --http-proxy="http://proxy:8080" "http://host/file"</tt></pre>
  3027. </div></div>
  3028. <div class="paragraph"><p>For FTP:</p></div>
  3029. <div class="listingblock">
  3030. <div class="content">
  3031. <pre><tt>aria2c --ftp-proxy="http://proxy:8080" "ftp://host/file"</tt></pre>
  3032. </div></div>
  3033. <div class="admonitionblock">
  3034. <table><tr>
  3035. <td class="icon">
  3036. <div class="title">Note</div>
  3037. </td>
  3038. <td class="content">See <strong>--http-proxy</strong>, <strong>--https-proxy</strong>, <strong>--ftp-proxy</strong> and <strong>--all-proxy</strong> for
  3039. details.
  3040. You can specify proxy in the environment variables. See <strong>ENVIRONMENT</strong> section.</td>
  3041. </tr></table>
  3042. </div>
  3043. <h4 id="_proxy_with_authorization">Proxy with authorization</h4>
  3044. <div class="listingblock">
  3045. <div class="content">
  3046. <pre><tt>aria2c --http-proxy="http://username:password@proxy:8080" "http://host/file"</tt></pre>
  3047. </div></div>
  3048. <h3 id="_metalink_download">Metalink Download</h3><div style="clear:left"></div>
  3049. <h4 id="_download_files_with_remote_metalink">Download files with remote Metalink</h4>
  3050. <div class="listingblock">
  3051. <div class="content">
  3052. <pre><tt>aria2c --follow-metalink=mem "http://host/file.metalink"</tt></pre>
  3053. </div></div>
  3054. <h4 id="_download_using_a_local_metalink_file">Download using a local metalink file</h4>
  3055. <div class="listingblock">
  3056. <div class="content">
  3057. <pre><tt>aria2c -p --lowest-speed-limit=4000 file.metalink</tt></pre>
  3058. </div></div>
  3059. <div class="admonitionblock">
  3060. <table><tr>
  3061. <td class="icon">
  3062. <div class="title">Note</div>
  3063. </td>
  3064. <td class="content">To pause a download, press Ctrl-C.
  3065. You can resume the transfer by running aria2c with the same argument in the same
  3066. directory.</td>
  3067. </tr></table>
  3068. </div>
  3069. <h4 id="_download_several_local_metalink_files">Download several local metalink files</h4>
  3070. <div class="listingblock">
  3071. <div class="content">
  3072. <pre><tt>aria2c -j2 file1.metalink file2.metalink</tt></pre>
  3073. </div></div>
  3074. <h4 id="_download_only_selected_files_using_index">Download only selected files using index</h4>
  3075. <div class="listingblock">
  3076. <div class="content">
  3077. <pre><tt>aria2c --select-file=1-4,8 file.metalink</tt></pre>
  3078. </div></div>
  3079. <div class="admonitionblock">
  3080. <table><tr>
  3081. <td class="icon">
  3082. <div class="title">Note</div>
  3083. </td>
  3084. <td class="content">The index is printed to the console using -S option.</td>
  3085. </tr></table>
  3086. </div>
  3087. <h4 id="_download_a_file_using_a_local_metalink_file_with_user_preference">Download a file using a local .metalink file with user preference</h4>
  3088. <div class="listingblock">
  3089. <div class="content">
  3090. <pre><tt>aria2c --metalink-location=JP,US --metalink-version=1.1 --metalink-language=en-US file.metalink</tt></pre>
  3091. </div></div>
  3092. <h3 id="_bittorrent_download">BitTorrent Download</h3><div style="clear:left"></div>
  3093. <h4 id="_download_files_from_remote_bittorrent_file">Download files from remote BitTorrent file</h4>
  3094. <div class="listingblock">
  3095. <div class="content">
  3096. <pre><tt>aria2c --follow-torrent=mem "http://host/file.torrent"</tt></pre>
  3097. </div></div>
  3098. <h4 id="_download_using_a_local_torrent_file">Download using a local torrent file</h4>
  3099. <div class="listingblock">
  3100. <div class="content">
  3101. <pre><tt>aria2c --max-upload-limit=40K file.torrent</tt></pre>
  3102. </div></div>
  3103. <div class="admonitionblock">
  3104. <table><tr>
  3105. <td class="icon">
  3106. <div class="title">Note</div>
  3107. </td>
  3108. <td class="content">--max-upload-limit specifies the max of upload rate.</td>
  3109. </tr></table>
  3110. </div>
  3111. <div class="admonitionblock">
  3112. <table><tr>
  3113. <td class="icon">
  3114. <div class="title">Note</div>
  3115. </td>
  3116. <td class="content">To pause a download, press Ctrl-C. You can resume the transfer by running aria2c with the same argument in the same directory.</td>
  3117. </tr></table>
  3118. </div>
  3119. <h4 id="_download_using_bittorrent_magnet_uri">Download using BitTorrent Magnet URI</h4>
  3120. <div class="listingblock">
  3121. <div class="content">
  3122. <pre><tt>aria2c "magnet:?xt=urn:btih:248d0a1cd08284299de78d5c1ed359bb46717d8c&amp;dn=aria2"</tt></pre>
  3123. </div></div>
  3124. <div class="admonitionblock">
  3125. <table><tr>
  3126. <td class="icon">
  3127. <div class="title">Note</div>
  3128. </td>
  3129. <td class="content">Don&#8217;t forget to quote BitTorrent Magnet URI which includes "&amp;"
  3130. character with single(') or double(") quotation.</td>
  3131. </tr></table>
  3132. </div>
  3133. <h4 id="_download_2_torrents">Download 2 torrents</h4>
  3134. <div class="listingblock">
  3135. <div class="content">
  3136. <pre><tt>aria2c -j2 file1.torrent file2.torrent</tt></pre>
  3137. </div></div>
  3138. <h4 id="_download_a_file_using_torrent_and_http_ftp_server">Download a file using torrent and HTTP/FTP server</h4>
  3139. <div class="listingblock">
  3140. <div class="content">
  3141. <pre><tt>aria2c -Ttest.torrent "http://host1/file" "ftp://host2/file"</tt></pre>
  3142. </div></div>
  3143. <div class="admonitionblock">
  3144. <table><tr>
  3145. <td class="icon">
  3146. <div class="title">Note</div>
  3147. </td>
  3148. <td class="content">Downloading multi file torrent with HTTP/FTP is not supported.</td>
  3149. </tr></table>
  3150. </div>
  3151. <h4 id="_download_only_selected_files_using_index_usually_called_selectable_download">Download only selected files using index(usually called "selectable download")</h4>
  3152. <div class="listingblock">
  3153. <div class="content">
  3154. <pre><tt>aria2c --select-file=1-4,8 file.torrent</tt></pre>
  3155. </div></div>
  3156. <div class="admonitionblock">
  3157. <table><tr>
  3158. <td class="icon">
  3159. <div class="title">Note</div>
  3160. </td>
  3161. <td class="content">The index is printed to the console using -S option.</td>
  3162. </tr></table>
  3163. </div>
  3164. <h4 id="_specify_output_filename">Specify output filename</h4>
  3165. <div class="paragraph"><p>To specify output filename for BitTorrent downloads, you need to know
  3166. the index of file in torrent file using <strong>-S</strong> option. For example, the
  3167. output looks like this:</p></div>
  3168. <div class="listingblock">
  3169. <div class="content">
  3170. <pre><tt>idx|path/length
  3171. ===+======================
  3172. 1|dist/base-2.6.18.iso
  3173. |99.9MiB
  3174. ---+----------------------
  3175. 2|dist/driver-2.6.18.iso
  3176. |169.0MiB
  3177. ---+----------------------</tt></pre>
  3178. </div></div>
  3179. <div class="paragraph"><p>To save <em>dist/base-2.6.18.iso</em> in <em>/tmp/mydir/base.iso</em> and
  3180. <em>dist/driver-2.6.18.iso</em> in <em>/tmp/dir/driver.iso</em>, use the following
  3181. command:</p></div>
  3182. <div class="listingblock">
  3183. <div class="content">
  3184. <pre><tt>aria2c --dir=/tmp --index-out=1=mydir/base.iso --index-out=2=dir/driver.iso file.torrent</tt></pre>
  3185. </div></div>
  3186. <h4 id="_change_the_listening_port_for_incoming_peer">Change the listening port for incoming peer</h4>
  3187. <div class="listingblock">
  3188. <div class="content">
  3189. <pre><tt>aria2c --listen-port=7000-7001,8000 file.torrent</tt></pre>
  3190. </div></div>
  3191. <div class="admonitionblock">
  3192. <table><tr>
  3193. <td class="icon">
  3194. <div class="title">Note</div>
  3195. </td>
  3196. <td class="content">Since aria2 doesn&#8217;t configure firewall or router for port forwarding, it&#8217;s up
  3197. to you to do it manually.</td>
  3198. </tr></table>
  3199. </div>
  3200. <h4 id="_specify_the_condition_to_stop_program_after_torrent_download_finished">Specify the condition to stop program after torrent download finished</h4>
  3201. <div class="listingblock">
  3202. <div class="content">
  3203. <pre><tt>aria2c --seed-time=120 --seed-ratio=1.0 file.torrent</tt></pre>
  3204. </div></div>
  3205. <div class="admonitionblock">
  3206. <table><tr>
  3207. <td class="icon">
  3208. <div class="title">Note</div>
  3209. </td>
  3210. <td class="content">In the above example, the program exits when the 120 minutes has elapsed since download completed or seed ratio reaches 1.0.</td>
  3211. </tr></table>
  3212. </div>
  3213. <h4 id="_throttle_upload_speed">Throttle upload speed</h4>
  3214. <div class="listingblock">
  3215. <div class="content">
  3216. <pre><tt>aria2c --max-upload-limit=100K file.torrent</tt></pre>
  3217. </div></div>
  3218. <h4 id="_enable_dht">Enable DHT</h4>
  3219. <div class="listingblock">
  3220. <div class="content">
  3221. <pre><tt>aria2c --enable-dht --dht-listen-port=6881 file.torrent</tt></pre>
  3222. </div></div>
  3223. <div class="admonitionblock">
  3224. <table><tr>
  3225. <td class="icon">
  3226. <div class="title">Note</div>
  3227. </td>
  3228. <td class="content">DHT uses udp port. Since aria2 doesn&#8217;t configure firewall or router for port
  3229. forwarding, it&#8217;s up to you to do it manually.</td>
  3230. </tr></table>
  3231. </div>
  3232. <h3 id="_more_advanced_http_features">More advanced HTTP features</h3><div style="clear:left"></div>
  3233. <h4 id="_load_cookies">Load cookies</h4>
  3234. <div class="listingblock">
  3235. <div class="content">
  3236. <pre><tt>aria2c --load-cookies=cookies.txt "http://host/file.zip"</tt></pre>
  3237. </div></div>
  3238. <div class="admonitionblock">
  3239. <table><tr>
  3240. <td class="icon">
  3241. <div class="title">Note</div>
  3242. </td>
  3243. <td class="content">You can use Firefox/Mozilla&#8217;s cookie file without modification.</td>
  3244. </tr></table>
  3245. </div>
  3246. <h4 id="_resume_download_started_by_web_browsers_or_another_programs">Resume download started by web browsers or another programs</h4>
  3247. <div class="listingblock">
  3248. <div class="content">
  3249. <pre><tt>aria2c -c -s2 "http://host/partiallydownloadedfile.zip"</tt></pre>
  3250. </div></div>
  3251. <h4 id="_client_certificate_authorization_for_ssl_tls">Client certificate authorization for SSL/TLS</h4>
  3252. <div class="listingblock">
  3253. <div class="content">
  3254. <pre><tt>aria2c --certificate=/path/to/mycert.pem --private-key=/path/to/mykey.pem https://host/file</tt></pre>
  3255. </div></div>
  3256. <div class="admonitionblock">
  3257. <table><tr>
  3258. <td class="icon">
  3259. <div class="title">Note</div>
  3260. </td>
  3261. <td class="content">The file specified in <strong>--private-key</strong> must be decrypted. The behavior when
  3262. encrypted one is given is undefined.</td>
  3263. </tr></table>
  3264. </div>
  3265. <h4 id="_verify_peer_in_ssl_tls_using_given_ca_certificates">Verify peer in SSL/TLS using given CA certificates</h4>
  3266. <div class="listingblock">
  3267. <div class="content">
  3268. <pre><tt>aria2c --ca-certificate=/path/to/ca-certificates.crt --check-certificate https://host/file</tt></pre>
  3269. </div></div>
  3270. <h3 id="_and_more_advanced_features">And more advanced features</h3><div style="clear:left"></div>
  3271. <h4 id="_throttle_download_speed">Throttle download speed</h4>
  3272. <div class="listingblock">
  3273. <div class="content">
  3274. <pre><tt>aria2c --max-download-limit=100K file.metalink</tt></pre>
  3275. </div></div>
  3276. <h4 id="_repair_a_damaged_download">Repair a damaged download</h4>
  3277. <div class="listingblock">
  3278. <div class="content">
  3279. <pre><tt>aria2c -V file.metalink</tt></pre>
  3280. </div></div>
  3281. <div class="admonitionblock">
  3282. <table><tr>
  3283. <td class="icon">
  3284. <div class="title">Note</div>
  3285. </td>
  3286. <td class="content">This option is only available used with BitTorrent or metalink with chunk
  3287. checksums.</td>
  3288. </tr></table>
  3289. </div>
  3290. <h4 id="_drop_connection_if_download_speed_is_lower_than_specified_value">Drop connection if download speed is lower than specified value</h4>
  3291. <div class="listingblock">
  3292. <div class="content">
  3293. <pre><tt>aria2c --lowest-speed-limit=10K file.metalink</tt></pre>
  3294. </div></div>
  3295. <h4 id="_parameterized_uri_support">Parameterized URI support</h4>
  3296. <div class="paragraph"><p>You can specify set of parts:</p></div>
  3297. <div class="listingblock">
  3298. <div class="content">
  3299. <pre><tt>aria2c -P "http://{host1,host2,host3}/file.iso"</tt></pre>
  3300. </div></div>
  3301. <div class="paragraph"><p>You can specify numeric sequence:</p></div>
  3302. <div class="listingblock">
  3303. <div class="content">
  3304. <pre><tt>aria2c -Z -P "http://host/image[000-100].png"</tt></pre>
  3305. </div></div>
  3306. <div class="admonitionblock">
  3307. <table><tr>
  3308. <td class="icon">
  3309. <div class="title">Note</div>
  3310. </td>
  3311. <td class="content">-Z option is required if the all URIs don&#8217;t point to the same file, such as the above example.</td>
  3312. </tr></table>
  3313. </div>
  3314. <div class="paragraph"><p>You can specify step counter:</p></div>
  3315. <div class="listingblock">
  3316. <div class="content">
  3317. <pre><tt>aria2c -Z -P "http://host/image[A-Z:2].png"</tt></pre>
  3318. </div></div>
  3319. <h4 id="_parallel_downloads_of_arbitrary_number_of_url_metalink_torrent">Parallel downloads of arbitrary number of URL,metalink,torrent</h4>
  3320. <div class="listingblock">
  3321. <div class="content">
  3322. <pre><tt>aria2c -j3 -Z "http://host/file1" file2.torrent file3.metalink</tt></pre>
  3323. </div></div>
  3324. <h4 id="_bittorrent_encryption">BitTorrent Encryption</h4>
  3325. <div class="paragraph"><p>Encrypt whole payload using ARC4:</p></div>
  3326. <div class="listingblock">
  3327. <div class="content">
  3328. <pre><tt>aria2c --bt-min-crypto-level=arc4 --bt-require-crypto=true file.torrent</tt></pre>
  3329. </div></div>
  3330. </div>
  3331. <h2 id="_see_also">SEE ALSO</h2>
  3332. <div class="sectionbody">
  3333. <div class="paragraph"><p>Project Web Site: <a href="http://aria2.sourceforge.net/">http://aria2.sourceforge.net/</a></p></div>
  3334. <div class="paragraph"><p>aria2 Wiki: <a href="http://sourceforge.net/apps/trac/aria2/wiki">http://sourceforge.net/apps/trac/aria2/wiki</a></p></div>
  3335. <div class="paragraph"><p>Metalink Homepage: <a href="http://www.metalinker.org/">http://www.metalinker.org/</a></p></div>
  3336. </div>
  3337. <h2 id="_copyright">COPYRIGHT</h2>
  3338. <div class="sectionbody">
  3339. <div class="paragraph"><p>Copyright &#169; 2006, 2009 Tatsuhiro Tsujikawa</p></div>
  3340. <div class="paragraph"><p>This program is free software; you can redistribute it and/or modify
  3341. it under the terms of the GNU General Public License as published by
  3342. the Free Software Foundation; either version 2 of the License, or
  3343. (at your option) any later version.</p></div>
  3344. <div class="paragraph"><p>This program is distributed in the hope that it will be useful,
  3345. but WITHOUT ANY WARRANTY; without even the implied warranty of
  3346. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  3347. GNU General Public License for more details.</p></div>
  3348. <div class="paragraph"><p>You should have received a copy of the GNU General Public License
  3349. along with this program; if not, write to the Free Software
  3350. Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</p></div>
  3351. <div class="paragraph"><p>In addition, as a special exception, the copyright holders give
  3352. permission to link the code of portions of this program with the
  3353. OpenSSL library under certain conditions as described in each
  3354. individual source file, and distribute linked combinations
  3355. including the two.
  3356. You must obey the GNU General Public License in all respects
  3357. for all of the code used other than OpenSSL. If you modify
  3358. file(s) with this exception, you may extend this exception to your
  3359. version of the file(s), but you are not obligated to do so. If you
  3360. do not wish to do so, delete this exception statement from your
  3361. version. If you delete this exception statement from all source
  3362. files in the program, then also delete it here.</p></div>
  3363. </div>
  3364. </div>
  3365. <div id="footnotes"><hr /></div>
  3366. <div id="footer">
  3367. <div id="footer-text">
  3368. Last updated 2009-11-29 15:46:53 JST
  3369. </div>
  3370. </div>
  3371. </body>
  3372. </html>