3

If it was windows machine that had no internet connection, what I would do is downloading the installers/programs on another computer, putting them on a portable media, copying them on the conectionless machine and install them. Linux does not work that simple unfortunately - though I hope you'll prove me wrong on this point.

On linux (debian), I never had the pleasure installing anything differently than through:

sudo apt-get install package_name(s)

Thing impossible without connection to the internet. Unfortunately, it's also very unclear which files are to be downloaded - and from where. Often apt downloads dozens of files which is something I'd hate to do manually.

So, is there a program that would download the files on my Windows PC with no need to do anything more than telling it package name?

  • Chocolatey is used for silent-installation of programs on windows. Not for downloading debian packages. – Tomáš Zato Jun 19 '14 at 19:59
  • "So, is there a program that would download the files on my Windows PC with no need to do anything more than telling it package name?" Sounds like chocolatey to me. @josten gave you a valid response, if you don't like it reword your question to ask what you really mean – Creek Jun 19 '14 at 20:10
  • the files is the important part. Could you define what did you understand that is meant by the files? – Tomáš Zato Jun 19 '14 at 20:20
6

I think you're looking for apt-offline.

On your Linux machine with no Internet connection, let's say you want to install emacs. You'd do:

# apt-offline set --install-packages=emacs /media/usbstick/offline.sig

Then, on your Windows machine with an Internet connection, you'd do:

E:\> apt-offline get offline.sig

and finally, on your Linux machine:

# apt-offline install /media/usbstick/offline.zip

Further details can be found in the article Offline Package Management for APT. Super User has some help on adding apt-offline to your path on Windows.

  • -bash: apt-offline: command not found. Seems I'm out of luck. – Tomáš Zato Jun 19 '14 at 20:41
  • 1
    @TomášZato You'll have to install it, and deal with dependencies once by hand. You can download the packages from that packages.debian.org site. You then install them on your Linux machine with dpkg -i filename.deb. (Or maybe its on the CD/DVD you used to install from, in which case you can install it from those) – derobert Jun 19 '14 at 20:43
  • Note: from the original Linux machine you can obtain the full list of packages with dpkg --get-selections > ~/Package.list. Just in case you want to use it... – Hastur Jun 19 '14 at 21:26
  • Thanks a lot for help. I have even succeeded mounting a pen drive to linux and generating .sig the files on it (not as simple as it may seem for beginner). However I can't seem to find any mention of the apt-offline windows download. The guide you linked to only contains link to some obscure site. – Tomáš Zato Jun 19 '14 at 21:50
  • So, I have found a git hub repository. But the pain is endless - now I have found that I can't build the thing. – Tomáš Zato Jun 19 '14 at 22:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.