debian-apt.rst
author Oleksandr Gavenko <gavenkoa@gmail.com>
Wed, 05 Aug 2015 23:55:34 +0300
changeset 1729 22ffd80639c0
parent 1716 ee2b194456b8
child 1730 fc588b9ae857
permissions -rw-r--r--
Make centered content design with adoption for mobile devices. Highlight TOC.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     1
.. -*- coding: utf-8; -*-
1334
9bf0d5a1f0cf Include common header with quick links.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1321
diff changeset
     2
.. include:: HEADER.rst
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     3
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
======
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     5
 Apt.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     6
======
1346
a2fbf50a43f4 Fix: Has no 'contents::' directive.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1334
diff changeset
     7
.. contents::
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     8
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     9
Conf files.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    10
===========
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    11
1460
59cb3aaa2fab apt_preferences(5).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1459
diff changeset
    12
See man sources.list(5), apt.conf(5), apt_preferences(5).
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    13
1459
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    14
``/etc/apt/sources.list``::
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    15
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    16
  deb http://ftp.debian.org.ua/debian/ stable main contrib non-free
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    17
  deb http://ftp2.debian.org.ua/debian/ testing main contrib non-free
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    18
  deb http://ftp2.debian.org.ua/debian/ unstable main contrib non-free
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    19
  deb http://ftp.uk.debian.org/debian/ experimental main contrib non-free
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    20
  deb http://www.deb-multimedia.org testing main non-free
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    21
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    22
``/etc/apt/preferences``::
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    23
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    24
  Package: *
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    25
  Pin: release a=stable
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    26
  Pin-Priority: 800
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    27
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    28
  Package: *
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    29
  Pin: release a=testing
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    30
  Pin-Priority: 900
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    31
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    32
  Package: *
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    33
  Pin: release a=unstable
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    34
  Pin-Priority: 700
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    35
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    36
  Package: *
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    37
  Pin: release a=experimental
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    38
  Pin-Priority: 600
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    39
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    40
Setup backport.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    41
===============
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    42
1459
3000c0f32807 /etc/apt/preferences
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1346
diff changeset
    43
Main backports archive located at http://www.backports.org.
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    44
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    45
To get packeges gpg sign key::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    46
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    47
  $ su
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    48
  ...
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    49
  $ wget -O - http://backports.org/debian/archive.key | apt-key add -
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    50
  $ ^D
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    51
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    52
Write where packeges places::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    53
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    54
  $ cat /etc/apt/sources.list
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    55
  deb http://www.backports.org/debian/ etch-backports main contrib non-free
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    56
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    57
Getting new keys for packages.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    58
==============================
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    59
::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    60
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    61
  $ sudo apt-get update
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    62
  ...
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    63
  W: There is no public key available for the following key IDs:
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    64
  9AA38DCD55BE302B
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    65
  W: GPG error: http://http.us.debian.org etch Release: The following signatures
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    66
  couldn't be verified because the public key is not available: NO_PUBKEY
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    67
  9AA38DCD55BE302B
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    68
  ...
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    69
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    70
  $ gpg --keyserver pgp.mit.edu --recv-key 9AA38DCD55BE302B \
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    71
  --keyserver-options http-proxy=http://user:pass@192.168.1.1:3128
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    72
  gpg: requesting key 55BE302B from hkp server pgp.mit.edu
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    73
  gpg: key 55BE302B: public key "Debian Archive Automatic Signing Key (5.0/lenny) <ftpmaster@debian.org>" imported
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    74
  gpg: no ultimately trusted keys found
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    75
  gpg: Total number processed: 1
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    76
  gpg:               imported: 1  (RSA: 1)
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    77
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    78
  $ gpg --export 9AA38DCD55BE302B | sudo apt-key add -
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    79
  OK
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    80
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    81
Install build dependency for package.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    82
=====================================
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    83
::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    84
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    85
  $ apt-get install build-essential    # install dev LIBC and GCC C/C++
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    86
  $ sudo apt-get build-dep $package
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    87
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    88
If all you want is checking what packages are needed to build a given package::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    89
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    90
  $ apt-cache showsrc $package
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    91
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    92
or check 'Build-Depends' attribute in::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    93
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    94
  $ apt-cache show $package
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    95
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    96
Delete config file for removed packages.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    97
========================================
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    98
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    99
To get list of such packages use one of::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   100
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   101
  $ aptitude search ~c
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   102
  $ grep-status -n -sPackage -FStatus config-files
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   103
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   104
To remove them::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   105
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   106
  $ aptitude purge ~c
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   107
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   108
Delete obsolete packages.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   109
=========================
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   110
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   111
To get list of such packages use::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   112
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   113
  $ aptitude search ~o
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   114
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   115
To remove them::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   116
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   117
  $ aptitude purge ~o
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   118
1616
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   119
To remove packages that were automatically installed to satisfy dependencies and
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   120
are now no longer needed::
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   121
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   122
  $ sudo apt-get autoremove
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   123
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   124
Clean up packages cache.
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   125
========================
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   126
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   127
Remove everything from ``/var/cache/apt/archives/`` and
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   128
``/var/cache/apt/archives/partial/``::
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   129
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   130
  $ sudo apt-get clean
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   131
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   132
Removes package files that can no longer be downloaded, and are largely
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   133
useless::
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   134
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   135
  $ sudo apt-get autoclean
1559575ac211 Clean up packages cache.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1604
diff changeset
   136
1321
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   137
Check package files for modification.
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   138
=====================================
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   139
::
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   140
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   141
  $ sudo debsums --changed
baa1dd97c9e1 Delete config file for removed packages. Delete obsolete packages. Check
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   142
1604
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   143
Search for packages.
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   144
====================
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   145
::
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   146
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   147
  $ aptitude search '?tag(works-with::logfile)'
797a3ba1f9b5 Search for packages.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1460
diff changeset
   148
1715
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   149
Find nearest mirror.
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   150
====================
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   151
::
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   152
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   153
  $ sudo apt-get install netselect-apt
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   154
  $ netselect-apt stable
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   155
  $ netselect-apt testing
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   156
  $ netselect-apt unstable
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   157
  $ netselect-apt experimental
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   158
  $ netselect-apt sid
ec4088985c44 Find nearest mirror.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1616
diff changeset
   159