Zobrazujú sa príspevky s označením *-release. Zobraziť všetky príspevky
Zobrazujú sa príspevky s označením *-release. Zobraziť všetky príspevky

utorok 17. decembra 2019

Update Debian 9

Update Debianu:

Alebo ako som si updatoval operačný systém. (Nie upgrade na novšiu verziu)

1. Zistíme, či máme vôbec voľné miesto:


root@guliverkel:/home/martin# df -h /dev/sda3
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3        15G  3.9G   11G  27% /


2. Zálohujem si grub


root@guliverkel:/home/martin# mkdir /media/data2/grub
root@guliverkel:/home/martin# cp /boot/grub/grub.cfg /media/data2/grub

root@guliverkel:/home/martin# ls -lh /media/data2/grub
total 12K
-r--r--r-- 1 root root 12K Dec 17 08:08 grub.cfg

3. Pozriem sa na to, akú konkrétnu verziu Debianu mám, plus aké mám jadro:


root@guliverkel:/home/martin# cat /etc/*release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
root@guliverkel:/home/martin# uname -r
4.9.0-8-amd64





4. Môžem spustiť prvý krok updatu (apt-get update) alebo v týchto novších verziách stačí apt update


root@guliverkel:/home/martin# apt update
Ign:1 http://ftp.sk.debian.org/debian stretch InRelease
Get:2 http://ftp.sk.debian.org/debian stretch Release [118 kB]
Get:3 http://ftp.sk.debian.org/debian stretch Release.gpg [2,365 B]                                                                                                                                                                                                         
Get:4 http://security.debian.org/debian-security stretch/updates InRelease [94.3 kB]                                                                                                                                                                                         
Get:5 http://ftp.sk.debian.org/debian stretch/main Sources [6,747 kB]                                                                                                                                                                                                       
Get:6 http://security.debian.org/debian-security stretch/updates/non-free Sources [1,216 B]                                                                                                                                                                                 
Get:7 http://security.debian.org/debian-security stretch/updates/main Sources [202 kB]                                                                                                                                                                                       
Get:8 http://security.debian.org/debian-security stretch/updates/main amd64 Packages [509 kB]                                                                                                                                                                               
Get:9 http://security.debian.org/debian-security stretch/updates/main Translation-en [224 kB]                                                                                                                                                                               
Get:10 http://security.debian.org/debian-security stretch/updates/non-free amd64 Packages [1,596 B]                                                                                                                                                                         
Get:11 http://ftp.sk.debian.org/debian stretch/contrib Sources [44.7 kB]                                                                                                                                                                                                     
Get:12 http://ftp.sk.debian.org/debian stretch/non-free Sources [79.4 kB]                                                                                                                                                                                                   
Get:13 http://ftp.sk.debian.org/debian stretch/main amd64 Packages [7,086 kB]                                                                                                                                                                                               
Get:14 http://ftp.sk.debian.org/debian stretch/main Translation-en [5,385 kB]                                                                                                                                                                                               
Get:15 http://ftp.sk.debian.org/debian stretch/non-free amd64 Packages [78.3 kB]                                                                                                                                                                                             
Get:16 http://ftp.sk.debian.org/debian stretch/non-free Translation-en [80.3 kB]                                                                                                                                                                                             
Get:17 http://ftp.sk.debian.org/debian stretch/contrib amd64 Packages [50.9 kB]                                                                                                                                                                                             
Fetched 20.7 MB in 6s (3,284 kB/s)                                                                                                                                                                                                                                           
Reading package lists... Done                                                                                                                                                                                                                                               
Building dependency tree                                                                                                                                                                                                                                                     
Reading state information... Done                                                                                                                                                                                                                                           
83 packages can be upgraded. Run 'apt list --upgradable' to see them. 


5. Tu mi vyhodí, čo bude upgradovať (len časť vypíšem)


root@guliverkel:/home/martin# apt list --upgradable                                                                                                                                                                                                                           
Listing... Done                                                                                                                                                                                                                                                             
base-files/oldstable 9.9+deb9u11 amd64 [upgradable from: 9.9+deb9u9]                                                                                                                                                                                                         
debian-archive-keyring/oldstable 2017.5+deb9u1 all [upgradable from: 2017.5]                                                                                                                                                                                                 
e2fslibs/oldstable 1.43.4-2+deb9u1 amd64 [upgradable from: 1.43.4-2]                                                                                                                                                                                                         
e2fsprogs/oldstable 1.43.4-2+deb9u1 amd64 [upgradable from: 1.43.4-2]       

6. spustím upgrade balíčkov:


root@guliverkel:/home/martin# apt upgrade
Reading package lists... Done
Building dependency tree     
Reading state information... Done
Calculating upgrade... Done
The following NEW packages will be installed:

83 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Need to get 176 MB of archives.
After this operation, 244 MB of additional disk space will be used.


7. spustím apt dist-upgrade


root@guliverkel:/home/martin# apt dist-upgrade
Reading package lists... Done
Building dependency tree     
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@guliverkel:/home/martin#


8. Keďže sa natiahli aj nejaké nové manuály, updatujem aj tie pomocou príkazu catman

catman - update man stránok

(niečo z catmanu)

root@guliverkel:/home/martin# catman

Updating cat files for section 1 of man hierarchy /usr/share/man
2to3-2.7, 2to3-3.5, 7z, 7za, 7zr, Xorg.wrap, acpi_available, add-apt-repository, apm_available, appres, appstreamcli, apropos, apt-extracttemplates, apt-ftparchive, apt-listchanges, apt-sortpkgs, ar, arch, ark, asn1parse, aspell,

9. rebootujem operačný systém (reboot and pray)

init 6

10. zistím, či sa nezmenil grub, verziu OS a jadra:


root@guliverkel:/home/martin# cat /etc/*release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
VERSION_CODENAME=stretch
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
root@guliverkel:/home/martin# uname -r
4.9.0-8-amd64
root@guliverkel:/home/martin# uptime -s
2019-12-17 08:22:25




piatok 6. decembra 2019

Verzia operačného systému

V ako linuxovom prostredí sa pohybujem?

Ako všetci dobre vieme, Linuxy sa od seba líšia. Všetko to začalo v roku 1957, keď vypustili do vesmíru Lajku. Nudiť vás ale Berkeleyho inštitútom, MIT a inými vecami nebudem. (Keď to inak veľmi chcete vedieť, Linus Torvalds hral v roku 1991 Princa a počas toho ako nevedel zabiť kostru, vymyslel Linux)

Linuxy sa menia, majú medzi sebou inú štruktúru, iný systém práce, iné konfiguračné súbory a podobne. V adresári /etc/ sa nachádzajú informácie o tom, aký je to operačný systém. (Niektoré systémy, dokonca aj SLES 15), majú v /etc/ adresári súbor os-release

martin@guliverkel:~$ cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"




(Niektoré žiaľ nie, preto sa odporúča používať hviezdičku)

martin@guliverkel:~$ cat /etc/*release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"


Niekde nájdeme aj balíček lsb a môžeme použiť tento príkaz:
martin@guliverkel:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 9.9 (stretch)
Release:        9.9
Codename:       stretch





Pre väčšie hrabanie v distribúciach odporúčam toto: https://upload.wikimedia.org/wikipedia/commons/1/1b/Linux_Distribution_Timeline.svg


a ešte toto: https://linuxconcept.com/top-10-linux-distribution-2019/

článok bol napísaný:

 martin@guliverkel:~$ date
Fri Dec  6 07:21:10 CET 2019