How to get one package from Ubuntu distibution and manually install it without internet [duplicate]

You can find download links for the package here: https://packages.ubuntu.com/impish/net-tools

I guess you want the 64-bit version so click on "amd64" link, this will get you to the page where you have to choose the server you want to download from (it is recommended to choose the one that is closest to you).

Copy it to the target system and install with:

sudo dpkg -i net-tools_*.deb

For manual package downloading from an Ubuntu system:

sudo apt install package_name --download-only

For manual package downloading from another OS, use http://packages.ubuntu.com.

  • Be to select the correct release of Ubuntu. (Example: https://packages.ubuntu.com/focal/net-tools). Wrong-release packages usually won't work.

After copying the package across to the offline system, use apt to install it:

sudo apt install /path/to/package_name.deb

For most offline folks, that was the easy part, and this is where it gets tricky: Apt might refuse to install the package due to missing dependencies. That means writing down those dependencies and doing another round of manually downloading and scp-ing packages across.

sudo apt install /path/to/package1.deb /path/to/package2.deb /path/to/packageN.deb

Sometimes several rounds of dependencies. I once had to do eight rounds of sneakernetting before I got all the dependencies.

After that time, I learned my lesson. Now I keep an online VM with an identical package set as the offline system (no data) and use the apt --download-only method, which captures all dependencies the first time.