Hier werden die Unterschiede zwischen zwei Versionen gezeigt.
Beide Seiten, vorherige Überarbeitung Vorherige Überarbeitung Nächste Überarbeitung | Vorherige Überarbeitung | ||
admin_grundlagen:apt [2013/02/04 15:39] 127.0.0.1 Externe Bearbeitung |
admin_grundlagen:apt [2023/02/28 12:57] (aktuell) carsten_strotmann |
||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
- | ====== debconf ====== | ||
- | |||
- | Anzeigen, welche Einstellungen bei der Installation des Paketes ''exim4-config'' vorgenommen wurden: | ||
- | debconf-show exim4-config | ||
- | |||
- | Nur die mit * gekennzeichneten Einträge sind vom Benutzer erfragt worden. | ||
- | |||
- | Man kann die von debconf gestellten Fragen vorab mit dem dem Befehl ''debconf-set-selections'' beantworten: | ||
- | <code bash> | ||
- | debconf-set-selections <<DEBCONF | ||
- | # Other destinations for which mail is accepted: | ||
- | exim4-config exim4/dc_other_hostnames string notebook01.linuxhotel.de | ||
- | # General type of mail configuration: | ||
- | exim4-config exim4/dc_eximconfig_configtype select local delivery only; not on a network | ||
- | # Root and postmaster mail recipient: | ||
- | exim4-config exim4/dc_postmaster string | ||
- | # System mail name: | ||
- | exim4-config exim4/mailname string notebook01.linuxhotel.de | ||
- | # Split configuration into small files? | ||
- | exim4-config exim4/use_split_config boolean false | ||
- | # IP-addresses to listen on for incoming SMTP connections: | ||
- | exim4-config exim4/dc_local_interfaces string 127.0.0.1 | ||
- | DEBCONF | ||
- | </code> | ||
- | |||
- | Der Befehl ''debconf-get-selections'' aus dem Paket ''debconf-utils'' erzeugt eine Ausgabe, die man leicht als Eingabe für den Befehlt ''debconf-set-selections'' verwenden kann: | ||
- | debconf-get-selections | grep -B 1 ^exim4-config | ||
- | //Achtung: die Ausgabe von ''debconf-get-selections'' enthält ein Tabulatorzeichen zwischen den 4 Feldern, daß in Terminals uU. als mehrere Leerzeichen dargestellt wird. Die Eingabe von ''debconf-set-selections'' darf aber immer nur genau 1 Whitespace-Zeichen enthalten.// | ||
- | |||
====== apt ====== | ====== apt ====== | ||
- | ===== Paket-Signatur ===== | + | ===== dist-upgrade ===== |
- | === Schlüssel über Paket beziehen === | + | [[admin_grundlagen:debian_dist-upgrade|Debian von einer Version zur nächsten aktualisieren]] |
- | Für Debian gültige Schlüssel finden sich im Paket ''debian-archive-keyring'' und können nachträglich mit folgenden Befehlen geladen werden: | + | |
- | aptitude install debian-archive-keyring | + | |
- | apt-key update | + | |
- | + | ||
- | Paketliste aktualisieren - sollte jetzt ohne Fehlermeldung klappen: | + | |
- | aptitude update | + | |
- | + | ||
- | Schlüssel für das Debian-Archiv finden sich auch unter http://ftp-master.debian.org/ | + | |
- | + | ||
- | === Schlüssel über Datei beziehen === | + | |
- | Im Fall von debian-volatile ( http://www.debian.org/volatile ) gibt es kein Paket, sondern man muß den Schlüssel von Hand runterladen und dann importieren: | + | |
- | wget http://www.debian.org/volatile/etch-volatile.asc | + | |
- | apt-key add etch-volatile.asc | + | |
- | apt-key update | + | |
- | + | ||
- | Nachschauen obs geklappt hat: | + | |
- | apt-key list | + | |
- | + | ||
- | Paketliste aktualisieren - sollte jetzt ohne Fehlermeldung klappen: | + | |
- | aptitude update | + | |
- | === Schlüssel über Key-Server beziehen === | + | ===== Paket aus Drittanbieter-Repository installieren mit extrepo ====== |
- | Im Fall von anderen Quellen die nur die PGP Signatur veröffentlichen gilt folgendes Verfahren: | + | |
- | gpg --keyserver hkp://wwwkeys.eu.pgp.net --recv-keys DB90D8FC306B6783 | + | |
- | gpg --armor --export DB90D8FC306B6783 | apt-key add - | + | |
- | === Links === | + | Beispiel: aktuellen Kernel aus Debian-Backports installieren |
- | * http://wiki.debian.org/SecureApt | + | |
+ | Paketquelle und Schlüssel hinzufügen: | ||
+ | apt install extrepo | ||
+ | extrepo enable debian_backports | ||
+ | cat /etc/apt/sources.list.d/extrepo_debian_backports.sources | ||
- | ===== Repositories mischen ===== | + | Paket aus Backports-Repository installieren: |
- | http://jaqque.sbih.org/kplug/apt-pinning.html | + | apt update |
+ | apt policy linux-image-amd64 | ||
+ | apt install -t bullseye-backports linux-image-amd64 | ||
- | ===== Pakete zu bestimmten Dateien finden ===== | + | ===== Paket zu bestimmten Dateien finden ===== |
Hierzu ist das Paket //apt-file// hilfreich: | Hierzu ist das Paket //apt-file// hilfreich: | ||
- | aptitude install apt-file | + | apt install apt-file |
apt-file update | apt-file update | ||
apt-file search /bin/sh | apt-file search /bin/sh | ||
Zeile 82: | Zeile 35: | ||
oder im Menu Aptitude/Options/Dependency Handling/ [X] Install Recommended Packages automatically => abwählen | oder im Menu Aptitude/Options/Dependency Handling/ [X] Install Recommended Packages automatically => abwählen | ||
- | ===== Abhängige Pakete bei apt-get remove automatisch entfernen ===== | + | ===== Abhängige Pakete bei apt remove automatisch entfernen ===== |
- | ''/etc/apt/apt.conf.d/no-cache'' : | + | ''/etc/apt/apt.conf.d/aito-remove'' : |
<file> | <file> | ||
APT::Get::AutomaticRemove "1"; | APT::Get::AutomaticRemove "1"; | ||
Zeile 104: | Zeile 57: | ||
Einzelne Datei aus einem .deb-Paket rausfischen: | Einzelne Datei aus einem .deb-Paket rausfischen: | ||
dpkg --fsys-tarfile /var/cache/apt/archives/xen-utils-common_3.0.3-0-2_all.deb | tar -x -O -f - ./usr/share/doc/README | dpkg --fsys-tarfile /var/cache/apt/archives/xen-utils-common_3.0.3-0-2_all.deb | tar -x -O -f - ./usr/share/doc/README | ||
+ | |||
+ | ====== debconf ====== | ||
+ | |||
+ | Anzeigen, welche Einstellungen bei der Installation des Paketes ''exim4-config'' vorgenommen wurden: | ||
+ | debconf-show exim4-config | ||
+ | |||
+ | Nur die mit * gekennzeichneten Einträge sind vom Benutzer erfragt worden. | ||
+ | |||
+ | Man kann die von debconf gestellten Fragen vorab mit dem dem Befehl ''debconf-set-selections'' beantworten: | ||
+ | <code bash> | ||
+ | debconf-set-selections <<DEBCONF | ||
+ | # Other destinations for which mail is accepted: | ||
+ | exim4-config exim4/dc_other_hostnames string notebook01.linuxhotel.de | ||
+ | # General type of mail configuration: | ||
+ | exim4-config exim4/dc_eximconfig_configtype select local delivery only; not on a network | ||
+ | # Root and postmaster mail recipient: | ||
+ | exim4-config exim4/dc_postmaster string | ||
+ | # System mail name: | ||
+ | exim4-config exim4/mailname string notebook01.linuxhotel.de | ||
+ | # Split configuration into small files? | ||
+ | exim4-config exim4/use_split_config boolean false | ||
+ | # IP-addresses to listen on for incoming SMTP connections: | ||
+ | exim4-config exim4/dc_local_interfaces string 127.0.0.1 | ||
+ | DEBCONF | ||
+ | </code> | ||
+ | |||
+ | Der Befehl ''debconf-get-selections'' aus dem Paket ''debconf-utils'' erzeugt eine Ausgabe, die man leicht als Eingabe für den Befehlt ''debconf-set-selections'' verwenden kann: | ||
+ | debconf-get-selections | grep -B 1 ^exim4-config | ||
+ | //Achtung: die Ausgabe von ''debconf-get-selections'' enthält ein Tabulatorzeichen zwischen den 4 Feldern, daß in Terminals uU. als mehrere Leerzeichen dargestellt wird. Die Eingabe von ''debconf-set-selections'' darf aber immer nur genau 1 Whitespace-Zeichen enthalten.// | ||
+ | |||