aria2c.1.html 110 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831
  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. To erase previously
  620. defined proxy, use "". You can override this setting and specify a
  621. proxy server for a particular protocol using <strong>--http-proxy</strong>,
  622. <strong>--https-proxy</strong> and <strong>--ftp-proxy</strong> options. 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. When <strong>-Z</strong> option is used, this
  705. option is ignored.
  706. </p>
  707. </dd>
  708. </dl></div>
  709. <div class="admonitionblock">
  710. <table><tr>
  711. <td class="icon">
  712. <div class="title">Note</div>
  713. </td>
  714. <td class="content">In Metalink or BitTorrent download you cannot specify file name.
  715. The file name specified here is only used when the URLs fed to aria2
  716. are done by command line without <strong>-i</strong>, <strong>-Z</strong> option. For example:
  717. aria2c -o myfile.zip "http://mirror1/file.zip" "http://mirror2/file.zip"</td>
  718. </tr></table>
  719. </div>
  720. <div class="dlist"><dl>
  721. <dt class="hdlist1">
  722. <strong>--proxy-method</strong>=METHOD
  723. </dt>
  724. <dd>
  725. <p>
  726. Set the method to use in proxy request. <em>METHOD</em> is either <em>get</em> or
  727. <em>tunnel</em>. HTTPS downloads always use <em>tunnel</em> regardless of this
  728. option.
  729. Default: <em>get</em>
  730. </p>
  731. </dd>
  732. <dt class="hdlist1">
  733. <strong>-R</strong>, <strong>--remote-time</strong>[=<em>true</em>|<em>false</em>]
  734. </dt>
  735. <dd>
  736. <p>
  737. Retrieve timestamp of the remote file from the remote HTTP/FTP
  738. server and if it is available, apply it to the local file.
  739. Default: <em>false</em>
  740. </p>
  741. </dd>
  742. <dt class="hdlist1">
  743. *--reuse-uri[=<em>true</em>|<em>false</em>]
  744. </dt>
  745. <dd>
  746. <p>
  747. Reuse already used URIs if no unused URIs are left.
  748. Default: <em>true</em>
  749. </p>
  750. </dd>
  751. <dt class="hdlist1">
  752. <strong>--server-stat-of</strong>=FILE
  753. </dt>
  754. <dd>
  755. <p>
  756. Specify the filename to which performance profile of the servers is
  757. saved. You can load saved data using <strong>--server-stat-if</strong> option. See
  758. <strong>Server Performance Profile</strong> subsection below for file format.
  759. </p>
  760. </dd>
  761. <dt class="hdlist1">
  762. <strong>--server-stat-if</strong>=FILE
  763. </dt>
  764. <dd>
  765. <p>
  766. Specify the filename to load performance profile of the servers. The
  767. loaded data will be used in some URI selector such as <em>feedback</em>.
  768. See also <strong>--uri-selector</strong> option. See <strong>Server Performance Profile</strong>
  769. subsection below for file format.
  770. </p>
  771. </dd>
  772. <dt class="hdlist1">
  773. <strong>--server-stat-timeout</strong>=SEC
  774. </dt>
  775. <dd>
  776. <p>
  777. Specifies timeout in seconds to invalidate performance profile of
  778. the servers since the last contact to them.
  779. Default: <em>86400</em> (24hours)
  780. </p>
  781. </dd>
  782. <dt class="hdlist1">
  783. <strong>-s</strong>, <strong>--split</strong>=N
  784. </dt>
  785. <dd>
  786. <p>
  787. Download a file using N connections.
  788. If more than N URLs are given, first N URLs are used and remaining URLs are
  789. used for backup.
  790. If less than N URLs are given, those URLs are used more than once so that N
  791. connections total are made simultaneously.
  792. Please see <strong>-j</strong> option too.
  793. Please note that in Metalink download, this option has no effect and use
  794. <strong>-C</strong> option instead.
  795. Default: <em>5</em>
  796. </p>
  797. </dd>
  798. <dt class="hdlist1">
  799. <strong>-t</strong>, <strong>--timeout</strong>=SEC
  800. </dt>
  801. <dd>
  802. <p>
  803. Set timeout in seconds.
  804. Default: <em>60</em>
  805. </p>
  806. </dd>
  807. <dt class="hdlist1">
  808. <strong>--uri-selector</strong>=SELECTOR
  809. </dt>
  810. <dd>
  811. <p>
  812. Specify URI selection algorithm. The possible values are <em>inorder</em>,
  813. <em>feedback</em> and <em>adaptive</em>. If <em>inorder</em> is given, URI is tried in
  814. the order appeared in the URI list. If <em>feedback</em> is given, aria2
  815. uses download speed observed in the previous downloads and choose
  816. fastest server in the URI list. This also effectively skips dead
  817. mirrors. The observed download speed is a part of performance
  818. profile of servers mentioned in <strong>--server-stat-of</strong> and
  819. <strong>--server-stat-if</strong> options. If <em>adaptive</em> is given, selects one of
  820. the best mirrors for the first and reserved connections. For
  821. supplementary ones, it returns mirrors which has not been tested
  822. yet, and if each of them has already been tested, returns mirrors
  823. which has to be tested again. Otherwise, it doesn&#8217;t select anymore
  824. mirrors. Like <em>feedback</em>, it uses a performance profile of servers.
  825. Default: <em>feedback</em>
  826. </p>
  827. </dd>
  828. </dl></div>
  829. <h3 id="_http_specific_options">HTTP Specific Options</h3><div style="clear:left"></div>
  830. <div class="dlist"><dl>
  831. <dt class="hdlist1">
  832. <strong>--ca-certificate</strong>=FILE
  833. </dt>
  834. <dd>
  835. <p>
  836. Use the certificate authorities in FILE to verify the peers.
  837. The certificate file must be in PEM format and can contain multiple CA
  838. certificates.
  839. Use <strong>--check-certificate</strong> option to enable verification.
  840. </p>
  841. </dd>
  842. <dt class="hdlist1">
  843. <strong>--certificate</strong>=FILE
  844. </dt>
  845. <dd>
  846. <p>
  847. Use the client certificate in FILE.
  848. The certificate must be in PEM format.
  849. You may use <strong>--private-key</strong> option to specify the private key.
  850. </p>
  851. </dd>
  852. <dt class="hdlist1">
  853. <strong>--check-certificate</strong>[=<em>true</em>|<em>false</em>]
  854. </dt>
  855. <dd>
  856. <p>
  857. Verify the peer using certificates specified in <strong>--ca-certificate</strong> option.
  858. Default: <em>true</em>
  859. </p>
  860. </dd>
  861. <dt class="hdlist1">
  862. <strong>--http-auth-challenge</strong>[=<em>true</em>|<em>false</em>]
  863. </dt>
  864. <dd>
  865. <p>
  866. Send HTTP authorization header only when it is requested by the
  867. server. If <em>false</em> is set, then authorization header is always sent
  868. to the server. There is an exception: if username and password are
  869. embedded in URI, authorization header is always sent to the server
  870. regardless of this option. Default: <em>false</em>
  871. </p>
  872. </dd>
  873. <dt class="hdlist1">
  874. <strong>--http-no-cache</strong>[=<em>true</em>|<em>false</em>]
  875. </dt>
  876. <dd>
  877. <p>
  878. Send Cache-Control: no-cache and Pragma: no-cache header to avoid
  879. cached content. If <em>false</em> is given, these headers are not sent
  880. and you can add Cache-Control header with a directive you like
  881. using <strong>--header</strong> option. Default: <em>true</em>
  882. </p>
  883. </dd>
  884. <dt class="hdlist1">
  885. <strong>--http-user</strong>=USER
  886. </dt>
  887. <dd>
  888. <p>
  889. Set HTTP user. This affects all URLs.
  890. </p>
  891. </dd>
  892. <dt class="hdlist1">
  893. <strong>--http-passwd</strong>=PASSWD
  894. </dt>
  895. <dd>
  896. <p>
  897. Set HTTP password. This affects all URLs.
  898. </p>
  899. </dd>
  900. <dt class="hdlist1">
  901. <strong>--http-proxy</strong>=PROXY
  902. </dt>
  903. <dd>
  904. <p>
  905. Use this proxy server for HTTP. To erase previously defined proxy,
  906. use "". See also <strong>--all-proxy</strong> option. This affects all URLs. The
  907. format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  908. </p>
  909. </dd>
  910. <dt class="hdlist1">
  911. <strong>--https-proxy</strong>=PROXY
  912. </dt>
  913. <dd>
  914. <p>
  915. Use this proxy server for HTTPS. To erase previously defined proxy,
  916. use "". See also <strong>--all-proxy</strong> option. This affects all URLs. The
  917. format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  918. </p>
  919. </dd>
  920. <dt class="hdlist1">
  921. <strong>--private-key</strong>=FILE
  922. </dt>
  923. <dd>
  924. <p>
  925. Use the private key in FILE.
  926. The private key must be decrypted and in PEM format.
  927. The behavior when encrypted one is given is undefined.
  928. See also <strong>--certificate</strong> option.
  929. </p>
  930. </dd>
  931. <dt class="hdlist1">
  932. <strong>--referer</strong>=REFERER
  933. </dt>
  934. <dd>
  935. <p>
  936. Set Referer. This affects all URLs.
  937. </p>
  938. </dd>
  939. <dt class="hdlist1">
  940. <strong>--enable-http-keep-alive</strong>[=<em>true</em>|<em>false</em>]
  941. </dt>
  942. <dd>
  943. <p>
  944. Enable HTTP/1.1 persistent connection.
  945. Default: <em>true</em>
  946. </p>
  947. </dd>
  948. <dt class="hdlist1">
  949. <strong>--enable-http-pipelining</strong>[=<em>true</em>|<em>false</em>]
  950. </dt>
  951. <dd>
  952. <p>
  953. Enable HTTP/1.1 pipelining.
  954. Default: <em>false</em>
  955. </p>
  956. </dd>
  957. <dt class="hdlist1">
  958. <strong>--header</strong>=HEADER
  959. </dt>
  960. <dd>
  961. <p>
  962. Append HEADER to HTTP request header.
  963. You can use this option repeatedly to specify more than one header:
  964. aria2c <strong>--header</strong>="X-A: b78" <strong>--header</strong>="X-B: 9J1" "http://host/file"
  965. </p>
  966. </dd>
  967. <dt class="hdlist1">
  968. <strong>--load-cookies</strong>=FILE
  969. </dt>
  970. <dd>
  971. <p>
  972. Load Cookies from FILE using the Firefox3 format (SQLite3) and the
  973. Mozilla/Firefox(1.x/2.x)/Netscape format.
  974. </p>
  975. </dd>
  976. </dl></div>
  977. <div class="admonitionblock">
  978. <table><tr>
  979. <td class="icon">
  980. <div class="title">Note</div>
  981. </td>
  982. <td class="content">If aria2 is built without libsqlite3, then it doesn&#8217;t support Firefox3 cookie format.</td>
  983. </tr></table>
  984. </div>
  985. <div class="dlist"><dl>
  986. <dt class="hdlist1">
  987. <strong>--save-cookies</strong>=FILE
  988. </dt>
  989. <dd>
  990. <p>
  991. Save Cookies to FILE in Mozilla/Firefox(1.x/2.x)/ Netscape
  992. format. If FILE already exists, it is overwritten. Session Cookies
  993. are also saved and their expiry values are treated as 0. Possible
  994. Values: <em>/path/to/file</em>
  995. </p>
  996. </dd>
  997. <dt class="hdlist1">
  998. <strong>--use-head</strong>[=<em>true</em>|<em>false</em>]
  999. </dt>
  1000. <dd>
  1001. <p>
  1002. Use HEAD method for the first request to the HTTP server.
  1003. Default: <em>false</em>
  1004. </p>
  1005. </dd>
  1006. <dt class="hdlist1">
  1007. <strong>-U</strong>, <strong>--user-agent</strong>=USER_AGENT
  1008. </dt>
  1009. <dd>
  1010. <p>
  1011. Set user agent for HTTP(S) downloads.
  1012. Default: <em>aria2/$VERSION</em>, $VERSION is replaced by package version.
  1013. </p>
  1014. </dd>
  1015. </dl></div>
  1016. <h3 id="_ftp_specific_options">FTP Specific Options</h3><div style="clear:left"></div>
  1017. <div class="dlist"><dl>
  1018. <dt class="hdlist1">
  1019. <strong>--ftp-user</strong>=USER
  1020. </dt>
  1021. <dd>
  1022. <p>
  1023. Set FTP user. This affects all URLs.
  1024. Default: <em>anonymous</em>
  1025. </p>
  1026. </dd>
  1027. <dt class="hdlist1">
  1028. <strong>--ftp-passwd</strong>=PASSWD
  1029. </dt>
  1030. <dd>
  1031. <p>
  1032. Set FTP password. This affects all URLs.
  1033. If user name is embedded but password is missing in URI, aria2 tries
  1034. to resolve password using .netrc. If password is found in .netrc,
  1035. then use it as password. If not, use the password specified in this
  1036. option.
  1037. Default: <em>ARIA2USER@</em>
  1038. </p>
  1039. </dd>
  1040. <dt class="hdlist1">
  1041. <strong>-p</strong>, <strong>--ftp-pasv</strong>[=<em>true</em>|<em>false</em>]
  1042. </dt>
  1043. <dd>
  1044. <p>
  1045. Use the passive mode in FTP.
  1046. If <em>false</em> is given, the active mode will be used.
  1047. Default: <em>true</em>
  1048. </p>
  1049. </dd>
  1050. <dt class="hdlist1">
  1051. <strong>--ftp-proxy</strong>=PROXY
  1052. </dt>
  1053. <dd>
  1054. <p>
  1055. Use this proxy server for FTP. To erase previously defined proxy,
  1056. use "". See also <strong>--all-proxy</strong> option. This affects all URLs. The
  1057. format of PROXY is [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  1058. </p>
  1059. </dd>
  1060. <dt class="hdlist1">
  1061. <strong>--ftp-type</strong>=TYPE
  1062. </dt>
  1063. <dd>
  1064. <p>
  1065. Set FTP transfer type. TYPE is either <em>binary</em> or <em>ascii</em>.
  1066. Default: <em>binary</em>
  1067. </p>
  1068. </dd>
  1069. <dt class="hdlist1">
  1070. <strong>--ftp-reuse-connection</strong>[=<em>true</em>|<em>false</em>]
  1071. </dt>
  1072. <dd>
  1073. <p>
  1074. Reuse connection in FTP.
  1075. Default: <em>true</em>
  1076. </p>
  1077. </dd>
  1078. </dl></div>
  1079. <h3 id="_bittorrent_metalink_options">BitTorrent/Metalink Options</h3><div style="clear:left"></div>
  1080. <div class="dlist"><dl>
  1081. <dt class="hdlist1">
  1082. <strong>--select-file</strong>=INDEX&#8230;
  1083. </dt>
  1084. <dd>
  1085. <p>
  1086. Set file to download by specifying its index.
  1087. You can find the file index using the <strong>--show-files</strong> option.
  1088. Multiple indexes can be specified by using ",", for example: <em>3,6</em>.
  1089. You can also use "-" to specify a range: <em>1-5</em>.
  1090. "," and "-" can be used together: <em>1-5,8,9</em>.
  1091. When used with the -M option, index may vary depending on the query
  1092. (see <strong>--metalink-</strong>* options).
  1093. </p>
  1094. </dd>
  1095. </dl></div>
  1096. <div class="admonitionblock">
  1097. <table><tr>
  1098. <td class="icon">
  1099. <div class="title">Note</div>
  1100. </td>
  1101. <td class="content">In multi file torrent, the adjacent files specified by this option may
  1102. also be downloaded. This is by design, not a bug.
  1103. A single piece may include several files or part of files, and aria2
  1104. writes the piece to the appropriate files.</td>
  1105. </tr></table>
  1106. </div>
  1107. <div class="dlist"><dl>
  1108. <dt class="hdlist1">
  1109. <strong>-S</strong>, <strong>--show-files</strong>
  1110. </dt>
  1111. <dd>
  1112. <p>
  1113. Print file listing of .torrent or .metalink file and exit.
  1114. In case of .torrent file, additional information
  1115. (infohash, piece length, etc) is also printed.
  1116. </p>
  1117. </dd>
  1118. </dl></div>
  1119. <h3 id="_bittorrent_specific_options">BitTorrent Specific Options</h3><div style="clear:left"></div>
  1120. <div class="dlist"><dl>
  1121. <dt class="hdlist1">
  1122. <strong>--bt-enable-lpd</strong>[=<em>true</em>|<em>false</em>]
  1123. </dt>
  1124. <dd>
  1125. <p>
  1126. Enable Local Peer Discovery. If a private flag is set in a torrent,
  1127. aria2 doesn&#8217;t use this feature for that download even if <em>true</em> is
  1128. given. Default: <em>false</em>
  1129. </p>
  1130. </dd>
  1131. <dt class="hdlist1">
  1132. <strong>--bt-external-ip</strong>=IPADDRESS
  1133. </dt>
  1134. <dd>
  1135. <p>
  1136. Specify the external IP address to report to a BitTorrent
  1137. tracker. Although this function is named "external", it can accept
  1138. any kind of IP addresses. IPADDRESS must be a numeric IP address.
  1139. </p>
  1140. </dd>
  1141. <dt class="hdlist1">
  1142. <strong>--bt-hash-check-seed</strong>[=<em>true</em>|<em>false</em>]
  1143. </dt>
  1144. <dd>
  1145. <p>
  1146. If <em>true</em> is given, after hash check using <strong>--check-integrity</strong> option and
  1147. file is complete, continue to seed file. If you want to check file
  1148. and download it only when it is damaged or incomplete, set this
  1149. option to <em>false</em>. This option has effect only on BitTorrent download.
  1150. Default: <em>true</em>
  1151. </p>
  1152. </dd>
  1153. <dt class="hdlist1">
  1154. <strong>--bt-lpd-interface</strong>=INTERFACE
  1155. </dt>
  1156. <dd>
  1157. <p>
  1158. Use given interface for Local Peer Discovery. If this option is not
  1159. specified, the default interface is chosen. You can specify
  1160. interface name and IP address. Possible Values: interface, IP
  1161. addres
  1162. </p>
  1163. </dd>
  1164. <dt class="hdlist1">
  1165. <strong>--bt-max-open-files</strong>=NUM
  1166. </dt>
  1167. <dd>
  1168. <p>
  1169. Specify maximum number of files to open in each BitTorrent download.
  1170. Default: <em>100</em>
  1171. </p>
  1172. </dd>
  1173. <dt class="hdlist1">
  1174. <strong>--bt-max-peers</strong>=NUM
  1175. </dt>
  1176. <dd>
  1177. <p>
  1178. Specify the maximum number of peers per torrent. <em>0</em> means
  1179. unlimited. See also <strong>--bt-request-peer-speed-limit</strong> option.
  1180. Default: <em>55</em>
  1181. </p>
  1182. </dd>
  1183. <dt class="hdlist1">
  1184. <strong>--bt-metadata-only</strong>[=<em>true</em>|<em>false</em>]
  1185. </dt>
  1186. <dd>
  1187. <p>
  1188. Download metadata only. The file(s) described in metadata will not
  1189. be downloaded. This option has effect only when BitTorrent Magnet
  1190. URI is used. See also <strong>--bt-save-metadata</strong> option. Default: <em>false</em>
  1191. </p>
  1192. </dd>
  1193. <dt class="hdlist1">
  1194. <strong>--bt-min-crypto-level</strong>=<em>plain</em>|<em>arc4</em>
  1195. </dt>
  1196. <dd>
  1197. <p>
  1198. Set minimum level of encryption method.
  1199. If several encryption methods are provided by a peer, aria2 chooses the lowest
  1200. one which satisfies the given level.
  1201. Default: <em>plain</em>
  1202. </p>
  1203. </dd>
  1204. <dt class="hdlist1">
  1205. <strong>--bt-prioritize-piece</strong>=<em>head</em>[=SIZE],<em>tail</em>[=SIZE]
  1206. </dt>
  1207. <dd>
  1208. <p>
  1209. Try to download first and last pieces of each file first. This is
  1210. useful for previewing files. The argument can contain 2 keywords:
  1211. <em>head</em> and <em>tail</em>. To include both keywords, they must be separated
  1212. by comma. These keywords can take one parameter, SIZE. For example,
  1213. if <em>head</em>=SIZE is specified, pieces in the range of first SIZE bytes
  1214. of each file get higher priority. <em>tail</em>=SIZE means the range of
  1215. last SIZE bytes of each file. SIZE can include <em>K</em> or <em>M</em>(1K = 1024,
  1216. 1M = 1024K). If SIZE is omitted, SIZE=1M is used.
  1217. </p>
  1218. </dd>
  1219. <dt class="hdlist1">
  1220. <strong>--bt-require-crypto</strong>=<em>true</em>|<em>false</em>
  1221. </dt>
  1222. <dd>
  1223. <p>
  1224. If true is given, aria2 doesn&#8217;t accept and establish connection with legacy
  1225. BitTorrent handshake(\19BitTorrent protocol).
  1226. Thus aria2 always uses Obfuscation handshake.
  1227. Default: <em>false</em>
  1228. </p>
  1229. </dd>
  1230. <dt class="hdlist1">
  1231. <strong>--bt-request-peer-speed-limit</strong>=SPEED
  1232. </dt>
  1233. <dd>
  1234. <p>
  1235. If the whole download speed of every torrent is lower than SPEED,
  1236. aria2 temporarily increases the number of peers to try for more
  1237. download speed. Configuring this option with your preferred download
  1238. speed can increase your download speed in some cases.
  1239. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1240. Default: <em>50K</em>
  1241. </p>
  1242. </dd>
  1243. <dt class="hdlist1">
  1244. <strong>--bt-save-metadata</strong>[=<em>true</em>|<em>false</em>]
  1245. </dt>
  1246. <dd>
  1247. <p>
  1248. Save metadata as .torrent file. This option has effect only when
  1249. BitTorrent Magnet URI is used. The filename is hex encoded info
  1250. hash with suffix .torrent. The directory to be saved is the same
  1251. directory where download file is saved. If the same file already
  1252. exists, metadata is not saved. See also <strong>--bt-metadata-only</strong>
  1253. option. Default: <em>false</em>
  1254. </p>
  1255. </dd>
  1256. <dt class="hdlist1">
  1257. <strong>--bt-seed-unverified</strong>[=<em>true</em>|<em>false</em>]
  1258. </dt>
  1259. <dd>
  1260. <p>
  1261. Seed previously downloaded files without verifying piece hashes.
  1262. Default: <em>false</em>
  1263. </p>
  1264. </dd>
  1265. <dt class="hdlist1">
  1266. <strong>--bt-stop-timeout</strong>=SEC
  1267. </dt>
  1268. <dd>
  1269. <p>
  1270. Stop BitTorrent download if download speed is 0 in consecutive SEC
  1271. seconds. If <em>0</em> is given, this feature is disabled. Default: <em>0</em>
  1272. </p>
  1273. </dd>
  1274. <dt class="hdlist1">
  1275. <strong>--bt-tracker-interval</strong>=SEC
  1276. </dt>
  1277. <dd>
  1278. <p>
  1279. Set the interval in seconds between tracker requests. This
  1280. completely overrides interval value and aria2 just uses this value
  1281. and ignores the min interval and interval value in the response of
  1282. tracker. If <em>0</em> is set, aria2 determines interval based on the
  1283. response of tracker and the download progress. Default: <em>0</em>
  1284. </p>
  1285. </dd>
  1286. <dt class="hdlist1">
  1287. <strong>--dht-entry-point</strong>=HOST:PORT
  1288. </dt>
  1289. <dd>
  1290. <p>
  1291. Set host and port as an entry point to DHT network.
  1292. </p>
  1293. </dd>
  1294. <dt class="hdlist1">
  1295. <strong>--dht-file-path</strong>=PATH
  1296. </dt>
  1297. <dd>
  1298. <p>
  1299. Change the DHT routing table file to PATH.
  1300. Default: <em>$HOME/.aria2/dht.dat</em>
  1301. </p>
  1302. </dd>
  1303. <dt class="hdlist1">
  1304. <strong>--dht-listen-port</strong>=PORT&#8230;
  1305. </dt>
  1306. <dd>
  1307. <p>
  1308. Set UDP listening port for DHT.
  1309. Multiple ports can be specified by using ",", for example: <em>6881,6885</em>.
  1310. You can also use "-" to specify a range: <em>6881-6999</em>. "," and "-" can be used
  1311. together.
  1312. Default: <em>6881-6999</em>
  1313. </p>
  1314. </dd>
  1315. </dl></div>
  1316. <div class="admonitionblock">
  1317. <table><tr>
  1318. <td class="icon">
  1319. <div class="title">Note</div>
  1320. </td>
  1321. <td class="content">Make sure that the specified ports are open for incoming UDP traffic.</td>
  1322. </tr></table>
  1323. </div>
  1324. <div class="dlist"><dl>
  1325. <dt class="hdlist1">
  1326. <strong>--enable-dht</strong>[=<em>true</em>|<em>false</em>]
  1327. </dt>
  1328. <dd>
  1329. <p>
  1330. Enable DHT functionality. If a private flag is set in a torrent, aria2
  1331. doesn&#8217;t use DHT for that download even if <em>true</em> is given.
  1332. Default: <em>true</em>
  1333. </p>
  1334. </dd>
  1335. <dt class="hdlist1">
  1336. <strong>--enable-peer-exchange</strong>[=<em>true</em>|<em>false</em>]
  1337. </dt>
  1338. <dd>
  1339. <p>
  1340. Enable Peer Exchange extension. If a private flag is set in a torrent, this
  1341. feature is disabled for that download even if <em>true</em> is given.
  1342. Default: <em>true</em>
  1343. </p>
  1344. </dd>
  1345. <dt class="hdlist1">
  1346. <strong>--follow-torrent</strong>=<em>true</em>|<em>false</em>|<em>mem</em>
  1347. </dt>
  1348. <dd>
  1349. <p>
  1350. If <em>true</em> or <em>mem</em> is specified, when a file whose suffix is ".torrent" or content
  1351. type is "application/x-bittorrent" is downloaded, aria2 parses it as a torrent
  1352. file and downloads files mentioned in it.
  1353. If <em>mem</em> is specified, a torrent file is not written to the disk, but is just
  1354. kept in memory.
  1355. If <em>false</em> is specified, the action mentioned above is not taken.
  1356. Default: <em>true</em>
  1357. </p>
  1358. </dd>
  1359. <dt class="hdlist1">
  1360. <strong>-O</strong>, <strong>--index-out</strong>=INDEX=PATH
  1361. </dt>
  1362. <dd>
  1363. <p>
  1364. Set file path for file with index=INDEX. You can find the file index
  1365. using the <strong>--show-files</strong> option. PATH is a relative path to the
  1366. path specified in <strong>--dir</strong> option. You can use this option multiple
  1367. times. Using this option, you can specify the output filenames of
  1368. BitTorrent downloads.
  1369. </p>
  1370. </dd>
  1371. <dt class="hdlist1">
  1372. <strong>--listen-port</strong>=PORT&#8230;
  1373. </dt>
  1374. <dd>
  1375. <p>
  1376. Set TCP port number for BitTorrent downloads.
  1377. Multiple ports can be specified by using ",", for example: <em>6881,6885</em>.
  1378. You can also use "-" to specify a range: <em>6881-6999</em>.
  1379. "," and "-" can be used together: <em>6881-6889,6999</em>.
  1380. Default: <em>6881-6999</em>
  1381. </p>
  1382. </dd>
  1383. </dl></div>
  1384. <div class="admonitionblock">
  1385. <table><tr>
  1386. <td class="icon">
  1387. <div class="title">Note</div>
  1388. </td>
  1389. <td class="content">Make sure that the specified ports are open for incoming TCP traffic.</td>
  1390. </tr></table>
  1391. </div>
  1392. <div class="dlist"><dl>
  1393. <dt class="hdlist1">
  1394. <strong>--max-overall-upload-limit</strong>=SPEED
  1395. </dt>
  1396. <dd>
  1397. <p>
  1398. Set max overall upload speed in bytes/sec.
  1399. <em>0</em> means unrestricted.
  1400. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1401. To limit the upload speed per torrent, use <strong>--max-upload-limit</strong> option.
  1402. Default: <em>0</em>
  1403. </p>
  1404. </dd>
  1405. <dt class="hdlist1">
  1406. <strong>-u</strong>, <strong>--max-upload-limit</strong>=SPEED
  1407. </dt>
  1408. <dd>
  1409. <p>
  1410. Set max upload speed per each torrent in bytes/sec.
  1411. <em>0</em> means unrestricted.
  1412. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1413. To limit the overall upload speed, use <strong>--max-overall-upload-limit</strong> option.
  1414. Default: <em>0</em>
  1415. </p>
  1416. </dd>
  1417. <dt class="hdlist1">
  1418. <strong>--peer-id-prefix</strong>=PEER_ID_PREFIX
  1419. </dt>
  1420. <dd>
  1421. <p>
  1422. Specify the prefix of peer ID. The peer ID in
  1423. BitTorrent is 20 byte length. If more than 20
  1424. bytes are specified, only first 20 bytes are
  1425. used. If less than 20 bytes are specified, random
  1426. byte data are added to make its length 20 bytes.
  1427. Default: <em>aria2/$VERSION-</em>, $VERSION is replaced by package version.
  1428. </p>
  1429. </dd>
  1430. <dt class="hdlist1">
  1431. <strong>--seed-ratio</strong>=RATIO
  1432. </dt>
  1433. <dd>
  1434. <p>
  1435. Specify share ratio. Seed completed torrents until share ratio reaches
  1436. RATIO.
  1437. You are strongly encouraged to specify equals or more than <em>1.0</em> here.
  1438. Specify <em>0.0</em> if you intend to do seeding regardless of share ratio.
  1439. If <strong>--seed-time</strong> option is specified along with this option, seeding ends when
  1440. at least one of the conditions is satisfied.
  1441. Default: <em>1.0</em>
  1442. </p>
  1443. </dd>
  1444. <dt class="hdlist1">
  1445. <strong>--seed-time</strong>=MINUTES
  1446. </dt>
  1447. <dd>
  1448. <p>
  1449. Specify seeding time in minutes. Also see the <strong>--seed-ratio</strong> option.
  1450. </p>
  1451. </dd>
  1452. <dt class="hdlist1">
  1453. <strong>-T</strong>, <strong>--torrent-file</strong>=TORRENT_FILE
  1454. </dt>
  1455. <dd>
  1456. <p>
  1457. The path to the .torrent file. You are not required to use this
  1458. option because you can specify .torrent files without <strong>-T</strong>.
  1459. </p>
  1460. </dd>
  1461. </dl></div>
  1462. <h3 id="_metalink_specific_options">Metalink Specific Options</h3><div style="clear:left"></div>
  1463. <div class="dlist"><dl>
  1464. <dt class="hdlist1">
  1465. <strong>--follow-metalink</strong>=<em>true</em>|<em>false</em>|<em>mem</em>
  1466. </dt>
  1467. <dd>
  1468. <p>
  1469. If <em>true</em> or <em>mem</em> is specified, when a file whose suffix is ".metalink" or content
  1470. type of "application/metalink+xml" is downloaded, aria2 parses it as a metalink
  1471. file and downloads files mentioned in it.
  1472. If <em>mem</em> is specified, a metalink file is not written to the disk, but is just
  1473. kept in memory.
  1474. If <em>false</em> is specified, the action mentioned above is not taken.
  1475. Default: <em>true</em>
  1476. </p>
  1477. </dd>
  1478. <dt class="hdlist1">
  1479. <strong>-M</strong>, <strong>--metalink-file</strong>=METALINK_FILE
  1480. </dt>
  1481. <dd>
  1482. <p>
  1483. The file path to .metalink file. Reads input from stdin when <em>-</em> is
  1484. specified. You are not required to use this option because you can
  1485. specify .metalink files without <strong>-M</strong>.
  1486. </p>
  1487. </dd>
  1488. <dt class="hdlist1">
  1489. <strong>-C</strong>, <strong>--metalink-servers</strong>=NUM_SERVERS
  1490. </dt>
  1491. <dd>
  1492. <p>
  1493. The number of servers to connect to simultaneously.
  1494. Some Metalinks regulate the number of servers to connect.
  1495. aria2 strictly respects them.
  1496. This means that if Metalink defines the maxconnections attribute lower
  1497. than NUM_SERVERS, then aria2 uses the value of maxconnections attribute
  1498. instead of NUM_SERVERS.
  1499. See also <strong>-s</strong> and <strong>-j</strong> options.
  1500. Default: <em>5</em>
  1501. </p>
  1502. </dd>
  1503. <dt class="hdlist1">
  1504. <strong>--metalink-language</strong>=LANGUAGE
  1505. </dt>
  1506. <dd>
  1507. <p>
  1508. The language of the file to download.
  1509. </p>
  1510. </dd>
  1511. <dt class="hdlist1">
  1512. <strong>--metalink-location</strong>=LOCATION[,&#8230;]
  1513. </dt>
  1514. <dd>
  1515. <p>
  1516. The location of the preferred server.
  1517. A comma-delimited list of locations is acceptable, for example, <em>jp,us</em>.
  1518. </p>
  1519. </dd>
  1520. <dt class="hdlist1">
  1521. <strong>--metalink-os</strong>=OS
  1522. </dt>
  1523. <dd>
  1524. <p>
  1525. The operating system of the file to download.
  1526. </p>
  1527. </dd>
  1528. <dt class="hdlist1">
  1529. <strong>--metalink-version</strong>=VERSION
  1530. </dt>
  1531. <dd>
  1532. <p>
  1533. The version of the file to download.
  1534. </p>
  1535. </dd>
  1536. <dt class="hdlist1">
  1537. <strong>--metalink-preferred-protocol</strong>=PROTO
  1538. </dt>
  1539. <dd>
  1540. <p>
  1541. Specify preferred protocol.
  1542. The possible values are <em>http</em>, <em>https</em>, <em>ftp</em> and <em>none</em>.
  1543. Specify <em>none</em> to disable this feature.
  1544. Default: <em>none</em>
  1545. </p>
  1546. </dd>
  1547. <dt class="hdlist1">
  1548. <strong>--metalink-enable-unique-protocol</strong>=<em>true</em>|<em>false</em>
  1549. </dt>
  1550. <dd>
  1551. <p>
  1552. If <em>true</em> is given and several protocols are available for a mirror in a
  1553. metalink file, aria2 uses one of them.
  1554. Use <strong>--metalink-preferred-protocol</strong> option to specify the preference of
  1555. protocol.
  1556. Default: <em>true</em>
  1557. </p>
  1558. </dd>
  1559. </dl></div>
  1560. <h3 id="_xml_rpc_options">XML-RPC Options</h3><div style="clear:left"></div>
  1561. <div class="dlist"><dl>
  1562. <dt class="hdlist1">
  1563. <strong>--enable-xml-rpc</strong>[=<em>true</em>|<em>false</em>]
  1564. </dt>
  1565. <dd>
  1566. <p>
  1567. Enable XML-RPC server. It is strongly recommended to set username
  1568. and password using <strong>--xml-rpc-user</strong> and <strong>--xml-rpc-passwd</strong>
  1569. option. See also <strong>--xml-rpc-listen-port</strong> option. Default: <em>false</em>
  1570. </p>
  1571. </dd>
  1572. <dt class="hdlist1">
  1573. <strong>--xml-rpc-listen-all</strong>[=<em>true</em>|<em>false</em>]
  1574. </dt>
  1575. <dd>
  1576. <p>
  1577. Listen incoming XML-RPC requests on all network interfaces. If false
  1578. is given, listen only on local loopback interface. Default: <em>false</em>
  1579. </p>
  1580. </dd>
  1581. <dt class="hdlist1">
  1582. <strong>--xml-rpc-listen-port</strong>=PORT
  1583. </dt>
  1584. <dd>
  1585. <p>
  1586. Specify a port number for XML-RPC server to listen to. Possible
  1587. Values: <em>1024</em>-<em>65535</em> Default: <em>6800</em>
  1588. </p>
  1589. </dd>
  1590. <dt class="hdlist1">
  1591. <strong>--xml-rpc-max-request-size</strong>=SIZE
  1592. </dt>
  1593. <dd>
  1594. <p>
  1595. Set max size of XML-RPC request. If aria2 detects the request is
  1596. more than SIZE bytes, it drops connection. Default: <em>2M</em>
  1597. </p>
  1598. </dd>
  1599. <dt class="hdlist1">
  1600. <strong>--xml-rpc-passwd</strong>=PASSWD
  1601. </dt>
  1602. <dd>
  1603. <p>
  1604. Set XML-RPC password.
  1605. </p>
  1606. </dd>
  1607. <dt class="hdlist1">
  1608. <strong>--xml-rpc-user</strong>=USER
  1609. </dt>
  1610. <dd>
  1611. <p>
  1612. Set XML-RPC user.
  1613. </p>
  1614. </dd>
  1615. </dl></div>
  1616. <h3 id="_advanced_options">Advanced Options</h3><div style="clear:left"></div>
  1617. <div class="dlist"><dl>
  1618. <dt class="hdlist1">
  1619. <strong>--allow-overwrite</strong>=<em>true</em>|<em>false</em>
  1620. </dt>
  1621. <dd>
  1622. <p>
  1623. Restart download from scratch if the corresponding control file
  1624. doesn&#8217;t exist. See also <strong>--auto-file-renaming</strong> option. Default:
  1625. <em>false</em>
  1626. </p>
  1627. </dd>
  1628. <dt class="hdlist1">
  1629. <strong>--allow-piece-length-change</strong>=<em>true</em>|<em>false</em>
  1630. </dt>
  1631. <dd>
  1632. <p>
  1633. If false is given, aria2 aborts download when a piece length is different
  1634. from one in a control file.
  1635. If true is given, you can proceed but some download progress will be lost.
  1636. Default: <em>false</em>
  1637. </p>
  1638. </dd>
  1639. <dt class="hdlist1">
  1640. <strong>--async-dns</strong>[=<em>true</em>|<em>false</em>]
  1641. </dt>
  1642. <dd>
  1643. <p>
  1644. Enable asynchronous DNS.
  1645. Default: <em>true</em>
  1646. </p>
  1647. </dd>
  1648. <dt class="hdlist1">
  1649. <strong>--auto-file-renaming</strong>[=<em>true</em>|<em>false</em>]
  1650. </dt>
  1651. <dd>
  1652. <p>
  1653. Rename file name if the same file already exists.
  1654. This option works only in HTTP(S)/FTP download.
  1655. The new file name has a dot and a number(1..9999) appended.
  1656. Default: <em>true</em>
  1657. </p>
  1658. </dd>
  1659. <dt class="hdlist1">
  1660. <strong>--auto-save-interval</strong>=SEC
  1661. </dt>
  1662. <dd>
  1663. <p>
  1664. Save a control file(*.aria2) every SEC seconds.
  1665. If <em>0</em> is given, a control file is not saved during download. aria2 saves a
  1666. control file when it stops regardless of the value.
  1667. The possible values are between <em>0</em> to <em>600</em>.
  1668. Default: <em>60</em>
  1669. </p>
  1670. </dd>
  1671. <dt class="hdlist1">
  1672. <strong>--conf-path</strong>=PATH
  1673. </dt>
  1674. <dd>
  1675. <p>
  1676. Change the configuration file path to PATH.
  1677. Default: <em>$HOME/.aria2/aria2.conf</em>
  1678. </p>
  1679. </dd>
  1680. <dt class="hdlist1">
  1681. <strong>-D</strong>, <strong>--daemon</strong>
  1682. </dt>
  1683. <dd>
  1684. <p>
  1685. Run as daemon. The current working directory will be changed to <em>/</em>
  1686. and standard input, standard output and standard error will be
  1687. redirected to <em>/dev/null</em>. Default: <em>false</em>
  1688. </p>
  1689. </dd>
  1690. <dt class="hdlist1">
  1691. <strong>--disable-ipv6</strong>[=<em>true</em>|<em>false</em>]
  1692. </dt>
  1693. <dd>
  1694. <p>
  1695. Disable IPv6. This is useful if you have to use broken DNS and want
  1696. to avoid terribly slow AAAA record lookup. Default: <em>false</em>
  1697. </p>
  1698. </dd>
  1699. <dt class="hdlist1">
  1700. <strong>--enable-direct-io</strong>[=<em>true</em>|<em>false</em>]
  1701. </dt>
  1702. <dd>
  1703. <p>
  1704. Enable directI/O, which lowers cpu usage while allocating/checking files.
  1705. Turn off if you encounter any error.
  1706. Default: <em>true</em>
  1707. </p>
  1708. </dd>
  1709. <dt class="hdlist1">
  1710. <strong>--event-poll</strong>=POLL
  1711. </dt>
  1712. <dd>
  1713. <p>
  1714. Specify the method for polling events. The possible Values are
  1715. <em>epoll</em> and <em>select</em>. If you use recent Linux that has epoll, then
  1716. the default value is <em>epoll</em>. Otherwise, the default value is
  1717. <em>select</em>.
  1718. </p>
  1719. </dd>
  1720. <dt class="hdlist1">
  1721. <strong>--file-allocation</strong>=METHOD
  1722. </dt>
  1723. <dd>
  1724. <p>
  1725. Specify file allocation method.
  1726. <em>none</em> doesn&#8217;t pre-allocate file space. <em>prealloc</em> pre-allocates file space
  1727. before download begins. This may take some time depending on the size of the
  1728. file.
  1729. If you are using newer file systems such as ext4
  1730. (with extents support), btrfs or xfs, <em>falloc</em> is
  1731. your best choice. It allocates large(few GiB)
  1732. files almost instantly. Don&#8217;t use <em>falloc</em> with
  1733. legacy file systems such as ext3 because it takes
  1734. almost same time as <em>prealloc</em> and it blocks aria2
  1735. entirely until allocation finishes. <em>falloc</em> may
  1736. not be available if your system doesn&#8217;t have
  1737. <strong>posix_fallocate</strong>() function.
  1738. Possible Values: <em>none</em>, <em>prealloc</em>, <em>falloc</em>
  1739. Default: <em>prealloc</em>
  1740. </p>
  1741. </dd>
  1742. <dt class="hdlist1">
  1743. <strong>--human-readable</strong>[=<em>true</em>|<em>false</em>]
  1744. </dt>
  1745. <dd>
  1746. <p>
  1747. Print sizes and speed in human readable format (e.g., 1.2Ki, 3.4Mi)
  1748. in the console readout. Default: <em>true</em>
  1749. </p>
  1750. </dd>
  1751. <dt class="hdlist1">
  1752. <strong>--interface</strong>=INTERFACE
  1753. </dt>
  1754. <dd>
  1755. <p>
  1756. Bind sockets to given interface. You can specify interface name, IP
  1757. address and hostname.
  1758. Possible Values: interface, IP address, hostname
  1759. </p>
  1760. </dd>
  1761. </dl></div>
  1762. <div class="admonitionblock">
  1763. <table><tr>
  1764. <td class="icon">
  1765. <div class="title">Note</div>
  1766. </td>
  1767. <td class="content">If an interface has multiple addresses, it is highly recommended to
  1768. specify IP address explicitly. See also <strong>--disable-ipv6</strong>. If your
  1769. system doesn&#8217;t have getifaddrs(), this option doesn&#8217;t accept interface
  1770. name.</td>
  1771. </tr></table>
  1772. </div>
  1773. <div class="dlist"><dl>
  1774. <dt class="hdlist1">
  1775. <strong>--log-level</strong>=LEVEL
  1776. </dt>
  1777. <dd>
  1778. <p>
  1779. Set log level to output.
  1780. LEVEL is either <em>debug</em>, <em>info</em>, <em>notice</em>, <em>warn</em> or <em>error</em>.
  1781. Default: <em>debug</em>
  1782. </p>
  1783. </dd>
  1784. <dt class="hdlist1">
  1785. <strong>--on-download-complete</strong>=COMMAND
  1786. </dt>
  1787. <dd>
  1788. <p>
  1789. Set the command to be executed when download completes. See
  1790. <strong>--on-download-start</strong> option for the requirement of COMMAND. See
  1791. also <strong>--on-download-stop</strong> option. Possible Values:
  1792. <em>/path/to/command</em>
  1793. </p>
  1794. </dd>
  1795. <dt class="hdlist1">
  1796. <strong>--on-download-error</strong>=COMMAND
  1797. </dt>
  1798. <dd>
  1799. <p>
  1800. Set the command to be executed when download aborts due to error.
  1801. See <strong>--on-download-start</strong> option for the requirement of COMMAND.
  1802. See also <strong>--on-download-stop</strong> option. Possible Values:
  1803. <em>/path/to/command</em>
  1804. </p>
  1805. </dd>
  1806. <dt class="hdlist1">
  1807. <strong>--on-download-start</strong>=COMMAND
  1808. </dt>
  1809. <dd>
  1810. <p>
  1811. Set the command to be executed when download starts up. COMMAND must
  1812. take just one argument and GID is passed to COMMAND as a first
  1813. argument. Possible Values: <em>/path/to/command</em>
  1814. </p>
  1815. </dd>
  1816. <dt class="hdlist1">
  1817. <strong>--on-download-stop</strong>=COMMAND
  1818. </dt>
  1819. <dd>
  1820. <p>
  1821. Set the command to be executed when download stops. You can override
  1822. the command to be executed for particular download result using
  1823. <strong>--on-download-complete</strong> and <strong>--on-download-error</strong>. If they are
  1824. specified, command specified in this option is not executed. See
  1825. <strong>--on-download-start</strong> option for the requirement of COMMAND.
  1826. Possible Values: <em>/path/to/command</em>
  1827. </p>
  1828. </dd>
  1829. <dt class="hdlist1">
  1830. <strong>--summary-interval</strong>=SEC
  1831. </dt>
  1832. <dd>
  1833. <p>
  1834. Set interval in seconds to output download progress summary.
  1835. Setting <em>0</em> suppresses the output.
  1836. Default: <em>60</em>
  1837. </p>
  1838. </dd>
  1839. </dl></div>
  1840. <div class="admonitionblock">
  1841. <table><tr>
  1842. <td class="icon">
  1843. <div class="title">Note</div>
  1844. </td>
  1845. <td class="content">In multi file torrent downloads, the files adjacent forward to the specified files
  1846. are also allocated if they share the same piece.</td>
  1847. </tr></table>
  1848. </div>
  1849. <div class="dlist"><dl>
  1850. <dt class="hdlist1">
  1851. <strong>-Z</strong>, <strong>--force-sequential</strong>[=<em>true</em>|<em>false</em>]
  1852. </dt>
  1853. <dd>
  1854. <p>
  1855. Fetch URIs in the command-line sequentially and download each URI in a
  1856. separate session, like the usual command-line download utilities.
  1857. Default: <em>false</em>
  1858. </p>
  1859. </dd>
  1860. <dt class="hdlist1">
  1861. <strong>--max-overall-download-limit</strong>=SPEED
  1862. </dt>
  1863. <dd>
  1864. <p>
  1865. Set max overall download speed in bytes/sec. <em>0</em> means
  1866. unrestricted. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K). To
  1867. limit the download speed per download, use <strong>--max-download-limit</strong>
  1868. option. Default: <em>0</em>
  1869. </p>
  1870. </dd>
  1871. <dt class="hdlist1">
  1872. <strong>--max-download-limit</strong>=SPEED
  1873. </dt>
  1874. <dd>
  1875. <p>
  1876. Set max download speed per each download in bytes/sec. <em>0</em> means
  1877. unrestricted. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K). To
  1878. limit the overall download speed, use <strong>--max-overall-download-limit</strong>
  1879. option. Default: <em>0</em>
  1880. </p>
  1881. </dd>
  1882. <dt class="hdlist1">
  1883. <strong>--no-conf</strong>
  1884. </dt>
  1885. <dd>
  1886. <p>
  1887. Disable loading aria2.conf file.
  1888. </p>
  1889. </dd>
  1890. <dt class="hdlist1">
  1891. <strong>--no-file-allocation-limit</strong>=SIZE
  1892. </dt>
  1893. <dd>
  1894. <p>
  1895. No file allocation is made for files whose size is smaller than SIZE.
  1896. You can append <em>K</em> or <em>M</em>(1K = 1024, 1M = 1024K).
  1897. Default: <em>5M</em>
  1898. </p>
  1899. </dd>
  1900. <dt class="hdlist1">
  1901. <strong>-P</strong>, <strong>--parameterized-uri</strong>[=<em>true</em>|<em>false</em>]
  1902. </dt>
  1903. <dd>
  1904. <p>
  1905. Enable parameterized URI support.
  1906. You can specify set of parts: <em>http://{sv1,sv2,sv3}/foo.iso</em>.
  1907. Also you can specify numeric sequences with step counter:
  1908. <em>http://host/image[000-100:2].img</em>.
  1909. A step counter can be omitted.
  1910. If all URIs do not point to the same file, such as the second example above,
  1911. -Z option is required.
  1912. Default: <em>false</em>
  1913. </p>
  1914. </dd>
  1915. <dt class="hdlist1">
  1916. <strong>-q</strong>, <strong>--quiet</strong>[=<em>true</em>|<em>false</em>]
  1917. </dt>
  1918. <dd>
  1919. <p>
  1920. Make aria2 quiet (no console output).
  1921. Default: <em>false</em>
  1922. </p>
  1923. </dd>
  1924. <dt class="hdlist1">
  1925. <strong>--realtime-chunk-checksum</strong>=<em>true</em>|<em>false</em>
  1926. </dt>
  1927. <dd>
  1928. <p>
  1929. Validate chunk of data by calculating checksum while downloading a file if
  1930. chunk checksums are provided.
  1931. Default: <em>true</em>
  1932. </p>
  1933. </dd>
  1934. <dt class="hdlist1">
  1935. <strong>--stop</strong>=SEC
  1936. </dt>
  1937. <dd>
  1938. <p>
  1939. Stop application after SEC seconds has passed.
  1940. If <em>0</em> is given, this feature is disabled.
  1941. Default: <em>0</em>
  1942. </p>
  1943. </dd>
  1944. <dt class="hdlist1">
  1945. <strong>-v</strong>, <strong>--version</strong>
  1946. </dt>
  1947. <dd>
  1948. <p>
  1949. Print the version number, copyright and the configuration information and
  1950. exit.
  1951. </p>
  1952. </dd>
  1953. </dl></div>
  1954. <h3 id="_options_that_take_an_optional_argument">Options That Take An Optional Argument</h3><div style="clear:left"></div>
  1955. <div class="paragraph"><p>The options that have its argument surrounded by square brackets([])
  1956. take an optional argument. Usually omiting the argument is evaluated to <em>true</em>.
  1957. If you use short form of these options(such as <em>-V</em>) and give
  1958. an argument, then the option name and its argument should be concatenated(e.g.
  1959. <em>-Vfalse</em>). If any spaces are inserted between the option name and the argument,
  1960. the argument will be treated as URI and usually this is not what you expect.</p></div>
  1961. <h3 id="_uri_magnet_torrent_file_metalink_file">URI, MAGNET, TORRENT_FILE, METALINK_FILE</h3><div style="clear:left"></div>
  1962. <div class="paragraph"><p>You can specify multiple URLs in command-line. Unless you specify
  1963. <strong>-Z</strong> option, all URLs must point to the same file or downloading will
  1964. fail.</p></div>
  1965. <div class="paragraph"><p>You can specify arbitrary number of BitTorrent Magnet URI. Please note
  1966. that they are always treated as a separate download. Both hex encoded
  1967. 40 characters Info Hash and Base32 encoded 32 characters Info Hash are
  1968. supported. The multiple "tr" parameters are supported. Because
  1969. BitTorrent Magnet URI is likely to contain "&amp;" character, it is highly
  1970. recommended to always quote URI with single(') or double(") quotation.
  1971. It is strongly recommended to enable DHT especially when "tr"
  1972. parameter is missing. See <a href="http://www.bittorrent.org/beps/bep_0009.html">http://www.bittorrent.org/beps/bep_0009.html</a>
  1973. for more details about BitTorrent Magnet URI.</p></div>
  1974. <div class="paragraph"><p>You can also specify arbitrary number of torrent files and metalink files
  1975. stored on a local drive. Please note that they are always treated as a
  1976. separate download.</p></div>
  1977. <div class="paragraph"><p>You can specify both torrent file with -T option and URLs. By doing
  1978. this, you can download a file from both torrent swarm and HTTP(S)/FTP
  1979. server at the same time, while the data from HTTP(S)/FTP are uploaded
  1980. to the torrent swarm. For single file torrents, URL can be a complete
  1981. URL pointing to the resource or if URL ends with /, name in torrent
  1982. file in torrent is added. For multi-file torrents, name and path are
  1983. added to form a URL for each file.</p></div>
  1984. <div class="admonitionblock">
  1985. <table><tr>
  1986. <td class="icon">
  1987. <div class="title">Note</div>
  1988. </td>
  1989. <td class="content">Make sure that URL is quoted with single(') or double(") quotation if it
  1990. contains "&amp;" or any characters that have special meaning in shell.</td>
  1991. </tr></table>
  1992. </div>
  1993. <h3 id="_resuming_download">Resuming Download</h3><div style="clear:left"></div>
  1994. <div class="paragraph"><p>Usually, you can resume transfer by just issuing same command(aria2c
  1995. URL) if the previous transfer is made by aria2.</p></div>
  1996. <div class="paragraph"><p>If the previous transfer is made by a browser or wget like sequential
  1997. download manager, then use -c option to continue the transfer(aria2c
  1998. <strong>-c</strong> URL).</p></div>
  1999. </div>
  2000. <h2 id="_exit_status">EXIT STATUS</h2>
  2001. <div class="sectionbody">
  2002. <div class="paragraph"><p>Because aria2 can handle multiple downloads at once, it encounters
  2003. lots of errors in a session. aria2 returns the following exit status
  2004. based on the last error encountered.</p></div>
  2005. <div class="dlist"><dl>
  2006. <dt class="hdlist1">
  2007. <strong>0</strong>
  2008. </dt>
  2009. <dd>
  2010. <p>
  2011. If all downloads are successful.
  2012. </p>
  2013. </dd>
  2014. <dt class="hdlist1">
  2015. <strong>1</strong>
  2016. </dt>
  2017. <dd>
  2018. <p>
  2019. If an unknown error occurs.
  2020. </p>
  2021. </dd>
  2022. <dt class="hdlist1">
  2023. <strong>2</strong>
  2024. </dt>
  2025. <dd>
  2026. <p>
  2027. If time out occurs.
  2028. </p>
  2029. </dd>
  2030. <dt class="hdlist1">
  2031. <strong>3</strong>
  2032. </dt>
  2033. <dd>
  2034. <p>
  2035. If a resource is not found.
  2036. </p>
  2037. </dd>
  2038. <dt class="hdlist1">
  2039. <strong>4</strong>
  2040. </dt>
  2041. <dd>
  2042. <p>
  2043. If aria2 sees the specfied number of "resource not found" error.
  2044. See <strong>--max-file-not-found</strong> option).
  2045. </p>
  2046. </dd>
  2047. <dt class="hdlist1">
  2048. <strong>5</strong>
  2049. </dt>
  2050. <dd>
  2051. <p>
  2052. If a download aborts because download speed is too slow.
  2053. See <strong>--lowest-speed-limit</strong> option)
  2054. </p>
  2055. </dd>
  2056. <dt class="hdlist1">
  2057. <strong>6</strong>
  2058. </dt>
  2059. <dd>
  2060. <p>
  2061. If network problem occurs.
  2062. </p>
  2063. </dd>
  2064. <dt class="hdlist1">
  2065. <strong>7</strong>
  2066. </dt>
  2067. <dd>
  2068. <p>
  2069. If there are unfinished downloads. This error is only reported if
  2070. all finished downloads are successful and there are unfinished
  2071. downloads in a queue when aria2 exits by pressing Ctrl-C by an user
  2072. or sending TERM or INT signal.
  2073. </p>
  2074. </dd>
  2075. </dl></div>
  2076. <div class="admonitionblock">
  2077. <table><tr>
  2078. <td class="icon">
  2079. <div class="title">Note</div>
  2080. </td>
  2081. <td class="content">An error occurred in a finished download will not be reported
  2082. as exit status.</td>
  2083. </tr></table>
  2084. </div>
  2085. </div>
  2086. <h2 id="_environment">ENVIRONMENT</h2>
  2087. <div class="sectionbody">
  2088. <div class="paragraph"><p>aria2 recognizes the following environment variables.</p></div>
  2089. <div class="dlist"><dl>
  2090. <dt class="hdlist1">
  2091. http_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2092. </dt>
  2093. <dd>
  2094. <p>
  2095. Specify proxy server for use in HTTP.
  2096. Overrides http-proxy value in configuration file.
  2097. The command-line option <strong>--http-proxy</strong> overrides this value.
  2098. </p>
  2099. </dd>
  2100. <dt class="hdlist1">
  2101. https_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2102. </dt>
  2103. <dd>
  2104. <p>
  2105. Specify proxy server for use in HTTPS.
  2106. Overrides https-proxy value in configuration file.
  2107. The command-line option <strong>--https-proxy</strong> overrides this value.
  2108. </p>
  2109. </dd>
  2110. <dt class="hdlist1">
  2111. ftp_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2112. </dt>
  2113. <dd>
  2114. <p>
  2115. Specify proxy server for use in FTP.
  2116. Overrides ftp-proxy value in configuration file.
  2117. The command-line option <strong>--ftp-proxy</strong> overrides this value.
  2118. </p>
  2119. </dd>
  2120. <dt class="hdlist1">
  2121. all_proxy [<a href="http://][USER:PASSWORD@]HOST[:PORT">http://][USER:PASSWORD@]HOST[:PORT</a>]
  2122. </dt>
  2123. <dd>
  2124. <p>
  2125. Specify proxy server for use if no protocol-specific proxy is specified.
  2126. Overrides all-proxy value in configuration file.
  2127. The command-line option <strong>--all-proxy</strong> overrides this value.
  2128. </p>
  2129. </dd>
  2130. <dt class="hdlist1">
  2131. no_proxy [DOMAIN,&#8230;]
  2132. </dt>
  2133. <dd>
  2134. <p>
  2135. Specify comma-separated hostname or domains to which proxy should not be used.
  2136. Overrides no-proxy value in configuration file.
  2137. The command-line option <strong>--no-proxy</strong> overrides this value.
  2138. </p>
  2139. </dd>
  2140. </dl></div>
  2141. </div>
  2142. <h2 id="_files">FILES</h2>
  2143. <div class="sectionbody">
  2144. <h3 id="_aria2_conf">aria2.conf</h3><div style="clear:left"></div>
  2145. <div class="paragraph"><p>By default, aria2 parses <em>$HOME/.aria2/aria2.conf</em> as a configuraiton
  2146. file. You can specify the path to configuration file using
  2147. <strong>--conf-path</strong> option. If you don&#8217;t want to use the configuraitonf
  2148. file, use <strong>--no-conf</strong> option.</p></div>
  2149. <div class="paragraph"><p>The configuration file is a text file and has 1 option per each
  2150. line. In each line, you can specify name-value pair in the format:
  2151. NAME=VALUE, where name is the long command-line option name without
  2152. "--" prefix. You can use same syntax for the command-line option. The
  2153. lines beginning "#" are treated as comments.</p></div>
  2154. <div class="listingblock">
  2155. <div class="content">
  2156. <pre><tt># sample configuration file for aria2c
  2157. listen-port=60000
  2158. dht-listen-port=60000
  2159. seed-ratio=1.0
  2160. max-upload-limit=50K
  2161. ftp-pasv=true</tt></pre>
  2162. </div></div>
  2163. <h3 id="_dht_dat">dht.dat</h3><div style="clear:left"></div>
  2164. <div class="paragraph"><p>By default, the routing table of DHT is saved to the path $HOME/.aria2/dht.dat.</p></div>
  2165. <h3 id="_control_file">Control File</h3><div style="clear:left"></div>
  2166. <div class="paragraph"><p>aria2 uses a control file to track the progress of a download. A
  2167. control file is placed in the same directory as the downloading file
  2168. and its filename is the filename of downloading file with ".aria2"
  2169. appended. For example, if you are downloading file.zip, then the
  2170. control file should be file.zip.aria2. (There is a exception for this
  2171. naming convention. If you are downloading a multi torrent, its
  2172. control file is the "top directory" name of the torrent with ".aria2"
  2173. appended. The "top directory" name is a value of "name" key in "info"
  2174. directory in a torrent file.)</p></div>
  2175. <div class="paragraph"><p>Usually a control file is deleted once download completed. If aria2
  2176. decides that download cannot be resumed(for example, when downloading
  2177. a file from a HTTP server which doesn&#8217;t support resume), a control
  2178. file is not created.</p></div>
  2179. <div class="paragraph"><p>Normally if you lose a control file, you cannot resume download. But
  2180. if you have a torrent or metalink with chunk checksums for the file,
  2181. you can resume the download without a control file by giving -V option
  2182. to aria2c in command-line.</p></div>
  2183. <h3 id="_input_file">Input File</h3><div style="clear:left"></div>
  2184. <div class="paragraph"><p>The input file can contain a list of URIs for aria2 to download. You
  2185. can specify multiple URIs for a single entity: separate URIs on a
  2186. single line using the TAB character.</p></div>
  2187. <div class="paragraph"><p>Each line is treated as if it is provided in command-line argument.
  2188. Therefore they are affected by <strong>-Z</strong> and <strong>-P</strong> options.</p></div>
  2189. <div class="paragraph"><p>Additionally, the following options can be specified after each line
  2190. of URIs. These optional lines must start with white space(s).</p></div>
  2191. <div class="ulist"><ul>
  2192. <li>
  2193. <p>
  2194. dir
  2195. </p>
  2196. </li>
  2197. <li>
  2198. <p>
  2199. check-integrity
  2200. </p>
  2201. </li>
  2202. <li>
  2203. <p>
  2204. continue
  2205. </p>
  2206. </li>
  2207. <li>
  2208. <p>
  2209. all-proxy
  2210. </p>
  2211. </li>
  2212. <li>
  2213. <p>
  2214. connect-timeout
  2215. </p>
  2216. </li>
  2217. <li>
  2218. <p>
  2219. dry-run
  2220. </p>
  2221. </li>
  2222. <li>
  2223. <p>
  2224. lowest-speed-limit
  2225. </p>
  2226. </li>
  2227. <li>
  2228. <p>
  2229. max-file-not-found
  2230. </p>
  2231. </li>
  2232. <li>
  2233. <p>
  2234. max-tries
  2235. </p>
  2236. </li>
  2237. <li>
  2238. <p>
  2239. no-proxy
  2240. </p>
  2241. </li>
  2242. <li>
  2243. <p>
  2244. out
  2245. </p>
  2246. </li>
  2247. <li>
  2248. <p>
  2249. proxy-method
  2250. </p>
  2251. </li>
  2252. <li>
  2253. <p>
  2254. remote-time
  2255. </p>
  2256. </li>
  2257. <li>
  2258. <p>
  2259. split
  2260. </p>
  2261. </li>
  2262. <li>
  2263. <p>
  2264. timeout
  2265. </p>
  2266. </li>
  2267. <li>
  2268. <p>
  2269. http-auth-challenge
  2270. </p>
  2271. </li>
  2272. <li>
  2273. <p>
  2274. http-no-cache
  2275. </p>
  2276. </li>
  2277. <li>
  2278. <p>
  2279. http-user
  2280. </p>
  2281. </li>
  2282. <li>
  2283. <p>
  2284. http-passwd
  2285. </p>
  2286. </li>
  2287. <li>
  2288. <p>
  2289. http-proxy
  2290. </p>
  2291. </li>
  2292. <li>
  2293. <p>
  2294. https-proxy
  2295. </p>
  2296. </li>
  2297. <li>
  2298. <p>
  2299. referer
  2300. </p>
  2301. </li>
  2302. <li>
  2303. <p>
  2304. enable-http-keep-alive
  2305. </p>
  2306. </li>
  2307. <li>
  2308. <p>
  2309. enable-http-pipelining
  2310. </p>
  2311. </li>
  2312. <li>
  2313. <p>
  2314. header
  2315. </p>
  2316. </li>
  2317. <li>
  2318. <p>
  2319. use-head
  2320. </p>
  2321. </li>
  2322. <li>
  2323. <p>
  2324. user-agent
  2325. </p>
  2326. </li>
  2327. <li>
  2328. <p>
  2329. ftp-user
  2330. </p>
  2331. </li>
  2332. <li>
  2333. <p>
  2334. ftp-passwd
  2335. </p>
  2336. </li>
  2337. <li>
  2338. <p>
  2339. ftp-pasv
  2340. </p>
  2341. </li>
  2342. <li>
  2343. <p>
  2344. ftp-proxy
  2345. </p>
  2346. </li>
  2347. <li>
  2348. <p>
  2349. ftp-type
  2350. </p>
  2351. </li>
  2352. <li>
  2353. <p>
  2354. ftp-reuse-connection
  2355. </p>
  2356. </li>
  2357. <li>
  2358. <p>
  2359. no-netrc
  2360. </p>
  2361. </li>
  2362. <li>
  2363. <p>
  2364. select-file
  2365. </p>
  2366. </li>
  2367. <li>
  2368. <p>
  2369. bt-external-ip
  2370. </p>
  2371. </li>
  2372. <li>
  2373. <p>
  2374. bt-hash-check-seed
  2375. </p>
  2376. </li>
  2377. <li>
  2378. <p>
  2379. bt-max-open-files
  2380. </p>
  2381. </li>
  2382. <li>
  2383. <p>
  2384. bt-max-peers
  2385. </p>
  2386. </li>
  2387. <li>
  2388. <p>
  2389. bt-metadata-only
  2390. </p>
  2391. </li>
  2392. <li>
  2393. <p>
  2394. bt-min-crypto-level
  2395. </p>
  2396. </li>
  2397. <li>
  2398. <p>
  2399. bt-prioritize-piece
  2400. </p>
  2401. </li>
  2402. <li>
  2403. <p>
  2404. bt-require-crypto
  2405. </p>
  2406. </li>
  2407. <li>
  2408. <p>
  2409. bt-request-peer-speed-limit
  2410. </p>
  2411. </li>
  2412. <li>
  2413. <p>
  2414. bt-save-metadata
  2415. </p>
  2416. </li>
  2417. <li>
  2418. <p>
  2419. bt-seed-unverified
  2420. </p>
  2421. </li>
  2422. <li>
  2423. <p>
  2424. bt-stop-timeout
  2425. </p>
  2426. </li>
  2427. <li>
  2428. <p>
  2429. bt-tracker-interval
  2430. </p>
  2431. </li>
  2432. <li>
  2433. <p>
  2434. enable-peer-exchange
  2435. </p>
  2436. </li>
  2437. <li>
  2438. <p>
  2439. follow-torrent
  2440. </p>
  2441. </li>
  2442. <li>
  2443. <p>
  2444. index-out
  2445. </p>
  2446. </li>
  2447. <li>
  2448. <p>
  2449. max-upload-limit
  2450. </p>
  2451. </li>
  2452. <li>
  2453. <p>
  2454. seed-ratio
  2455. </p>
  2456. </li>
  2457. <li>
  2458. <p>
  2459. seed-time
  2460. </p>
  2461. </li>
  2462. <li>
  2463. <p>
  2464. follow-metalink
  2465. </p>
  2466. </li>
  2467. <li>
  2468. <p>
  2469. metalink-servers
  2470. </p>
  2471. </li>
  2472. <li>
  2473. <p>
  2474. metalink-language
  2475. </p>
  2476. </li>
  2477. <li>
  2478. <p>
  2479. metalink-location
  2480. </p>
  2481. </li>
  2482. <li>
  2483. <p>
  2484. metalink-os
  2485. </p>
  2486. </li>
  2487. <li>
  2488. <p>
  2489. metalink-version
  2490. </p>
  2491. </li>
  2492. <li>
  2493. <p>
  2494. metalink-preferred-protocol
  2495. </p>
  2496. </li>
  2497. <li>
  2498. <p>
  2499. metalink-enable-unique-protocol
  2500. </p>
  2501. </li>
  2502. <li>
  2503. <p>
  2504. allow-overwrite
  2505. </p>
  2506. </li>
  2507. <li>
  2508. <p>
  2509. allow-piece-length-change
  2510. </p>
  2511. </li>
  2512. <li>
  2513. <p>
  2514. async-dns
  2515. </p>
  2516. </li>
  2517. <li>
  2518. <p>
  2519. auto-file-renaming
  2520. </p>
  2521. </li>
  2522. <li>
  2523. <p>
  2524. file-allocation
  2525. </p>
  2526. </li>
  2527. <li>
  2528. <p>
  2529. max-download-limit
  2530. </p>
  2531. </li>
  2532. <li>
  2533. <p>
  2534. no-file-allocation-limit
  2535. </p>
  2536. </li>
  2537. <li>
  2538. <p>
  2539. parameterized-uri
  2540. </p>
  2541. </li>
  2542. <li>
  2543. <p>
  2544. realtime-chunk-checksum
  2545. </p>
  2546. </li>
  2547. </ul></div>
  2548. <div class="paragraph"><p>These options have exactly same meaning of the ones in the
  2549. command-line options, but it just applies to the URIs it belongs to.</p></div>
  2550. <div class="paragraph"><p>For example, the content of uri.txt is</p></div>
  2551. <div class="listingblock">
  2552. <div class="content">
  2553. <pre><tt>http://server/file.iso http://mirror/file.iso
  2554. dir=/iso_images
  2555. out=file.img
  2556. http://foo/bar</tt></pre>
  2557. </div></div>
  2558. <div class="paragraph"><p>If aria2 is executed with <strong>-i</strong> uri.txt <strong>-d</strong> /tmp options, then
  2559. <em>file.iso</em> is saved as <em>/iso_images/file.img</em> and it is downloaded
  2560. from http://server/file.iso and http://mirror/file.iso. The file
  2561. <em>bar</em> is downloaded from http://foo/bar and saved as <em>/tmp/bar</em>.</p></div>
  2562. <div class="paragraph"><p>In some cases, <strong>out</strong> parameter has no effect. See note of <strong>--out</strong>
  2563. option for the restrictions.</p></div>
  2564. <h3 id="_server_performance_profile">Server Performance Profile</h3><div style="clear:left"></div>
  2565. <div class="paragraph"><p>This section describes the format of server performance profile. The
  2566. file is plain text and each line has several NAME=VALUE pair,
  2567. delimited by comma. Currently following NAMEs are recognized:</p></div>
  2568. <div class="dlist"><dl>
  2569. <dt class="hdlist1">
  2570. host
  2571. </dt>
  2572. <dd>
  2573. <p>
  2574. Hostname of the server. Required.
  2575. </p>
  2576. </dd>
  2577. <dt class="hdlist1">
  2578. protocol
  2579. </dt>
  2580. <dd>
  2581. <p>
  2582. Protocol for this profile, such as ftp, http. Required.
  2583. </p>
  2584. </dd>
  2585. <dt class="hdlist1">
  2586. dl_speed
  2587. </dt>
  2588. <dd>
  2589. <p>
  2590. The average download speed observed in the previous download in
  2591. bytes per sec. Required.
  2592. </p>
  2593. </dd>
  2594. <dt class="hdlist1">
  2595. sc_avg_speed
  2596. </dt>
  2597. <dd>
  2598. <p>
  2599. The average download speed observed in the previous download in
  2600. bytes per sec. This value is only updated if the download is done in
  2601. single connection environment and only used by
  2602. AdaptiveURISelector. Optional.
  2603. </p>
  2604. </dd>
  2605. <dt class="hdlist1">
  2606. mc_avg_speed
  2607. </dt>
  2608. <dd>
  2609. <p>
  2610. The average download speed observed in the previous download in
  2611. bytes per sec. This value is only updated if the download is done in
  2612. multi connection environment and only used by
  2613. AdaptiveURISelector. Optional.
  2614. </p>
  2615. </dd>
  2616. <dt class="hdlist1">
  2617. counter
  2618. </dt>
  2619. <dd>
  2620. <p>
  2621. How many times the server is used. Currently this value is only used
  2622. by AdaptiveURISelector. Optional.
  2623. </p>
  2624. </dd>
  2625. <dt class="hdlist1">
  2626. last_updated
  2627. </dt>
  2628. <dd>
  2629. <p>
  2630. Last contact time in GMT with this server, specified in the seconds
  2631. since the Epoch(00:00:00 on January 1, 1970, UTC). Required.
  2632. </p>
  2633. </dd>
  2634. <dt class="hdlist1">
  2635. status
  2636. </dt>
  2637. <dd>
  2638. <p>
  2639. ERROR is set when server cannot be reached or out-of-service or
  2640. timeout occurred. Otherwise, OK is set.
  2641. </p>
  2642. </dd>
  2643. </dl></div>
  2644. <div class="paragraph"><p>Those fields must exist in one line. The order of the fields is not
  2645. significant. You can put pairs other than the above; they are simply
  2646. ignored.</p></div>
  2647. <div class="paragraph"><p>An example follows:</p></div>
  2648. <div class="listingblock">
  2649. <div class="content">
  2650. <pre><tt>host=localhost, protocol=http, dl_speed=32000, last_updated=1222491640, status=OK
  2651. host=localhost, protocol=ftp, dl_speed=0, last_updated=1222491632, status=ERROR</tt></pre>
  2652. </div></div>
  2653. </div>
  2654. <h2 id="_xml_rpc_interface">XML-RPC INTERFACE</h2>
  2655. <div class="sectionbody">
  2656. <h3 id="_terminology">Terminology</h3><div style="clear:left"></div>
  2657. <div class="dlist"><dl>
  2658. <dt class="hdlist1">
  2659. GID
  2660. </dt>
  2661. <dd>
  2662. <p>
  2663. GID(or gid) is the key to manage each download. Each download has an
  2664. unique GID. Currently GID looks like an integer, but don&#8217;t treat it
  2665. as integer because it may be changed to another type in the future
  2666. release. Please note that GID is session local and not persisted
  2667. when aria2 exits.
  2668. </p>
  2669. </dd>
  2670. </dl></div>
  2671. <h3 id="_methods">Methods</h3><div style="clear:left"></div>
  2672. <div class="paragraph"><p><strong>aria2.addUri</strong> <em>uris[, options[, position]]</em></p></div>
  2673. <div class="paragraph"><p>This method adds new HTTP(S)/FTP/BitTorrent Magnet URI. <em>uris</em> is of
  2674. type array and its element is URI which is of type string. For
  2675. BitTorrent Magnet URI, <em>uris</em> must have only one element and it should
  2676. be BitTorrent Magnet URI. <em>options</em> is of type struct and its members
  2677. are a pair of option name and value. See <strong>Options</strong> below for more
  2678. details. If <em>position</em> is given as an integer starting from 0, the
  2679. new download is inserted at <em>position</em> in the waiting queue. If
  2680. <em>position</em> is not given or <em>position</em> is larger than the size of the
  2681. queue, it is appended at the end of the queue. This method returns
  2682. GID of registered download.</p></div>
  2683. <div class="paragraph"><p><strong>aria2.addTorrent</strong> <em>torrent[, uris[, options[, position]]]</em></p></div>
  2684. <div class="paragraph"><p>This method adds BitTorrent download by uploading .torrent file. If
  2685. you want to add BitTorrent Magnet URI, use <strong>aria2.addUri</strong> method
  2686. instead. <em>torrent</em> is of type base64 which contains Base64-encoded
  2687. .torrent file. <em>uris</em> is of type array and its element is URI which
  2688. is of type string. <em>uris</em> is used for Web-seeding. For single file
  2689. torrents, URI can be a complete URI pointing to the resource or if URI
  2690. ends with /, name in torrent file is added. For multi-file torrents,
  2691. name and path in torrent are added to form a URI for each file.
  2692. <em>options</em> is of type struct and its members are a pair of option name
  2693. and value. See <strong>Options</strong> below for more details. If <em>position</em> is
  2694. given as an integer starting from 0, the new download is inserted at
  2695. <em>position</em> in the waiting queue. If <em>position</em> is not given or
  2696. <em>position</em> is larger than the size of the queue, it is appended at the
  2697. end of the queue. This method returns GID of registered download.</p></div>
  2698. <div class="paragraph"><p><strong>aria2.addMetalink</strong> <em>metalink[, options[, position]]</em></p></div>
  2699. <div class="paragraph"><p>This method adds Metalink download by uploading .metalink file.
  2700. <em>metalink</em> is of type base64 which contains Base64-encoded .metalink
  2701. file. <em>options</em> is of type struct and its members are a pair of
  2702. option name and value. See <strong>Options</strong> below for more details. If
  2703. <em>position</em> is given as an integer starting from 0, the new download is
  2704. inserted at <em>position</em> in the waiting queue. If <em>position</em> is not
  2705. given or <em>position</em> is larger than the size of the queue, it is
  2706. appended at the end of the queue. This method returns array of GID of
  2707. registered download.</p></div>
  2708. <div class="paragraph"><p><strong>aria2.remove</strong> <em>gid</em></p></div>
  2709. <div class="paragraph"><p>This method removes the download denoted by <em>gid</em>. <em>gid</em> is of type
  2710. string. If specified download is in progress, it is stopped at
  2711. first. The status of removed download becomes "removed". This method
  2712. returns GID of removed download.</p></div>
  2713. <div class="paragraph"><p><strong>aria2.forceRemove</strong> <em>gid</em></p></div>
  2714. <div class="paragraph"><p>This method removes the download denoted by <em>gid</em>. This method
  2715. behaves just like <strong>aria2.remove</strong> except that this method removes
  2716. download without any action which takes time such as contacting
  2717. BitTorrent tracker.</p></div>
  2718. <div class="paragraph"><p><strong>aria2.tellStatus</strong> <em>gid</em></p></div>
  2719. <div class="paragraph"><p>This method returns download progress of the download denoted by
  2720. <em>gid</em>. <em>gid</em> is of type string. The response is of type struct and it
  2721. contains following keys. The value type is string.</p></div>
  2722. <div class="dlist"><dl>
  2723. <dt class="hdlist1">
  2724. gid
  2725. </dt>
  2726. <dd>
  2727. <p>
  2728. GID of this download.
  2729. </p>
  2730. </dd>
  2731. <dt class="hdlist1">
  2732. status
  2733. </dt>
  2734. <dd>
  2735. <p>
  2736. "active" for currently downloading/seeding entry. "waiting" for the
  2737. entry in the queue; download is not started. "error" for the stopped
  2738. download because of error. "complete" for the stopped and completed
  2739. download. "removed" for the download removed by user.
  2740. </p>
  2741. </dd>
  2742. <dt class="hdlist1">
  2743. totalLength
  2744. </dt>
  2745. <dd>
  2746. <p>
  2747. Total length of this download in bytes.
  2748. </p>
  2749. </dd>
  2750. <dt class="hdlist1">
  2751. completedLength
  2752. </dt>
  2753. <dd>
  2754. <p>
  2755. Completed length of this download in bytes.
  2756. </p>
  2757. </dd>
  2758. <dt class="hdlist1">
  2759. uploadLength
  2760. </dt>
  2761. <dd>
  2762. <p>
  2763. Uploaded length of this download in bytes.
  2764. </p>
  2765. </dd>
  2766. <dt class="hdlist1">
  2767. bitfield
  2768. </dt>
  2769. <dd>
  2770. <p>
  2771. Hexadecimal representation of the download progress. The highest bit
  2772. corresponds to piece index 0. The set bits indicate the piece is
  2773. available and unset bits indicate the piece is missing. The spare
  2774. bits at the end are set to zero.
  2775. </p>
  2776. </dd>
  2777. <dt class="hdlist1">
  2778. downloadSpeed
  2779. </dt>
  2780. <dd>
  2781. <p>
  2782. Download speed of this download measured in bytes/sec.
  2783. </p>
  2784. </dd>
  2785. <dt class="hdlist1">
  2786. uploadSpeed
  2787. </dt>
  2788. <dd>
  2789. <p>
  2790. Upload speed of this download measured in bytes/sec.
  2791. </p>
  2792. </dd>
  2793. <dt class="hdlist1">
  2794. infoHash
  2795. </dt>
  2796. <dd>
  2797. <p>
  2798. InfoHash. BitTorrent only.
  2799. </p>
  2800. </dd>
  2801. <dt class="hdlist1">
  2802. numSeeders
  2803. </dt>
  2804. <dd>
  2805. <p>
  2806. The number of seeders the client has connected to. BitTorrent only.
  2807. </p>
  2808. </dd>
  2809. <dt class="hdlist1">
  2810. pieceLength
  2811. </dt>
  2812. <dd>
  2813. <p>
  2814. Piece length in bytes.
  2815. </p>
  2816. </dd>
  2817. <dt class="hdlist1">
  2818. numPieces
  2819. </dt>
  2820. <dd>
  2821. <p>
  2822. The number of pieces.
  2823. </p>
  2824. </dd>
  2825. <dt class="hdlist1">
  2826. connections
  2827. </dt>
  2828. <dd>
  2829. <p>
  2830. The number of peers/servers the client has connected to.
  2831. </p>
  2832. </dd>
  2833. <dt class="hdlist1">
  2834. errorCode
  2835. </dt>
  2836. <dd>
  2837. <p>
  2838. The last error code occurred in this download. The value is of type
  2839. string. The error codes are defined in EXIT STATUS section. This
  2840. value is only available for stopped/completed downloads.
  2841. </p>
  2842. </dd>
  2843. <dt class="hdlist1">
  2844. followedBy
  2845. </dt>
  2846. <dd>
  2847. <p>
  2848. List of GIDs which are generated by the consequence of this
  2849. download. For example, when aria2 downloaded Metalink file, it
  2850. generates downloads described in it(see <strong>--follow-metalink</strong>
  2851. option). This value is useful to track these auto generated
  2852. downloads. If there is no such downloads, this key will not
  2853. be included in the response.
  2854. </p>
  2855. </dd>
  2856. <dt class="hdlist1">
  2857. belongsTo
  2858. </dt>
  2859. <dd>
  2860. <p>
  2861. GID of a parent download. Some downloads are a part of another
  2862. download. For example, if a file in Metalink has BitTorrent
  2863. resource, the download of .torrent is a part of that file. If this
  2864. download has no parent, this key will not be included in the
  2865. response.
  2866. </p>
  2867. </dd>
  2868. <dt class="hdlist1">
  2869. dir
  2870. </dt>
  2871. <dd>
  2872. <p>
  2873. Directory to save files. This key is not available for stopped
  2874. downloads.
  2875. </p>
  2876. </dd>
  2877. <dt class="hdlist1">
  2878. files
  2879. </dt>
  2880. <dd>
  2881. <p>
  2882. Returns the list of files. The element of list is the same struct
  2883. used in <strong>aria2.getFiles</strong> method.
  2884. </p>
  2885. </dd>
  2886. <dt class="hdlist1">
  2887. bittorrent
  2888. </dt>
  2889. <dd>
  2890. <p>
  2891. Struct which contains information retrieved from .torrent
  2892. file. BitTorrent only. It contains following keys.
  2893. </p>
  2894. <div class="dlist"><dl>
  2895. <dt class="hdlist1">
  2896. announceList
  2897. </dt>
  2898. <dd>
  2899. <p>
  2900. List of lists of announce URI. If .torrent file contains announce
  2901. and no announce-list, announce is converted to announce-list
  2902. format.
  2903. </p>
  2904. </dd>
  2905. <dt class="hdlist1">
  2906. comment
  2907. </dt>
  2908. <dd>
  2909. <p>
  2910. The comment for the torrent. comment.utf-8 is used if available.
  2911. </p>
  2912. </dd>
  2913. <dt class="hdlist1">
  2914. creationDate
  2915. </dt>
  2916. <dd>
  2917. <p>
  2918. The creation time of the torrent. The value is an integer since
  2919. the Epoch, measured in seconds.
  2920. </p>
  2921. </dd>
  2922. <dt class="hdlist1">
  2923. mode
  2924. </dt>
  2925. <dd>
  2926. <p>
  2927. File mode of the torrent. The value is either <em>single</em> or <em>multi</em>.
  2928. </p>
  2929. </dd>
  2930. <dt class="hdlist1">
  2931. info
  2932. </dt>
  2933. <dd>
  2934. <p>
  2935. Struct which contains data from Info dictionary. It contains
  2936. following keys.
  2937. </p>
  2938. <div class="dlist"><dl>
  2939. <dt class="hdlist1">
  2940. name
  2941. </dt>
  2942. <dd>
  2943. <p>
  2944. name in info dictionary. name.utf-8 is used if available.
  2945. </p>
  2946. </dd>
  2947. </dl></div>
  2948. </dd>
  2949. </dl></div>
  2950. </dd>
  2951. </dl></div>
  2952. <div class="paragraph"><p><strong>aria2.getUris</strong> <em>gid</em></p></div>
  2953. <div class="paragraph"><p>This method returns URIs used in the download denoted by <em>gid</em>. <em>gid</em>
  2954. is of type string. The response is of type array and its element is of
  2955. type struct and it contains following keys. The value type is string.</p></div>
  2956. <div class="dlist"><dl>
  2957. <dt class="hdlist1">
  2958. uri
  2959. </dt>
  2960. <dd>
  2961. <p>
  2962. URI
  2963. </p>
  2964. </dd>
  2965. <dt class="hdlist1">
  2966. status
  2967. </dt>
  2968. <dd>
  2969. <p>
  2970. <em>used</em> if the URI is already used. <em>waiting</em> if the URI is waiting
  2971. in the queue.
  2972. </p>
  2973. </dd>
  2974. </dl></div>
  2975. <div class="paragraph"><p><strong>aria2.getFiles</strong> <em>gid</em></p></div>
  2976. <div class="paragraph"><p>This method returns file list of the download denoted by <em>gid</em>. <em>gid</em>
  2977. is of type string. The response is of type array and its element is of
  2978. type struct and it contains following keys. The value type is string.</p></div>
  2979. <div class="dlist"><dl>
  2980. <dt class="hdlist1">
  2981. index
  2982. </dt>
  2983. <dd>
  2984. <p>
  2985. Index of file. Starting with 1. This is the same order with the
  2986. files in multi-file torrent.
  2987. </p>
  2988. </dd>
  2989. <dt class="hdlist1">
  2990. path
  2991. </dt>
  2992. <dd>
  2993. <p>
  2994. File path.
  2995. </p>
  2996. </dd>
  2997. <dt class="hdlist1">
  2998. length
  2999. </dt>
  3000. <dd>
  3001. <p>
  3002. File size in bytes.
  3003. </p>
  3004. </dd>
  3005. <dt class="hdlist1">
  3006. selected
  3007. </dt>
  3008. <dd>
  3009. <p>
  3010. "true" if this file is selected by <strong>--select-file</strong> option. If
  3011. <strong>--select-file</strong> is not specified or this is single torrent or no
  3012. torrent download, this value is always "true". Otherwise "false".
  3013. </p>
  3014. </dd>
  3015. <dt class="hdlist1">
  3016. uris
  3017. </dt>
  3018. <dd>
  3019. <p>
  3020. Returns the list of URI for this file. The element of list is the
  3021. same struct used in <strong>aria2.getUris</strong> method.
  3022. </p>
  3023. </dd>
  3024. </dl></div>
  3025. <div class="paragraph"><p><strong>aria2.getPeers</strong> <em>gid</em></p></div>
  3026. <div class="paragraph"><p>This method returns peer list of the download denoted by <em>gid</em>. <em>gid</em>
  3027. is of type string. This method is for BitTorrent only. The response
  3028. is of type array and its element is of type struct and it contains
  3029. following keys. The value type is string.</p></div>
  3030. <div class="dlist"><dl>
  3031. <dt class="hdlist1">
  3032. peerId
  3033. </dt>
  3034. <dd>
  3035. <p>
  3036. Percent-encoded peer ID.
  3037. </p>
  3038. </dd>
  3039. <dt class="hdlist1">
  3040. ip
  3041. </dt>
  3042. <dd>
  3043. <p>
  3044. IP address of the peer.
  3045. </p>
  3046. </dd>
  3047. <dt class="hdlist1">
  3048. port
  3049. </dt>
  3050. <dd>
  3051. <p>
  3052. Port number of the peer.
  3053. </p>
  3054. </dd>
  3055. <dt class="hdlist1">
  3056. bitfield
  3057. </dt>
  3058. <dd>
  3059. <p>
  3060. Hexadecimal representation of the download progress of the peer. The
  3061. highest bit corresponds to piece index 0. The set bits indicate the
  3062. piece is available and unset bits indicate the piece is missing. The
  3063. spare bits at the end are set to zero.
  3064. </p>
  3065. </dd>
  3066. <dt class="hdlist1">
  3067. amChoking
  3068. </dt>
  3069. <dd>
  3070. <p>
  3071. "true" if this client is choking the peer. Otherwise "false".
  3072. </p>
  3073. </dd>
  3074. <dt class="hdlist1">
  3075. peerChoking
  3076. </dt>
  3077. <dd>
  3078. <p>
  3079. "true" if the peer is choking this client. Otherwise "false".
  3080. </p>
  3081. </dd>
  3082. <dt class="hdlist1">
  3083. downloadSpeed
  3084. </dt>
  3085. <dd>
  3086. <p>
  3087. Download speed (byte/sec) that this client obtains from the peer.
  3088. </p>
  3089. </dd>
  3090. <dt class="hdlist1">
  3091. uploadSpeed
  3092. </dt>
  3093. <dd>
  3094. <p>
  3095. Upload speed(byte/sec) that this client uploads to the peer.
  3096. </p>
  3097. </dd>
  3098. <dt class="hdlist1">
  3099. seeder
  3100. </dt>
  3101. <dd>
  3102. <p>
  3103. "true" is this client is a seeder. Otherwise "false".
  3104. </p>
  3105. </dd>
  3106. </dl></div>
  3107. <div class="paragraph"><p><strong>aria2.getServers</strong> <em>gid</em></p></div>
  3108. <div class="paragraph"><p>This method returns currently connected HTTP(S)/FTP servers of the download denoted by <em>gid</em>. <em>gid</em> is of type string. The response
  3109. is of type array and its element is of type struct and it contains
  3110. following keys. The value type is string.</p></div>
  3111. <div class="dlist"><dl>
  3112. <dt class="hdlist1">
  3113. index
  3114. </dt>
  3115. <dd>
  3116. <p>
  3117. Index of file. Starting with 1. This is the same order with the
  3118. files in multi-file torrent.
  3119. </p>
  3120. </dd>
  3121. <dt class="hdlist1">
  3122. servers
  3123. </dt>
  3124. <dd>
  3125. <p>
  3126. The list of struct which contains following keys.
  3127. </p>
  3128. <div class="dlist"><dl>
  3129. <dt class="hdlist1">
  3130. uri
  3131. </dt>
  3132. <dd>
  3133. <p>
  3134. URI originally added.
  3135. </p>
  3136. </dd>
  3137. <dt class="hdlist1">
  3138. currentUri
  3139. </dt>
  3140. <dd>
  3141. <p>
  3142. This is the URI currently used for downloading. If redirection is
  3143. involved, currentUri and uri may differ.
  3144. </p>
  3145. </dd>
  3146. <dt class="hdlist1">
  3147. downloadSpeed
  3148. </dt>
  3149. <dd>
  3150. <p>
  3151. Download speed (byte/sec)
  3152. </p>
  3153. </dd>
  3154. </dl></div>
  3155. </dd>
  3156. </dl></div>
  3157. <div class="paragraph"><p><strong>aria2.tellActive</strong></p></div>
  3158. <div class="paragraph"><p>This method returns the list of active downloads. The response is of
  3159. type array and its element is the same struct returned by
  3160. <strong>aria2.tellStatus</strong> method.</p></div>
  3161. <div class="paragraph"><p><strong>aria2.tellWaiting</strong> <em>offset, num</em></p></div>
  3162. <div class="paragraph"><p>This method returns the list of waiting download. <em>offset</em> is of type
  3163. integer and specifies the offset from the download waiting at the
  3164. front. <em>num</em> is of type integer and specifies the number of downloads
  3165. to be returned.</p></div>
  3166. <div class="paragraph"><p>If offset is a positive integer, this method returns downloads in the
  3167. range of [<em>offset</em>, <em>offset</em>+<em>num</em>).</p></div>
  3168. <div class="paragraph"><p><em>offset</em> can be a negative integer. <em>offset</em> == -1 points last
  3169. download in the waiting queue and <em>offset</em> == -2 points the download
  3170. before the last download, and so on. The downloads in the response are
  3171. in reversed order.</p></div>
  3172. <div class="paragraph"><p>For example, imagine that three downloads "A","B" and "C" are waiting
  3173. in this order. aria2.tellWaiting(0, 1) returns
  3174. ["A"]. aria2.tellWaiting(1, 2) returns ["B", "C"].
  3175. aria2.tellWaiting(-1, 2) returns ["C", "B"].</p></div>
  3176. <div class="paragraph"><p>The response is of type array and its element is the same struct
  3177. returned by <strong>aria2.tellStatus</strong> method.</p></div>
  3178. <div class="paragraph"><p><strong>aria2.tellStopped</strong> <em>offset, num</em></p></div>
  3179. <div class="paragraph"><p>This method returns the list of stopped download. <em>offset</em> is of type
  3180. integer and specifies the offset from the oldest download. <em>num</em> is of
  3181. type integer and specifies the number of downloads to be returned.</p></div>
  3182. <div class="paragraph"><p><em>offset</em> and <em>num</em> have the same semantics as <strong>aria2.tellWaiting</strong>
  3183. method.</p></div>
  3184. <div class="paragraph"><p>The response is of type array and its element is the same struct
  3185. returned by <strong>aria2.tellStatus</strong> method.</p></div>
  3186. <div class="paragraph"><p><strong>aria2.changePosition</strong> <em>gid, pos, how</em></p></div>
  3187. <div class="paragraph"><p>This method changes the position of the download denoted by
  3188. <em>gid</em>. <em>pos</em> is of type integer. <em>how</em> is of type string. If <em>how</em> is
  3189. "POS_SET", it moves the download to a position relative to the
  3190. beginning of the queue. If <em>how</em> is "POS_CUR", it moves the download
  3191. to a position relative to the current position. If <em>how</em> is "POS_END",
  3192. it moves the download to a position relative to the end of the
  3193. queue. If the destination position is less than 0 or beyond the end of
  3194. the queue, it moves the download to the beginning or the end of the
  3195. queue respectively. The response is of type integer and it is the
  3196. destination position.</p></div>
  3197. <div class="paragraph"><p>For example, if GID#1 is placed in position 3, aria2.changePosition(1,
  3198. -1, POS_CUR) will change its position to 2. Additional
  3199. aria2.changePosition(1, 0, POS_SET) will change its position to 0(the
  3200. beginning of the queue).</p></div>
  3201. <div class="paragraph"><p><strong>aria2.changeUri</strong> <em>gid, fileIndex, delUris, addUris[, position]</em></p></div>
  3202. <div class="paragraph"><p>This method removes URIs in <em>delUris</em> from and appends URIs in
  3203. <em>addUris</em> to download denoted by <em>gid</em>. <em>delUris</em> and <em>addUris</em> are
  3204. list of string. A download can contain multiple files and URIs are
  3205. attached to each file. <em>fileIndex</em> is used to select which file to
  3206. remove/attach given URIs. <em>fileIndex</em> is 1-based. <em>position</em> is used
  3207. to specify where URIs are inserted in the existing waiting URI
  3208. list. <em>position</em> is 0-based. When <em>position</em> is omitted, URIs are
  3209. appended to the back of the list. This method first execute removal
  3210. and then addition. <em>position</em> is the position after URIs are removed,
  3211. not the position when this method is called. When removing URI, if
  3212. same URIs exist in download, only one of them is removed for each URI
  3213. in <em>delUris</em>. In other words, there are three URIs
  3214. "http://example.org/aria2" and you want remove them all, you have to
  3215. specify (at least) 3 "http://example.org/aria2" in <em>delUris</em>. This
  3216. method returns a list which contains 2 integers. The first integer is
  3217. the number of URIs deleted. The second integer is the number of URIs
  3218. added.</p></div>
  3219. <div class="paragraph"><p><strong>aria2.getOption</strong> <em>gid</em></p></div>
  3220. <div class="paragraph"><p>This method returns options of the download denoted by <em>gid</em>. The
  3221. response is of type struct. Its key is the name of option. The value type
  3222. is string.</p></div>
  3223. <div class="paragraph"><p><strong>aria2.changeOption</strong> <em>gid, options</em></p></div>
  3224. <div class="paragraph"><p>This method changes options of the download denoted by <em>gid</em>
  3225. dynamically. <em>gid</em> is of type string. <em>options</em> is of type struct
  3226. and the available options are: <strong>bt-max-peers</strong>,
  3227. <strong>bt-request-peer-speed-limit</strong>, <strong>max-download-limit</strong> and
  3228. <strong>max-upload-limit</strong>. This method returns "OK" for success.</p></div>
  3229. <div class="paragraph"><p><strong>aria2.getGlobalOption</strong></p></div>
  3230. <div class="paragraph"><p>This method returns global options. The response is of type
  3231. struct. Its key is the name of option. The value type is string.
  3232. Because global options are used as a template for the options of newly
  3233. added download, the response contains keys returned by
  3234. <strong>aria2.getOption</strong> method.</p></div>
  3235. <div class="paragraph"><p><strong>aria2.changeGlobalOption</strong> <em>options</em></p></div>
  3236. <div class="paragraph"><p>This method changes global options dynamically. <em>options</em> is of type
  3237. struct and the available options are <strong>max-concurrent-downloads</strong>,
  3238. <strong>max-overall-download-limit</strong> and <strong>max-overall-upload-limit</strong>. This
  3239. method returns "OK" for success.</p></div>
  3240. <div class="paragraph"><p><strong>aria2.purgeDownloadResult</strong></p></div>
  3241. <div class="paragraph"><p>This method purges completed/error/removed downloads to free memory.
  3242. This method returns "OK".</p></div>
  3243. <div class="paragraph"><p><strong>aria2.getVersion</strong></p></div>
  3244. <div class="paragraph"><p>This method returns version of the program and the list of enabled
  3245. features. The response is of type struct and contains following keys.</p></div>
  3246. <div class="dlist"><dl>
  3247. <dt class="hdlist1">
  3248. version
  3249. </dt>
  3250. <dd>
  3251. <p>
  3252. Version number of the program in string.
  3253. </p>
  3254. </dd>
  3255. <dt class="hdlist1">
  3256. enabledFeatures
  3257. </dt>
  3258. <dd>
  3259. <p>
  3260. List of enabled features. Each feature name is of type string.
  3261. </p>
  3262. </dd>
  3263. </dl></div>
  3264. <div class="paragraph"><p><strong>aria2.getSessionInfo</strong></p></div>
  3265. <div class="paragraph"><p>This method returns session information.
  3266. The response is of type struct and contains following key.</p></div>
  3267. <div class="dlist"><dl>
  3268. <dt class="hdlist1">
  3269. sessionId
  3270. </dt>
  3271. <dd>
  3272. <p>
  3273. Session ID, which is generated each time when aria2 is invoked.
  3274. </p>
  3275. </dd>
  3276. </dl></div>
  3277. <div class="paragraph"><p><strong>system.multicall</strong> <em>methods</em></p></div>
  3278. <div class="paragraph"><p>This methods encapsulates multiple method calls in a single request.
  3279. <em>methods</em> is of type array and its element is struct. The struct
  3280. contains two keys: "methodName" and "params". "methodName" is the
  3281. method name to call and "params" is array containing parameters to the
  3282. method. This method returns array of responses. The element of array
  3283. will either be a one-item array containing the return value of each
  3284. method call or struct of fault element if an encapsulated method call
  3285. fails.</p></div>
  3286. <h3 id="_error_handling">Error Handling</h3><div style="clear:left"></div>
  3287. <div class="paragraph"><p>In case of error, aria2 returns faultCode=1 and the error message in
  3288. faultString.</p></div>
  3289. <h3 id="_options_2">Options</h3><div style="clear:left"></div>
  3290. <div class="paragraph"><p>Same options for <strong>-i</strong> list are available. See <strong>Input File</strong> subsection
  3291. for complete list of options.</p></div>
  3292. <div class="paragraph"><p>In the option struct, name element is option name(without preceding
  3293. "--") and value element is argument as string.</p></div>
  3294. <div class="listingblock">
  3295. <div class="content">
  3296. <pre><tt>&lt;struct&gt;
  3297. &lt;member&gt;
  3298. &lt;name&gt;split&lt;/name&gt;
  3299. &lt;value&gt;&lt;string&gt;1&lt;/string&gt;&lt;/value&gt;
  3300. &lt;/member&gt;
  3301. &lt;member&gt;
  3302. &lt;name&gt;http-proxy&lt;/name&gt;
  3303. &lt;value&gt;&lt;string&gt;http://proxy/&lt;/string&gt;&lt;/value&gt;
  3304. &lt;/member&gt;
  3305. &lt;/struct&gt;</tt></pre>
  3306. </div></div>
  3307. <div class="paragraph"><p><strong>header</strong> and <strong>index-out</strong> option are allowed multiple times in
  3308. command-line. Since name should be unique in struct(many XML-RPC
  3309. library implementation uses hash or dict for struct), single string is
  3310. not enough. To overcome this situation, they can take array as value
  3311. as well as string.</p></div>
  3312. <div class="listingblock">
  3313. <div class="content">
  3314. <pre><tt>&lt;struct&gt;
  3315. &lt;member&gt;
  3316. &lt;name&gt;header&lt;/name&gt;
  3317. &lt;value&gt;
  3318. &lt;array&gt;
  3319. &lt;data&gt;
  3320. &lt;value&gt;&lt;string&gt;Accept-Language: ja&lt;/string&gt;&lt;/value&gt;
  3321. &lt;value&gt;&lt;string&gt;Accept-Charset: utf-8&lt;/string&gt;&lt;/value&gt;
  3322. &lt;/data&gt;
  3323. &lt;/array&gt;
  3324. &lt;/value&gt;
  3325. &lt;/member&gt;
  3326. &lt;/struct&gt;</tt></pre>
  3327. </div></div>
  3328. <h3 id="_sample_xml_rpc_client_code">Sample XML-RPC Client Code</h3><div style="clear:left"></div>
  3329. <div class="paragraph"><p>The following Ruby script adds <em>http://localhost/aria2.tar.bz2</em> to
  3330. aria2c operated on localhost with option <strong>--dir</strong>=<em>/downloads</em> and
  3331. prints its reponse.</p></div>
  3332. <div class="listingblock">
  3333. <div class="content">
  3334. <pre><tt>#!/usr/bin/env ruby
  3335. require 'xmlrpc/client'
  3336. require 'pp'
  3337. client=XMLRPC::Client.new2("http://localhost:6800/rpc")
  3338. options={ "dir" =&gt; "/downloads" }
  3339. result=client.call("aria2.addUri", [ "http://localhost/aria2.tar.bz2" ], options)
  3340. pp result</tt></pre>
  3341. </div></div>
  3342. <div class="paragraph"><p>If you are a Python lover, you can use xmlrpclib(for Python3.x, use
  3343. xmlrpc.client instead) to interact with aria2.</p></div>
  3344. <div class="listingblock">
  3345. <div class="content">
  3346. <pre><tt>import xmlrpclib
  3347. from pprint import pprint
  3348. s = xmlrpclib.ServerProxy("http://localhost:6800/rpc")
  3349. r = s.aria2.addUri(["http://localhost/aria2.tar.bz2"], {"dir":"/downloads"})
  3350. pprint(r)</tt></pre>
  3351. </div></div>
  3352. </div>
  3353. <h2 id="_example">EXAMPLE</h2>
  3354. <div class="sectionbody">
  3355. <h3 id="_http_ftp_segmented_download">HTTP/FTP Segmented Download</h3><div style="clear:left"></div>
  3356. <h4 id="_download_a_file">Download a file</h4>
  3357. <div class="listingblock">
  3358. <div class="content">
  3359. <pre><tt>aria2c "http://host/file.zip"</tt></pre>
  3360. </div></div>
  3361. <div class="admonitionblock">
  3362. <table><tr>
  3363. <td class="icon">
  3364. <div class="title">Note</div>
  3365. </td>
  3366. <td class="content">aria2 uses 5 connections to download 1 file by default.</td>
  3367. </tr></table>
  3368. </div>
  3369. <h4 id="_download_a_file_using_1_connection">Download a file using 1 connection</h4>
  3370. <div class="listingblock">
  3371. <div class="content">
  3372. <pre><tt>aria2c -s1 "http://host/file.zip"</tt></pre>
  3373. </div></div>
  3374. <div class="admonitionblock">
  3375. <table><tr>
  3376. <td class="icon">
  3377. <div class="title">Note</div>
  3378. </td>
  3379. <td class="content">aria2 uses 5 connections to download 1 file by default.
  3380. -s1 limits the number of connections to just 1.</td>
  3381. </tr></table>
  3382. </div>
  3383. <div class="admonitionblock">
  3384. <table><tr>
  3385. <td class="icon">
  3386. <div class="title">Note</div>
  3387. </td>
  3388. <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>
  3389. </tr></table>
  3390. </div>
  3391. <h4 id="_download_a_file_from_2_different_http_servers">Download a file from 2 different HTTP servers</h4>
  3392. <div class="listingblock">
  3393. <div class="content">
  3394. <pre><tt>aria2c "http://host/file.zip" "http://mirror/file.zip"</tt></pre>
  3395. </div></div>
  3396. <h4 id="_download_a_file_from_http_and_ftp_servers">Download a file from HTTP and FTP servers</h4>
  3397. <div class="listingblock">
  3398. <div class="content">
  3399. <pre><tt>aria2c "http://host1/file.zip" "ftp://host2/file.zip"</tt></pre>
  3400. </div></div>
  3401. <h4 id="_download_files_listed_in_a_text_file_concurrently">Download files listed in a text file concurrently</h4>
  3402. <div class="listingblock">
  3403. <div class="content">
  3404. <pre><tt>aria2c -ifiles.txt -j2</tt></pre>
  3405. </div></div>
  3406. <div class="admonitionblock">
  3407. <table><tr>
  3408. <td class="icon">
  3409. <div class="title">Note</div>
  3410. </td>
  3411. <td class="content">-j option specifies the number of parallel downloads.</td>
  3412. </tr></table>
  3413. </div>
  3414. <h4 id="_using_proxy">Using proxy</h4>
  3415. <div class="paragraph"><p>For HTTP:</p></div>
  3416. <div class="listingblock">
  3417. <div class="content">
  3418. <pre><tt>aria2c --http-proxy="http://proxy:8080" "http://host/file"</tt></pre>
  3419. </div></div>
  3420. <div class="paragraph"><p>For FTP:</p></div>
  3421. <div class="listingblock">
  3422. <div class="content">
  3423. <pre><tt>aria2c --ftp-proxy="http://proxy:8080" "ftp://host/file"</tt></pre>
  3424. </div></div>
  3425. <div class="admonitionblock">
  3426. <table><tr>
  3427. <td class="icon">
  3428. <div class="title">Note</div>
  3429. </td>
  3430. <td class="content">See <strong>--http-proxy</strong>, <strong>--https-proxy</strong>, <strong>--ftp-proxy</strong> and <strong>--all-proxy</strong> for
  3431. details.
  3432. You can specify proxy in the environment variables. See <strong>ENVIRONMENT</strong> section.</td>
  3433. </tr></table>
  3434. </div>
  3435. <h4 id="_proxy_with_authorization">Proxy with authorization</h4>
  3436. <div class="listingblock">
  3437. <div class="content">
  3438. <pre><tt>aria2c --http-proxy="http://username:password@proxy:8080" "http://host/file"</tt></pre>
  3439. </div></div>
  3440. <h3 id="_metalink_download">Metalink Download</h3><div style="clear:left"></div>
  3441. <h4 id="_download_files_with_remote_metalink">Download files with remote Metalink</h4>
  3442. <div class="listingblock">
  3443. <div class="content">
  3444. <pre><tt>aria2c --follow-metalink=mem "http://host/file.metalink"</tt></pre>
  3445. </div></div>
  3446. <h4 id="_download_using_a_local_metalink_file">Download using a local metalink file</h4>
  3447. <div class="listingblock">
  3448. <div class="content">
  3449. <pre><tt>aria2c -p --lowest-speed-limit=4000 file.metalink</tt></pre>
  3450. </div></div>
  3451. <div class="admonitionblock">
  3452. <table><tr>
  3453. <td class="icon">
  3454. <div class="title">Note</div>
  3455. </td>
  3456. <td class="content">To pause a download, press Ctrl-C.
  3457. You can resume the transfer by running aria2c with the same argument in the same
  3458. directory.</td>
  3459. </tr></table>
  3460. </div>
  3461. <h4 id="_download_several_local_metalink_files">Download several local metalink files</h4>
  3462. <div class="listingblock">
  3463. <div class="content">
  3464. <pre><tt>aria2c -j2 file1.metalink file2.metalink</tt></pre>
  3465. </div></div>
  3466. <h4 id="_download_only_selected_files_using_index">Download only selected files using index</h4>
  3467. <div class="listingblock">
  3468. <div class="content">
  3469. <pre><tt>aria2c --select-file=1-4,8 file.metalink</tt></pre>
  3470. </div></div>
  3471. <div class="admonitionblock">
  3472. <table><tr>
  3473. <td class="icon">
  3474. <div class="title">Note</div>
  3475. </td>
  3476. <td class="content">The index is printed to the console using -S option.</td>
  3477. </tr></table>
  3478. </div>
  3479. <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>
  3480. <div class="listingblock">
  3481. <div class="content">
  3482. <pre><tt>aria2c --metalink-location=jp,us --metalink-version=1.1 --metalink-language=en-US file.metalink</tt></pre>
  3483. </div></div>
  3484. <h3 id="_bittorrent_download">BitTorrent Download</h3><div style="clear:left"></div>
  3485. <h4 id="_download_files_from_remote_bittorrent_file">Download files from remote BitTorrent file</h4>
  3486. <div class="listingblock">
  3487. <div class="content">
  3488. <pre><tt>aria2c --follow-torrent=mem "http://host/file.torrent"</tt></pre>
  3489. </div></div>
  3490. <h4 id="_download_using_a_local_torrent_file">Download using a local torrent file</h4>
  3491. <div class="listingblock">
  3492. <div class="content">
  3493. <pre><tt>aria2c --max-upload-limit=40K file.torrent</tt></pre>
  3494. </div></div>
  3495. <div class="admonitionblock">
  3496. <table><tr>
  3497. <td class="icon">
  3498. <div class="title">Note</div>
  3499. </td>
  3500. <td class="content">--max-upload-limit specifies the max of upload rate.</td>
  3501. </tr></table>
  3502. </div>
  3503. <div class="admonitionblock">
  3504. <table><tr>
  3505. <td class="icon">
  3506. <div class="title">Note</div>
  3507. </td>
  3508. <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>
  3509. </tr></table>
  3510. </div>
  3511. <h4 id="_download_using_bittorrent_magnet_uri">Download using BitTorrent Magnet URI</h4>
  3512. <div class="listingblock">
  3513. <div class="content">
  3514. <pre><tt>aria2c "magnet:?xt=urn:btih:248D0A1CD08284299DE78D5C1ED359BB46717D8C&amp;dn=aria2"</tt></pre>
  3515. </div></div>
  3516. <div class="admonitionblock">
  3517. <table><tr>
  3518. <td class="icon">
  3519. <div class="title">Note</div>
  3520. </td>
  3521. <td class="content">Don&#8217;t forget to quote BitTorrent Magnet URI which includes "&amp;"
  3522. character with single(') or double(") quotation.</td>
  3523. </tr></table>
  3524. </div>
  3525. <h4 id="_download_2_torrents">Download 2 torrents</h4>
  3526. <div class="listingblock">
  3527. <div class="content">
  3528. <pre><tt>aria2c -j2 file1.torrent file2.torrent</tt></pre>
  3529. </div></div>
  3530. <h4 id="_download_a_file_using_torrent_and_http_ftp_server">Download a file using torrent and HTTP/FTP server</h4>
  3531. <div class="listingblock">
  3532. <div class="content">
  3533. <pre><tt>aria2c -Ttest.torrent "http://host1/file" "ftp://host2/file"</tt></pre>
  3534. </div></div>
  3535. <div class="admonitionblock">
  3536. <table><tr>
  3537. <td class="icon">
  3538. <div class="title">Note</div>
  3539. </td>
  3540. <td class="content">Downloading multi file torrent with HTTP/FTP is not supported.</td>
  3541. </tr></table>
  3542. </div>
  3543. <h4 id="_download_only_selected_files_using_index_usually_called_selectable_download">Download only selected files using index(usually called "selectable download")</h4>
  3544. <div class="listingblock">
  3545. <div class="content">
  3546. <pre><tt>aria2c --select-file=1-4,8 file.torrent</tt></pre>
  3547. </div></div>
  3548. <div class="admonitionblock">
  3549. <table><tr>
  3550. <td class="icon">
  3551. <div class="title">Note</div>
  3552. </td>
  3553. <td class="content">The index is printed to the console using -S option.</td>
  3554. </tr></table>
  3555. </div>
  3556. <h4 id="_specify_output_filename">Specify output filename</h4>
  3557. <div class="paragraph"><p>To specify output filename for BitTorrent downloads, you need to know
  3558. the index of file in torrent file using <strong>-S</strong> option. For example, the
  3559. output looks like this:</p></div>
  3560. <div class="listingblock">
  3561. <div class="content">
  3562. <pre><tt>idx|path/length
  3563. ===+======================
  3564. 1|dist/base-2.6.18.iso
  3565. |99.9MiB
  3566. ---+----------------------
  3567. 2|dist/driver-2.6.18.iso
  3568. |169.0MiB
  3569. ---+----------------------</tt></pre>
  3570. </div></div>
  3571. <div class="paragraph"><p>To save <em>dist/base-2.6.18.iso</em> in <em>/tmp/mydir/base.iso</em> and
  3572. <em>dist/driver-2.6.18.iso</em> in <em>/tmp/dir/driver.iso</em>, use the following
  3573. command:</p></div>
  3574. <div class="listingblock">
  3575. <div class="content">
  3576. <pre><tt>aria2c --dir=/tmp --index-out=1=mydir/base.iso --index-out=2=dir/driver.iso file.torrent</tt></pre>
  3577. </div></div>
  3578. <h4 id="_change_the_listening_port_for_incoming_peer">Change the listening port for incoming peer</h4>
  3579. <div class="listingblock">
  3580. <div class="content">
  3581. <pre><tt>aria2c --listen-port=7000-7001,8000 file.torrent</tt></pre>
  3582. </div></div>
  3583. <div class="admonitionblock">
  3584. <table><tr>
  3585. <td class="icon">
  3586. <div class="title">Note</div>
  3587. </td>
  3588. <td class="content">Since aria2 doesn&#8217;t configure firewall or router for port forwarding, it&#8217;s up
  3589. to you to do it manually.</td>
  3590. </tr></table>
  3591. </div>
  3592. <h4 id="_specify_the_condition_to_stop_program_after_torrent_download_finished">Specify the condition to stop program after torrent download finished</h4>
  3593. <div class="listingblock">
  3594. <div class="content">
  3595. <pre><tt>aria2c --seed-time=120 --seed-ratio=1.0 file.torrent</tt></pre>
  3596. </div></div>
  3597. <div class="admonitionblock">
  3598. <table><tr>
  3599. <td class="icon">
  3600. <div class="title">Note</div>
  3601. </td>
  3602. <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>
  3603. </tr></table>
  3604. </div>
  3605. <h4 id="_throttle_upload_speed">Throttle upload speed</h4>
  3606. <div class="listingblock">
  3607. <div class="content">
  3608. <pre><tt>aria2c --max-upload-limit=100K file.torrent</tt></pre>
  3609. </div></div>
  3610. <h4 id="_enable_dht">Enable DHT</h4>
  3611. <div class="listingblock">
  3612. <div class="content">
  3613. <pre><tt>aria2c --enable-dht --dht-listen-port=6881 file.torrent</tt></pre>
  3614. </div></div>
  3615. <div class="admonitionblock">
  3616. <table><tr>
  3617. <td class="icon">
  3618. <div class="title">Note</div>
  3619. </td>
  3620. <td class="content">DHT uses udp port. Since aria2 doesn&#8217;t configure firewall or router for port
  3621. forwarding, it&#8217;s up to you to do it manually.</td>
  3622. </tr></table>
  3623. </div>
  3624. <h3 id="_more_advanced_http_features">More advanced HTTP features</h3><div style="clear:left"></div>
  3625. <h4 id="_load_cookies">Load cookies</h4>
  3626. <div class="listingblock">
  3627. <div class="content">
  3628. <pre><tt>aria2c --load-cookies=cookies.txt "http://host/file.zip"</tt></pre>
  3629. </div></div>
  3630. <div class="admonitionblock">
  3631. <table><tr>
  3632. <td class="icon">
  3633. <div class="title">Note</div>
  3634. </td>
  3635. <td class="content">You can use Firefox/Mozilla&#8217;s cookie file without modification.</td>
  3636. </tr></table>
  3637. </div>
  3638. <h4 id="_resume_download_started_by_web_browsers_or_another_programs">Resume download started by web browsers or another programs</h4>
  3639. <div class="listingblock">
  3640. <div class="content">
  3641. <pre><tt>aria2c -c -s2 "http://host/partiallydownloadedfile.zip"</tt></pre>
  3642. </div></div>
  3643. <h4 id="_client_certificate_authorization_for_ssl_tls">Client certificate authorization for SSL/TLS</h4>
  3644. <div class="listingblock">
  3645. <div class="content">
  3646. <pre><tt>aria2c --certificate=/path/to/mycert.pem --private-key=/path/to/mykey.pem https://host/file</tt></pre>
  3647. </div></div>
  3648. <div class="admonitionblock">
  3649. <table><tr>
  3650. <td class="icon">
  3651. <div class="title">Note</div>
  3652. </td>
  3653. <td class="content">The file specified in <strong>--private-key</strong> must be decrypted. The behavior when
  3654. encrypted one is given is undefined.</td>
  3655. </tr></table>
  3656. </div>
  3657. <h4 id="_verify_peer_in_ssl_tls_using_given_ca_certificates">Verify peer in SSL/TLS using given CA certificates</h4>
  3658. <div class="listingblock">
  3659. <div class="content">
  3660. <pre><tt>aria2c --ca-certificate=/path/to/ca-certificates.crt --check-certificate https://host/file</tt></pre>
  3661. </div></div>
  3662. <h3 id="_and_more_advanced_features">And more advanced features</h3><div style="clear:left"></div>
  3663. <h4 id="_throttle_download_speed">Throttle download speed</h4>
  3664. <div class="listingblock">
  3665. <div class="content">
  3666. <pre><tt>aria2c --max-download-limit=100K file.metalink</tt></pre>
  3667. </div></div>
  3668. <h4 id="_repair_a_damaged_download">Repair a damaged download</h4>
  3669. <div class="listingblock">
  3670. <div class="content">
  3671. <pre><tt>aria2c -V file.metalink</tt></pre>
  3672. </div></div>
  3673. <div class="admonitionblock">
  3674. <table><tr>
  3675. <td class="icon">
  3676. <div class="title">Note</div>
  3677. </td>
  3678. <td class="content">This option is only available used with BitTorrent or metalink with chunk
  3679. checksums.</td>
  3680. </tr></table>
  3681. </div>
  3682. <h4 id="_drop_connection_if_download_speed_is_lower_than_specified_value">Drop connection if download speed is lower than specified value</h4>
  3683. <div class="listingblock">
  3684. <div class="content">
  3685. <pre><tt>aria2c --lowest-speed-limit=10K file.metalink</tt></pre>
  3686. </div></div>
  3687. <h4 id="_parameterized_uri_support">Parameterized URI support</h4>
  3688. <div class="paragraph"><p>You can specify set of parts:</p></div>
  3689. <div class="listingblock">
  3690. <div class="content">
  3691. <pre><tt>aria2c -P "http://{host1,host2,host3}/file.iso"</tt></pre>
  3692. </div></div>
  3693. <div class="paragraph"><p>You can specify numeric sequence:</p></div>
  3694. <div class="listingblock">
  3695. <div class="content">
  3696. <pre><tt>aria2c -Z -P "http://host/image[000-100].png"</tt></pre>
  3697. </div></div>
  3698. <div class="admonitionblock">
  3699. <table><tr>
  3700. <td class="icon">
  3701. <div class="title">Note</div>
  3702. </td>
  3703. <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>
  3704. </tr></table>
  3705. </div>
  3706. <div class="paragraph"><p>You can specify step counter:</p></div>
  3707. <div class="listingblock">
  3708. <div class="content">
  3709. <pre><tt>aria2c -Z -P "http://host/image[A-Z:2].png"</tt></pre>
  3710. </div></div>
  3711. <h4 id="_parallel_downloads_of_arbitrary_number_of_url_metalink_torrent">Parallel downloads of arbitrary number of URL,metalink,torrent</h4>
  3712. <div class="listingblock">
  3713. <div class="content">
  3714. <pre><tt>aria2c -j3 -Z "http://host/file1" file2.torrent file3.metalink</tt></pre>
  3715. </div></div>
  3716. <h4 id="_bittorrent_encryption">BitTorrent Encryption</h4>
  3717. <div class="paragraph"><p>Encrypt whole payload using ARC4:</p></div>
  3718. <div class="listingblock">
  3719. <div class="content">
  3720. <pre><tt>aria2c --bt-min-crypto-level=arc4 --bt-require-crypto=true file.torrent</tt></pre>
  3721. </div></div>
  3722. </div>
  3723. <h2 id="_see_also">SEE ALSO</h2>
  3724. <div class="sectionbody">
  3725. <div class="paragraph"><p>Project Web Site: <a href="http://aria2.sourceforge.net/">http://aria2.sourceforge.net/</a></p></div>
  3726. <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>
  3727. <div class="paragraph"><p>Metalink Homepage: <a href="http://www.metalinker.org/">http://www.metalinker.org/</a></p></div>
  3728. </div>
  3729. <h2 id="_copyright">COPYRIGHT</h2>
  3730. <div class="sectionbody">
  3731. <div class="paragraph"><p>Copyright &#169; 2006, 2010 Tatsuhiro Tsujikawa</p></div>
  3732. <div class="paragraph"><p>This program is free software; you can redistribute it and/or modify
  3733. it under the terms of the GNU General Public License as published by
  3734. the Free Software Foundation; either version 2 of the License, or
  3735. (at your option) any later version.</p></div>
  3736. <div class="paragraph"><p>This program is distributed in the hope that it will be useful,
  3737. but WITHOUT ANY WARRANTY; without even the implied warranty of
  3738. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  3739. GNU General Public License for more details.</p></div>
  3740. <div class="paragraph"><p>You should have received a copy of the GNU General Public License
  3741. along with this program; if not, write to the Free Software
  3742. Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</p></div>
  3743. <div class="paragraph"><p>In addition, as a special exception, the copyright holders give
  3744. permission to link the code of portions of this program with the
  3745. OpenSSL library under certain conditions as described in each
  3746. individual source file, and distribute linked combinations
  3747. including the two.
  3748. You must obey the GNU General Public License in all respects
  3749. for all of the code used other than OpenSSL. If you modify
  3750. file(s) with this exception, you may extend this exception to your
  3751. version of the file(s), but you are not obligated to do so. If you
  3752. do not wish to do so, delete this exception statement from your
  3753. version. If you delete this exception statement from all source
  3754. files in the program, then also delete it here.</p></div>
  3755. </div>
  3756. </div>
  3757. <div id="footnotes"><hr /></div>
  3758. <div id="footer">
  3759. <div id="footer-text">
  3760. Last updated 2010-03-09 00:04:25 JST
  3761. </div>
  3762. </div>
  3763. </body>
  3764. </html>