Skip to content

In-memory metalink limited to 5MiB #1892

@rgaudin

Description

@rgaudin

It is possible for large files to be composed of a large number of metalink pieces, resulting in a quite large metalink payload.

Should this payload exceed 5MiB, aria2 will fail with an unclear message.

$ aria2c --follow-metalink=mem http://download.kiwix.org/zim/stack_exchange/stackoverflow.com_en_all_2019-02.zim

03/03 08:58:53 [NOTICE] Downloading 1 item(s)
[#bc7796 1.7MiB/0B CN:1 DL:2.2MiB]
03/03 08:58:55 [ERROR] CUID#7 - Download aborted. URI=http://download.kiwix.org/zim/stack_exchange/stackoverflow.com_en_all_2019-02.zim
Exception: [AbstractCommand.cc:351] errorCode=1 URI=http://download.kiwix.org/zim/stack_exchange/stackoverflow.com_en_all_2019-02.zim
  -> [ByteArrayDiskWriter.cc:64] errorCode=1 Maximum length(5242880) exceeded.

03/03 08:58:55 [NOTICE] Download GID#bc77967a7a379436 not complete: /Users/reg/Downloads/stackoverflow.com_en_all_2019-02.zim.meta4

Download Results:
gid   |stat|avg speed  |path/URI
======+====+===========+=======================================================
bc7796|ERR |   2.7MiB/s|[MEMORY]stackoverflow.com_en_all_2019-02.zim.meta4

Status Legend:
(ERR):error occurred.

aria2 will resume download if the transfer is restarted.
If there are any errors, then see the log file. See '-l' option in help/man page for details.

In this example, the meta4 payload is 7.84 MiB large.

I am not sure about what behavior to expect but at least a clear error message would save users some trouble.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions