Skip to content

Daemon

WarpDL uses a daemon architecture where a background process manages all downloads.

CLI Command → Unix Socket/Named Pipe → Daemon → Download Engine

The daemon:

  • Runs in the background
  • Manages multiple concurrent downloads
  • Persists state across CLI sessions
  • Handles retry and resume logic

The daemon starts automatically when you run any download command. To start it manually:

Terminal window
warpdl daemon
Flag Default Description
--max-concurrent 3 Maximum number of concurrent downloads (0 = unlimited)
--speed-schedule - Throttle window HH:MM-HH:MM:SPEED (e.g. 09:00-17:00:512KB)
--rpc-listen-all false Bind the JSON-RPC endpoint to all interfaces instead of localhost only

Throttle example (full speed overnight, 512 KB/s during work hours):

Terminal window
# Via flag
warpdl daemon --speed-schedule 09:00-17:00:512KB
# Via environment variable (used when the flag is not set)
export WARPDL_SPEED_SCHEDULE=09:00-17:00:512KB
warpdl daemon

Examples:

Terminal window
# Start with max 5 concurrent downloads
warpdl daemon --max-concurrent 5

The daemon always serves its JSON-RPC API on /jsonrpc (HTTP) and /jsonrpc/ws (WebSocket). It binds to 127.0.0.1 by default and is unauthenticated — there is no token or secret to configure. Only bind it to all interfaces when something else provides the access control (reverse proxy, SSH tunnel, firewall):

Terminal window
warpdl daemon --rpc-listen-all

Environment variables are also supported:

Terminal window
export WARPDL_MAX_CONCURRENT=5
export WARPDL_RPC_LISTEN_ALL=1
warpdl daemon

The daemon maintains a download queue that manages active and waiting downloads. Use the queue command to manage queue state.

Terminal window
warpdl queue
# or
warpdl queue status

This displays:

  • Queue state (running/paused)
  • Maximum concurrent download limit
  • Active download count and waiting count
  • List of active downloads (with hashes)
  • Waiting queue with positions and priorities

Prevent new downloads from starting automatically:

Terminal window
warpdl queue pause

Active downloads continue, but no new downloads will start from the waiting queue.

Allow downloads to start automatically again:

Terminal window
warpdl queue resume

Reposition a download in the waiting queue:

Terminal window
warpdl queue move <hash> <position>
  • <hash> - The download hash (shown in queue status)
  • <position> - New position in queue (1-based index)

Example:

Terminal window
# Move download with hash "abc123" to position 1 (front of queue)
warpdl queue move abc123 1
Terminal window
warpdl stop-daemon
Platform Default IPC
Linux/macOS Unix socket at $TMPDIR/warpdl.sock (defaults to /tmp/warpdl.sock)
Windows Named pipe \\.\pipe\warpdl

Use the --daemon-uri flag to connect to a specific daemon:

Terminal window
warpdl download --daemon-uri unix:///custom/path.sock https://example.com/file.zip
warpdl download --daemon-uri tcp://192.168.1.100:3849 https://example.com/file.zip
warpdl download --daemon-uri pipe://custom-pipe https://example.com/file.zip # Windows

Or set via environment variable:

Terminal window
export WARPDL_DAEMON_URI=tcp://192.168.1.100:3849

To customize the socket path:

Terminal window
export WARPDL_SOCKET_PATH=/custom/path.sock

To force TCP connection:

Terminal window
export WARPDL_FORCE_TCP=1
export WARPDL_TCP_PORT=3849

See Service Setup for running the daemon as a system service.