LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   get installed rpm or deb package file (https://www.linuxquestions.org/questions/linux-newbie-8/get-installed-rpm-or-deb-package-file-4175557341/)

Harshit_24 10-28-2015 01:20 AM

get installed rpm or deb package file
 
As in android, we can download the app from playstore, & if want we can share the app using shareit. It means the installable software must be present somewhere on the system.

Can we do the same in Linux distros as well ?

If I download a software like

Code:

apt-get install vlc
This command will directly download & install the vlc software. But if I want to give this software to someone else, then where does the vlc installable file i.e. .deb gets stored ?

John VV 10-28-2015 01:41 AM

a bit of a MAJOR problem

you are using a Debian based system ( apt-get )

BUT

rpm's are REDHAT packages


Debian uses "deb " packages

Debian based systems use "apt" to install deb packages

RedHat based systems use yum ( or dnf and zypper) to install rpm packages

JJJCR 10-28-2015 02:09 AM

if you want a software to give it to someone else as long as they have internet.

Give them the link where you download or install the file, or ask them to Google for the file.

or try:

find / -name '*.deb' -o -name '*.rpm'

ondoho 10-28-2015 02:34 AM

Code:

man apt-get
i'm pretty sure it has an option to only download packages, maybe even to a location of your choice.

chrism01 10-28-2015 04:03 AM

If you really are on a box that uses rpms, you can use http://linux.die.net/man/1/yumdownloader to just download it.

TobiSGD 10-28-2015 05:19 AM

There is a major difference between Android's APKs and the RPMs and DEBs of Linux systems: APKs do not only contain the software you want to install, but also all of the dependencies that are not present on a standard Android system. This is not the case with RPMs or DEBs, they only store the information which dependencies are needed. For example, if I want to install VLC on the Arch system I post this from the package manager also wants to install a bunch of other packages as dependencies:
Code:

>>> sudo pacman -S vlc                                                                          demon 11:07:11 ~ [INS]
[sudo] password for tobi:
resolving dependencies...
looking for conflicting packages...

Packages (9) libdvbpsi-1:1.3.0-1  libebml-1.3.1-1  libkate-0.4.1-5  libmatroska-1.4.2-1  libtar-1.2.20-2
            libtiger-0.3.4-4  libupnp-1.6.19-1  zvbi-0.2.35-1  vlc-2.2.1-8

Total Download Size:  10.52 MiB
Total Installed Size:  54.67 MiB

:: Proceed with installation? [Y/n] n

So, if you want to share packages with other systems you not only will need to make sure that the other systems also run the same distro (not even Ubuntu and Debian are close enough that there is a guarantee that packages from one run flawlessly on the other) in a somewhat comparable version (you might run into problems when trying to run software compiled for Ubuntu 14.04 on older versions, for example), you also have to make sure to share all the dependencies with the software.

This is a know problem and there are different approaches to solve it:
- Use a universal runtime. This is the approach that for example Steam uses, all games should be compiled against Steam's runtime environment, this way they are distribution independent and run on any distribution that can run Steam.
- Use container technology, like Docker or the upcoming Ubuntu Snappy. This way you can deploy all the dependencies together with the software without touching the base system.

Both approaches make it possible to share software across different systems, even with different distributions in different versions.

Harshit_24 01-09-2017 07:00 AM

Quote:

Originally Posted by TobiSGD (Post 5441315)
There is a major difference between Android's APKs and the RPMs and DEBs of Linux systems: APKs do not only contain the software you want to install, but also all of the dependencies that are not present on a standard Android system. This is not the case with RPMs or DEBs, they only store the information which dependencies are needed. For example, if I want to install VLC on the Arch system I post this from the package manager also wants to install a bunch of other packages as dependencies:
Code:

>>> sudo pacman -S vlc                                                                          demon 11:07:11 ~ [INS]
[sudo] password for tobi:
resolving dependencies...
looking for conflicting packages...

Packages (9) libdvbpsi-1:1.3.0-1  libebml-1.3.1-1  libkate-0.4.1-5  libmatroska-1.4.2-1  libtar-1.2.20-2
            libtiger-0.3.4-4  libupnp-1.6.19-1  zvbi-0.2.35-1  vlc-2.2.1-8

Total Download Size:  10.52 MiB
Total Installed Size:  54.67 MiB

:: Proceed with installation? [Y/n] n

So, if you want to share packages with other systems you not only will need to make sure that the other systems also run the same distro (not even Ubuntu and Debian are close enough that there is a guarantee that packages from one run flawlessly on the other) in a somewhat comparable version (you might run into problems when trying to run software compiled for Ubuntu 14.04 on older versions, for example), you also have to make sure to share all the dependencies with the software.

This is a know problem and there are different approaches to solve it:
- Use a universal runtime. This is the approach that for example Steam uses, all games should be compiled against Steam's runtime environment, this way they are distribution independent and run on any distribution that can run Steam.
- Use container technology, like Docker or the upcoming Ubuntu Snappy. This way you can deploy all the dependencies together with the software without touching the base system.

Both approaches make it possible to share software across different systems, even with different distributions in different versions.

Is it not possible to download the software like vlc with all its dependencies & put it in a particular location to be moved & installed in other linux system where internet is not accessible?

As in windows System, we can download the software & can install that software in any number of windows systems. Is it not possible with Linux OS?

TB0ne 01-09-2017 07:08 AM

Quote:

Originally Posted by Harshit_24 (Post 5652373)
Is it not possible to download the software like vlc with all its dependencies & put it in a particular location to be moved & installed in other linux system where internet is not accessible?

As in windows System, we can download the software & can install that software in any number of windows systems. Is it not possible with Linux OS?

Yes. The problem with that is simple, though....there is no 'Linux' that is like Windows. Windows 10 base, unpatched, unfixed, will STILL allow software to be installed. Whether it actually functions or not is a different matter. Installing a package for Debian on Red Hat won't work....a RHEL package on openSUSE won't work.

A program for Ubuntu 14.04 *MAY* work for Ubuntu 16.04 and have the same dependencies...and may NOT. And the dependencies have their OWN dependencies....do you know which ones are missing beforehand? Unless you can download ALL of them, then things aren't going to work. If you want to do that, then feel free....but it's fairly pointless, in my opinion. Putting it on the Internet for a few minutes and typing in "apt-get install vlc" or "yum install vlc" is far easier.

BW-userx 01-09-2017 07:12 AM

for deb files I simpley goto the Debian web sight via google and it leads me there then i just download the deb file in question.

Turbocapitalist 01-09-2017 07:18 AM

Quote:

Originally Posted by Harshit_24 (Post 5652373)
Is it not possible to download the software like vlc with all its dependencies & put it in a particular location to be moved & installed in other linux system where internet is not accessible?

It is possible to cache it. You can use apt-cacher or apt-cacher-ng and then just carry the cache with you over to the system that is without Internet access.

BW-userx 01-09-2017 07:23 AM

you can download them here 32bit or 64bit
Dependencies too are needed for VLC

Debian Jessie

Package: vlc (2.2.4-1~deb8u1)


Debian wheezy
Download Page for vlc-nox_2.0.3-5+deb7u2+b1_amd64.deb on AMD64 machines

Download Page for vlc-nox_2.2.4-12_i386.deb on Intel x86 machines


Ubuntututututututu

Download Page for vlc-dbg_2.0.8-0ubuntu0.12.04.1_i386.deb on Intel x86 machines

Download Page for vlc-nox_2.0.8-0ubuntu0.12.04.1_amd64.deb on AMD64 machines

Harshit_24 01-09-2017 07:32 AM

Quote:

Originally Posted by TB0ne (Post 5652377)
Yes. The problem with that is simple, though....there is no 'Linux' that is like Windows. Windows 10 base, unpatched, unfixed, will STILL allow software to be installed. Whether it actually functions or not is a different matter. Installing a package for Debian on Red Hat won't work....a RHEL package on openSUSE won't work.

A program for Ubuntu 14.04 *MAY* work for Ubuntu 16.04 and have the same dependencies...and may NOT. And the dependencies have their OWN dependencies....do you know which ones are missing beforehand? Unless you can download ALL of them, then things aren't going to work. If you want to do that, then feel free....but it's fairly pointless, in my opinion. Putting it on the Internet for a few minutes and typing in "apt-get install vlc" or "yum install vlc" is far easier.

I got your point. But I just wanted to know if I have a System with any Linux distro suppose Ubuntu 16 where I can download & keep the software. Now I have another system with the same linux distro i.e. Ubuntu 16 where I want to install that downloaded software which dont have internet connection. Then it should be possible by some way to install the software since the environment of the OSs are same.

Quote:

Originally Posted by Turbocapitalist (Post 5652384)
It is possible to cache it. You can use apt-cacher or apt-cacher-ng and then just carry the cache with you over to the system that is without Internet access.

Thanks for your reply. I didn't know about it. Thanks for the information. I could try that by keeping in my local system to be installed somewhere else.

Thanks for the reply. It could a nice option. I can try it out.

TB0ne 01-09-2017 07:53 AM

Quote:

Originally Posted by Harshit_24 (Post 5652387)
I got your point. But I just wanted to know if I have a System with any Linux distro suppose Ubuntu 16 where I can download & keep the software. Now I have another system with the same linux distro i.e. Ubuntu 16 where I want to install that downloaded software which dont have internet connection. Then it should be possible by some way to install the software since the environment of the OSs are same.

Yes...AGAIN, you would have to download ALL THE DEPENDENCIES, and all of THEIR DEPENDENCIES TOO. You CAN do it, but it's time consuming and pointless. Assume you get the current version of VLC...great. And in six months when it's updated? Or any of the dependencies updated?? Going to KEEP updating everything, all the time???

It is a HUGE waste of time and effort. Even if internet access is problematic at your company, you can easily create a central repository server that DOES have Internet (or is updated from Internet), and update all your other machines from it: https://help.ubuntu.com/community/AptGet/Offline

Habitual 01-09-2017 09:40 AM

Quote:

Originally Posted by Harshit_24 (Post 5652387)
I got your point. But I just wanted to know if I have a System with any Linux distro suppose Ubuntu 16 where I can download & keep the software. Now I have another system with the same linux distro i.e. Ubuntu 16 where I want to install that downloaded software which dont have internet connection. Then it should be possible by some way to install the software since the environment of the OSs are same.

Each vendor has differing requirements and IMO an "Internet Connection" is recommended on just about (dare I say it?) all of them?

Spare yourself a nervous breakdown...
Code:

"offline repositories" centos|debian|ubuntu
at any search engine, or
https://help.ubuntu.com/community/Ap...ine/Repository

"Suggested"? "Recommended"? Oh My!

JeremyBoden 01-09-2017 11:49 AM

Quote:

Originally Posted by John VV (Post 5441258)
a bit of a MAJOR problem
you are using a Debian based system ( apt-get )
BUT

rpm's are REDHAT packages

Debian uses "deb " packages
Debian based systems use "apt" to install deb packages

RedHat based systems use yum ( or dnf and zypper) to install rpm packages

If you really want to install a rpm package on Debian or a Debian based distro - you can!

Install the alien deb package into Debian,
This will allow you to install rpm packages.
I believe there is a degree of finger crossing involved though. :twocents:


All times are GMT -5. The time now is 04:56 PM.