Skip to content

aMule takes 25 minutes to start #562

Description

@ngosang

aMule versions tested: 2.3.3 and commit abfcbb8 (same result)

I have a server sharing a large amount of files:

  • Number of Shared Files: 11782
  • Total size of Shared Files: 8.017 TB
  • Average file size: 713.51 MB

Each time I restart the aMule server (amuled) it takes 25 minutes to start. During the start aMule only uses 1 core 100% (of 4 cores available).

 2026-05-10 00:37:19: Logging to stdout enabled
 2026-05-10 00:37:19: Initialising aMuleD GIT compiled with wxBase(GTK3) v3.2.8 and Boost 1.84 (Snapshot: rev. 2.3.3-313-gabfcbb8ad3)
 2026-05-10 00:37:19: Checking if there is an instance already running...
 2026-05-10 00:37:19: No other instances are running.
!2026-05-10 00:37:19: ERROR: Info  --- This is the first time you run aMule GIT ---
!2026-05-10 00:37:19: More information, support and new releases can found at our homepage,
!2026-05-10 00:37:19: at https://amule-org.github.io, or in our IRC channel #aMule at irc.freenode.net.
!2026-05-10 00:37:19: Feel free to report any bugs to https://github.com/amule-org/amule/issues
 2026-05-10 00:59:05: Creditfile loaded, 12453 clients are known
 2026-05-10 00:59:05:  - Credits expired for 45 clients!
 2026-05-10 00:59:05: *** TCP socket (ECServer) listening on 0.0.0.0:4717
 2026-05-10 00:59:05: Created Server UDP-Socket at port 24665
 2026-05-10 00:59:05: ListenSocket: Ok.
 2026-05-10 00:59:05: Created Client UDP-Socket at port 24672

---

 2026-05-10 00:59:10: Found 11603 known shared files, 179 unknown

Known files are huge:

-rw-r--r--  1 noroot noroot  74M May 10 01:07 known.met
-rw-r--r--  1 noroot noroot 1.1G May 10 01:00 known2_64.met

I suppose the aMule code is not designed for modern computers. It seems to be using only 1 core and reading all the files from disk again to recalculate the piece hashes. BitTorrent clients never recalculate hashes on startup; they only check the file's last modification date and assume the content has not changed.

My question is whether something can be done to improve the code so that startup becomes much faster.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions