In Ubuntu I install some software via deb packages (dpkg -i), because in "apt-get install" old versions of software. But I have to manually install all dependency to deb package. How to avoid this?

For example installation of bareos 16 version in Ubuntu. I install it from deb package via official site.

But there are other files on page (Packages, Release, Sources ...).

other files

What should I use and how to replace deb package and install dependency automatically? For example in CentOS as far as I know there is file .repo

2 Answers 2


To add the Bareos community repository, you first need to download and import their key:

curl http://download.bareos.org/bareos/release/latest/xUbuntu_16.04/Release.key | sudo apt-key add -

then add the repository:

echo deb http://download.bareos.org/bareos/release/latest/xUbuntu_16.04/ / | sudo tee /etc/apt/sources.list.d/bareos.list

before updating:

sudo apt update

You will then be able to install Bareos packages and their dependencies using apt install bareos, and they will be upgraded by apt upgrade whenever new releases are made available.

  • Thanks. Do I understand correctly, that now when I want to install concrete package I have to install from such command "sudo apt install bareos-filedaemon_16.2.4-12.1_amd64" instead of "dpkg -i bareos-filedaemon_16.2.4-12.1_amd64.deb"?
    – Log
    Dec 6, 2017 at 20:46
  • No, you’d just run sudo apt install bareos-filedaemon (without downloading the package beforehand). Dec 6, 2017 at 21:04

Use apt:

$ apt-get install ./file.deb
  • Thanks. When need to update package what should I use, installing new .deb file or something like "apt-get update" of previous file?
    – Log
    Dec 6, 2017 at 20:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .