Download a package using apt on Debian/Ubuntu

On Debian and Ubuntu servers, you can download a package using apt download command.

apt download PKG_NAME

download package using apt

Package will get downloaded to current working directory. Better do this to /tmp to avoid permission errors.

Method 2

If you want to download package and dependencies, then use

apt-get install --download-only PKG_NAME

This will download the package and all dependency, store it in folder /var/cache/apt/archives.

If you need to remove downloaded packages, run

apt clean

Seeapt-get

Need help with Linux Server or WordPress? We can help!

Leave a Reply

Your email address will not be published. Required fields are marked *