Debian command Summary

Source: Internet
Author: User
Debian command Summary-Linux Release Technology-Debian information. The following is a detailed description. When installing Debian, You need to mirror the official software package. The/etc/apt/sources. list file can be found:

Deb http://debian.cn99.com/debian stable main contrib non-free

Deb http://debian.cn99.com/debian-non-US stable/non-US main contrib non-free

Deb http://debian.cn99.com/debian-security stable/updates main contrib non-gree

Deb-src http://debian.cn99.com/debian stable main contrib non-free

Deb-src http://debian.cn99.com/debian-non-US stable/non-US main contrib

Non-free

.

If you want to install a software package, use the apt and dpkg commands.

Apt

The Advanced Packaging Tool is an Advanced interface of the Debian software package management system. It consists of several programs named as "APT. Apt-get, apt-cache, apt-cdrom, and apt-config are command line tools used to process software packages. They are also the backend of other user foreground programs, such as dselect and aptitude.

Apt-get update: update package list from/etc/apt/source. list

Apt-cache search-string description, such as the search-string Software Package

Apt-cache policy package-name displays the package version and priority.

Apt-cache show package-name: displays the description of the file.

Apt-cache showpkg package-name shows the dependency of the software package.

Apt-get install package-name install the package from the source and all its dependent packages

Apt-get upgrade: update the currently installed software package to the latest version.

We can see that some packages prevent updates (kept back)

Apt-get dist-upgrade

For example, apt-get upgrade will automatically resolve the conflict.

Apt-get remove package-names

Apt-get -- purge remove permanently deletes these packages and their configuration files

Apt-get -- purge remove gnome-panel nautilus +

When you delete a software package, if the package name is followed by a "+", the software package will be installed rather than deleted.

Apt-cache depends package-names: list all dependent packages of a specified package

Apt-cache rdepends package-names list all packages dependent on a given package

Apt-file upgrade: update the content list from the source

Apt-file search file-name: Find the software package containing the file

Apt-file search package-name: list the content of the package

Auto-apt

If you need to install the software package automatically, you can replace apt-file and install auto-apt.

Aptitude APT console interface, you need to install aptitude

Synaptic apt gui interface, you need to install synaptic

Apt-get clean

Delete the downloaded software package stored in the cache directory (/var/cache/apt/archives.

The/var/cache/apt/archives directory and all files under the/var/cache/apt/archives/partial directory will be deleted, except the locked files. When you install a software package again, APT will download it again.

Apt-get autoclean only deletes files that do not need to be downloaded again.

After selecting the software package in dselect, run:

Apt-get-u dselect-upgrade

Compare the situation with that of apt-get dist-upgrade.

You can see that many software packages installed in idea are the result of "recommended" or "recommended" of other software packages. Other software packages are installed or deleted by the dselect tool. It can be seen that the combination of dselect and APT will be a powerful tool.

Apt-get -- reinstall install

Apt-get check: download the software package database from the default server

Apt-get upgrade package_name: upgrade the specified software package, and upgrade the dependent Software Package apt-cache showpkg package_name to display some general information about the software package. apt-cache stats displays related statistics.

Apt-cache dump displays brief descriptions of each software package in the cache

Apt-cache unmet displays inconsistent dependencies.

Apt-cache show Displays the record information of the specified software package, similar to rpm-qi

Apt-cache search software package

Apt-cache depends displays the dependency of the software package.

Apt-cache pkgnames list all software packages

Apt-config dump displays the current configuration information.

Apt-get install nessus-server automatically downloads and installs dependency packages

Apt-get source package_name download package source rpm

Dpkg

It is the main tool for operating software package files;

Dpkg evolved from several original AIDS.

· Dpkg-deb: operation. deb file. Dpkg-deb (1)

· Dpkg-ftp: an old software package command. Dpkg-ftp (1)

· Dpkg-mountable: an old software package command. Dpkg-mountable (1)

· Dpkg-split: splits large software packages into small packets. Dpkg-split (1)

Dpkg-l [names] listing software packages

Dpkg-I pkg. deb displays information about the software package.

Dpkg-c pkg. deb list the content of the package

Dpkg-S filename shows which package contains this file

Dpkg-I pkg. deb installation package

Deborphan shows that there are no dependent (orphan) software packages, and deborphan needs to be installed

Debsums audit installed software reports, need to install debsums

Dpkg-divert [option] file override the version of a software package

Dpkg -- compare-versions v1 gt v2 comparison version, with echo $? Check

Dpkg-query-W -- showformat = format to query installed software packages. The format is '$ '.

Dpkg -- get-selections writes the selected software package to a file

Dpkg -- set-selection select from the file read package
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.