APT tips and tricks

Search installed packages:

apt-cache search package

Get details about a specific installed package:

apt-cache show package

 

Install new package (Note that you can install several packages at a time by seperating the package name by a single space):

apt-get install package1 package2

Remove a package

apt-get remove package

When you are removing the package some configuration files a left at the system but you can completely remove the package and config by using the following parameter:

apt-get remove package --purge

You can use the apt tool to update installed packages on the system by running the following commands:

apt-get update
apt-get upgrade

You can also update the system using these commands. apt-get upgrade is used to install the newest versions of all packages currently installed on the system but apt-get dist-upgrade, in addition to performing the function of upgrade, also intelligently handles changing dependencies with new versions of packages.

apt-get update
apt-get dist-upgrade

the upgrade command does the trick but you should run the update command before to receive latest packages and updates.

If installation of a package fails you may resolve the problems by running this command:

apt-get -f install
  • Install new, install, packages and updates
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Installing Postfix with MySql backend and TLS

In this tutorial we’ll install a ready to use Postfix mail server with MySql backend for virtual...

Installing ionCube

ionCube protects software written using the PHP programming language from being viewed,...

Installing PowerDNS on etch/lenny

The PowerDNS Nameserver is a modern, advanced and high performance authoritative-only nameserver....

Installing Zenoss monitoring system

Zenoss is an award-winning open source IT monitoring product that effectively manages the...

Upgrade from etch to lenny

Debian has released a stable version of Debian 5.0 (lenny). If you’re running previous version of...