• RSS
  • SmsJobs
  • Sms
  • GoogleBuzz
  • Facebook
  • Twitter
  • Linkedin
  • Youtube
The Linux Juggernaut

The Linux Juggernaut

roles on……

Do you like www.linuxnix.com ? Please consider supporting us by becoming a subscriber and get a Linux basics e-book for free.
apt-get-download-only

Q. I want to download a package from Ubuntu repository, I don’t want to install it on local machine but want to copy to other machine which does not have INTERNET? How can I do that?

A. By default when you use apt-get install packagename, it will try to install the package, there is –download-only option with apt-get install command to do just a download.

Suppose now I want to download only gbemol package and don’t want to install it, use below command to do this.

apt-get install gbemol –download-only

Example output:

root@surendra:/home/surendra# apt-get install gbemol --download-only 

Reading package lists... Done 

Building dependency tree 

Reading state information... Done 

Suggested packages: 

mpd 

The following NEW packages will be installed: 

gbemol 

0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 

Need to get 66.8 kB of archives. 

After this operation, 283 kB of additional disk space will be used. 

Get:1 http://us.archive.ubuntu.com/ubuntu/ natty/universe gbemol i386 0.3.2-1 [66.8 kB] 

Fetched 66.8 kB in 0s (77.4 kB/s) 

Download complete and in download only mode 

If you see above log package is just downloaded, but it did not mention where it is downloaded. There is a default location for all downloaded and downloaded/installed packages in Ubuntu. The location is /var/cache/apt/archive

Now search for your package in this location and copy it to other machine where you want to install it. I hope this helps some one who are in need. Please post your comments on this.

Do you like www.linuxnix.com ? Please consider supporting us by becoming a subscriber and get a Linux basics e-book for free.
bySurendra Anne On Thursday-August - 11 - 2011

email newsletter

Redhat Flagship dist

Redhat announced that they are going to release RHEL7 by ...

12 examples to use f

Flower brackets examples This is a small post on how to ...

7 Linux read command

read command examples read command is useful in scripts when reading ...

7 linux sort command

Linux/Unix sort command examples This is a small tutorial on how ...

How to find command

How to find command location in Linux and Unix This is ...

  • About Linux Juggernaut

    How the blog name selected? Juggernaut: * a massive inexorable force that seems to crush everything in its way ...readmore>>

  • Contact Me

    Contact us Send an Email Phone number and vCard LinkedIn profile Advertise with us
  • About Me

    Surendra Kumar Chowdary

    My name is Surendra Kumar Anne. I am from Vijayawada which is cultural capital of south Indian state of Andhra Pradesh. I am a Linux evangelist who believes in Hard work, A down to earth person, Likes to share knowledge with others, Loves dogs, Likes photography. At present i work at Persistent Systems as Module Lead.   read more »