How to install debian package on any Linux distro ?

Written on 22 June 2016

What is deb package ?

Debian packages are standard Unix ar archives that include two tar archives optionally compressed with gzip (zlib), Bzip2, lzma, or xz (lzma2): one archive holds the control information and another contains the program data.

Since Debian 0.93, a deb file is implemented as an ar archive. Canonical contents of this archive are three files:

  • debian-binary: deb format version number. This is "2.0" for current versions of Debian.
  • control.tar, control.tar.gz or control.tar.xz: all package meta-information. It tells dpkg what to configure when the package is being installed.
  • data.tar, data.tar.gz, data.tar.bz2, data.tar.lzma or data.tar.xz: the actual installable files. 1

How to install Deb package in any Linux Distro ?

  1. Unarchive Debian package
 ar vx package.deb

Example result

x - debian-binary  
x - control.tar.gz  
x - data.tar.xz

2. Unarchive data.tar, data.tar.gz, data.tar.bz2, data.tar.lzma or data.tar.xz...
Depend on your previous command result we use use command below:
For data.tar.xz

sudo tar --strip-components 1 -xf data.tar.xz -C /usr  

For data.tar.bz2

sudo tar --strip-components 1 -jxf data.tar.bz2 -C /usr  

For data.tar.gz

sudo tar --strip-components 1 -xzf data.tar.gz -C /usr