You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/15.md
+27-13Lines changed: 27 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ Today however, you'll be looking "under the covers" to see how this works; bette
16
16
17
17
* Add a new repo
18
18
* Remove a repo
19
-
* Find out where to get a program from (apt-search)
19
+
* Find out where to get a program from (aptsearch)
20
20
* Install a program without apt
21
21
22
22
## REPOSITORIES AND VERSIONS
@@ -27,11 +27,11 @@ Any particular Linux installation has a number of important characteristics:
27
27
* "Bit size" - 32-bit or 64-bit
28
28
* Chip - Intel, AMD, PowerPC, ARM
29
29
30
-
The version number is particularly important because it controls the versions of application that you can install. When Ubuntu 18.04 was released (in April 2018 - hence the version number!), it came out with Apache 2.4.29. So, if your server runs 18.04, then even if you installed Apache with `apt` five years later that is still the version you would receive. This provides stability, but at an obvious cost for web designers who hanker after some feature which later versions provide. (Security patches _are_ made to the repositories, but by "backporting" security fixes from later versions into the old stable version that was first shipped).
30
+
The version number is particularly important because it controls the versions of application that you can install. When Ubuntu 18.04 was released (in April 2018 - hence the version number!), it came out with Apache 2.4.29. So, if your server runs 18.04, then even if you installed Apache with `apt` five years later that is still the version you would receive. This provides stability, but at an obvious cost for web designers who hanker after some feature which later versions provide. Security patches _are_ made to the repositories, but by "backporting" security fixes from later versions into the old stable version that was first shipped.
31
31
32
32
## WHERE IS ALL THIS SETUP?
33
33
34
-
We'll be discussing the "package manager" used by the Debian and Ubuntu distributions, and dozens of derivatives. This uses the `apt` command, but for most purposes the competing `yum` and `dnf` commands used by Fedora, RHEL, CentOS and Scientific Linux work in a very similar way - as do the equivalent utilities in other versions.
34
+
We'll be discussing the "package manager" used by the Debian and Ubuntu distributions, and dozens of derivatives. This uses the `apt` command, but for most purposes the competing `yum` and `dnf` commands used by Red Hat family like RHEL, Fedora, RockyLinux, and CentOS will work in a very similar way - as do the equivalent utilities in other versions.
35
35
36
36
The configuration is done with files under the _/etc/apt_ directory, and to see where the packages you install are coming from, use `less` to view _/etc/apt/sources.list.d/ubuntu.sources_ where you'll see entries that specify repository URIs, suites, and components for your specific version:
37
37
@@ -73,13 +73,24 @@ After adding this, update your local cache of available applications:
73
73
74
74
`sudo apt update`
75
75
76
-
Once done, you should be able to install `netperf` like this:
76
+
Once done, search the application you're looking for with `apt-cache search netperf`, for example, instead of manually running the dump list. You will see a smaller list with names of packages related and a brief one-line description.
77
77
78
-
`sudo apt install netperf`
78
+
Then just check `netperf` like this:
79
+
80
+
`apt-cache policy netperf`
79
81
80
82
...and the output will show that it's coming from Multiverse.
Ubuntu also allows users to register an account and setup software in a Personal Package Archive (PPA) - typically these are setup by enthusiastic developers, and allow you to install the latest "cutting edge" software.
85
96
@@ -104,19 +115,22 @@ When you next run "sudo apt upgrade" you'll likely be prompted to install a new
104
115
105
116
## SUMMARY
106
117
107
-
Installing only from the default repositories is clearly the safest, but there are often good reasons for going beyond them. As a sysadmin you need to judge the risks, but in the example we came up with a realistic scenario where connecting to an unstable working developer’s version made sense.
118
+
Installing only from the default repositories is clearly the safest, but there are often good reasons for going beyond them. As a sysadmin you need to judge the risks, and evaluate if an application justify the use of different packaging managing solutions.
108
119
109
-
As general rule however you:
120
+
As a general rule:
110
121
111
-
*Will seldom have good reasons for hooking into more than one or two extra repositories
112
-
*Need to read up about a repository first, to understand any potential disadvantages.
122
+
*Have good reasons for hooking into more than one or two extra repositories; more is not necessarily better.
123
+
*Read up about a repository first, to understand any potential disadvantages.
0 commit comments