1 00:00:07,170 --> 00:00:09,540 - Let's talk about software managers. 2 00:00:09,540 --> 00:00:11,370 Now, what are software managers? 3 00:00:11,370 --> 00:00:13,500 Software managers are the solution 4 00:00:13,500 --> 00:00:15,240 to the dependency problem, 5 00:00:15,240 --> 00:00:16,440 and they're really cool. 6 00:00:17,460 --> 00:00:19,860 Software managers fix the dependency problem 7 00:00:19,860 --> 00:00:21,570 by working with the repositories. 8 00:00:21,570 --> 00:00:24,570 A repository is an online resource 9 00:00:24,570 --> 00:00:26,340 where packages are stored. 10 00:00:26,340 --> 00:00:28,560 And the nice thing about a repository is that 11 00:00:28,560 --> 00:00:30,570 as long as you make sure that all packages 12 00:00:30,570 --> 00:00:31,950 that may ever be required 13 00:00:31,950 --> 00:00:33,960 as a dependency are available, 14 00:00:33,960 --> 00:00:35,640 the software manager is taking care 15 00:00:35,640 --> 00:00:36,473 of the rest. 16 00:00:37,410 --> 00:00:38,790 Before installing a package, 17 00:00:38,790 --> 00:00:41,206 the software manager analyzes the dependencies 18 00:00:41,206 --> 00:00:43,380 and it'll try to fetch the dependencies 19 00:00:43,380 --> 00:00:45,000 from the repositories. 20 00:00:45,000 --> 00:00:45,930 So you will never see 21 00:00:45,930 --> 00:00:48,903 the missing dependencies messages anymore. 22 00:00:49,740 --> 00:00:52,290 Now, software repositories are provided 23 00:00:52,290 --> 00:00:54,420 by the Linux distributions. 24 00:00:54,420 --> 00:00:56,760 Typically, when you install a Linux distribution, 25 00:00:56,760 --> 00:00:59,850 you get access to the standard software repositories 26 00:00:59,850 --> 00:01:02,610 and every distribution makes sure that you have access 27 00:01:02,610 --> 00:01:06,630 to thousands of packages in the software repositories. 28 00:01:06,630 --> 00:01:09,360 Alternatively, you can work 29 00:01:09,360 --> 00:01:11,700 with software repositories that are provided 30 00:01:11,700 --> 00:01:13,530 by software vendors 31 00:01:13,530 --> 00:01:15,303 and you can even create your own. 32 00:01:16,860 --> 00:01:18,660 Software managers that are common, 33 00:01:18,660 --> 00:01:20,430 in the Reddit and family, 34 00:01:20,430 --> 00:01:22,080 we use YUM and DNF. 35 00:01:22,080 --> 00:01:24,330 In Ubuntu, it's APT, 36 00:01:24,330 --> 00:01:27,480 and we will explore what they look like in the next video. 37 00:01:27,480 --> 00:01:29,850 But first, I want to make a drawing to show you 38 00:01:29,850 --> 00:01:33,603 how software managers relate to the repositories. 39 00:01:35,640 --> 00:01:38,040 In order to understand software managers, 40 00:01:38,040 --> 00:01:40,660 you should understand the dependencies 41 00:01:41,640 --> 00:01:45,240 because it's all about dealing with dependencies. 42 00:01:45,240 --> 00:01:46,810 So in a software manager, 43 00:01:46,810 --> 00:01:50,283 the central point is the repository. 44 00:01:51,240 --> 00:01:52,830 Now what is the repository? 45 00:01:52,830 --> 00:01:57,830 Well, the repository is an online and onsite resource 46 00:01:57,930 --> 00:02:00,240 that contains packages. 47 00:02:00,240 --> 00:02:01,667 Many packages. 48 00:02:01,667 --> 00:02:05,100 You can have one repository, that sounds really common. 49 00:02:05,100 --> 00:02:08,700 Most of the cases, you will have multiple repositories. 50 00:02:08,700 --> 00:02:11,100 And then you are going to use your software manager 51 00:02:11,100 --> 00:02:14,220 to install packages from these repositories. 52 00:02:14,220 --> 00:02:18,000 So let's imagine that DNF is your software manager. 53 00:02:18,000 --> 00:02:21,254 Then DNF is going to be configured to fetch the packages 54 00:02:21,254 --> 00:02:24,420 from these repositories. 55 00:02:24,420 --> 00:02:26,460 And if it finds any dependencies, 56 00:02:26,460 --> 00:02:30,450 it'll automatically resolve these dependencies. 57 00:02:30,450 --> 00:02:33,720 And the result of the work of the software manager 58 00:02:33,720 --> 00:02:37,770 is that it keeps track of installed packages 59 00:02:37,770 --> 00:02:40,110 in a local database. 60 00:02:40,110 --> 00:02:43,050 And having this local database is a good thing, 61 00:02:43,050 --> 00:02:45,509 because if you have this local database, 62 00:02:45,509 --> 00:02:50,130 then you can see which version, for instance, 63 00:02:50,130 --> 00:02:52,143 of a software package you are using. 64 00:02:53,370 --> 00:02:54,660 Now, why is that good? 65 00:02:54,660 --> 00:02:55,740 Well, that is good 66 00:02:55,740 --> 00:02:59,850 because your software manager can fetch an index 67 00:02:59,850 --> 00:03:01,350 from the repository. 68 00:03:01,350 --> 00:03:06,120 In this index, it can compare the index. 69 00:03:06,120 --> 00:03:07,710 It can compare the versions 70 00:03:07,710 --> 00:03:09,810 of the packages in the software repository, 71 00:03:09,810 --> 00:03:10,643 to the versions 72 00:03:10,643 --> 00:03:13,770 of the packages that you have installed locally. 73 00:03:13,770 --> 00:03:16,140 And then you can even do update accents to 74 00:03:16,140 --> 00:03:18,450 make it easy to update packages. 75 00:03:18,450 --> 00:03:21,750 And all of these are benefits of software managers. 76 00:03:21,750 --> 00:03:23,940 I have used DNF in my example, 77 00:03:23,940 --> 00:03:24,810 of course, this works 78 00:03:24,810 --> 00:03:28,473 for other software managers, such as APT and YUM as well.