Now: Tutorial for Web and Software Design > OS > Linux > OS Content
> Installing Software on Debian [Bookmark it]
Installing Software on Debian

Installing Software on Debian

by Edd Dumbill
04/06/2006
Debian has more or less all free software in the known world!

One of the things that has made Debian famous among Linux distributions is the APT package management system. Its ability to handle often complex chains of interdependencies between packages makes installing software very convenient. APT selects Debian software packages, commonly known as debs, from one or more archive sources.

Using APT is the most important skill for a Debian administrator to learn. The two most popular tools in Debian for managing packages are apt-get and aptitude. Most people find aptitude superior, as it not only includes all of apt-get's features, but also includes many others, such as an interactive menu-driven mode and the removal of packages when you no longer need them.

By following this article, you'll learn the basics of package management on Debian using the aptitude tool.

Using aptitude

The software available in the Debian Linux distribution is organized into packages. Packages consist of precompiled software and additional files that integrate the software into the Debian system. Adding software to your Debian system is usually a matter of installing packages.

After you ran the Debian installer, several packages were installed for you. Now you can start adding further packages using aptitude install. This article shows how to install the sudo package, which enables normal users to do tasks as the system superuser. (See my article Using the Root Account on Debian for more information on running commands as root.)

To install software, you must be running as the root, the superuser account. Until you have sudo installed, you need to log in to the console as root, or become root by running su - and typing in the root password.

# aptitude install sudo

Reading Package Lists... 

Building Dependency Tree... 

Reading extended state information... 

Initializing package states... 

Reading task descriptions... Done

The following NEW packages will be installed:

  sudo 

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

Need to get 147kB of archives. After unpacking 369kB will be used.

Writing extended state information... Done

Get:1 http://ftp.uk.debian.org testing/main sudo 1.6.7p5-2 [147kB]

Fetched 147kB in 2s (55.2kB/s)

Selecting previously deselected package sudo.

(Reading database ... 25786 files and directories currently installed.)

Unpacking sudo (from .../sudo_1.6.7p5-2_i386.deb) ...

Setting up sudo (1.6.7p5-2) ...

No /etc/sudoers found... creating one for you.



Reading Package Lists... Done

Building Dependency Tree

Reading extended state information

Initializing package states... Done

Reading task descriptions... Done

The installation process prints a lot of text, most of which you can ignore. You'll often find useful information, however, after the Setting up line. In this case, the sudo package installation process says that it's created a configuration file /etc/sudoers.

You can see that the sudo software is now installed by looking in /usr/share/doc/sudo, the usual place for accompanying documentation. Note also that the configuration file, /etc/sudoers, is in place.

Removing software is as easy as running aptitude remove. Remove the sudo package and observe how the system changes:

# aptitude remove sudo

Reading Package Lists... 

Building Dependency Tree... 

Reading extended state information... 

Initializing package states... 

Reading task descriptions... Done

The following packages will be REMOVED:

  sudo 

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

Need to get 0B of archives. After unpacking 369kB will be freed.

Writing extended state information... Done

(Reading database ... 25809 files and directories currently installed.)

Removing sudo ...

Reading Package Lists... Done

Building Dependency Tree

Reading extended state information

Initializing package states... Done

Reading task descriptions... Done

# ls /etc/sudoers

/etc/sudoers

Notice that the configuration file has been left behind, but the software and its documentation is gone. To really get rid of all files related to a package, use the aptitude purge command:

 # aptitude purge sudo

...

The following packages will be REMOVED:

  sudo 

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

Need to get 0B of archives. After unpacking 0B will be used.

Do you want to continue? [Y/n/?] Y

Writing extended state information... Done

(Reading database ... 25788 files and directories currently installed.)

Removing sudo ...

Purging configuration files for sudo ...

...

# ls /etc/sudoers

ls: /etc/sudoers: No such file or directory

[1] [2] [3] Next

[Bookmark][Print] [Close][To Top]
  • Prev Article-OS:

  • Next Article-OS:
  • Related Materias
    How to Deploy Software Usi
    Top 10 Tips for Using Wind
    Mastering Windows New Fire
    Creating Visual Studio Pro
    Implementing Mandatory Roa
    Better Registry Searching
    Windows XP File Sharing My
    Using Data Compression in 
    Building Photo Uploaders w
    How to Remove Startup Prog
    Topics
    Photoshop Tutorial
     

    Special Effect

      3D Effect
      Photoshop Articles
    Programming Tutorial
     

    C/C++ Tutorial

      Visual Basic
      C# Tutorial
    Database Tutorial
     

    MySQL Tutorial

      MS SQL Tutorial
      Oracle Tutorial
    Graphic Design Tutorial
     

    Coreldraw Tutorial

      Illustrator Tutorial
      3D Graphics Articles
    Webmaster Articles
     

    Domain Service

      Web Hosting
      Site Promotion
    Java Tutorial&Articles
     

    Java Servlets

      JavaEE Tutorial
     

    JavaBeans Tutorial

    XML Tutorial&Articles
     

    XML Style Tutorial

      AJAX Tutorial
      XML Mobile
    Flash Tutorial&Articles
     

    Flash Video

      Action Script
      Flash Articles
    OS Tutorial&Articles
     

    Linux Tutorial

      Symbian Tutorial
      MacOS Tutorial