1 00:00:07,350 --> 00:00:08,610 - So for the lab solution, 2 00:00:08,610 --> 00:00:10,740 I'm going to use Santo S. 3 00:00:10,740 --> 00:00:11,640 For the simple reason 4 00:00:11,640 --> 00:00:12,570 that we have already seen 5 00:00:12,570 --> 00:00:15,060 how to to use Net plan 6 00:00:15,060 --> 00:00:16,230 with System D, Network D 7 00:00:16,230 --> 00:00:18,989 to set static IP addresses on Ubuntu. 8 00:00:18,989 --> 00:00:22,830 Here is the the network manager approach 9 00:00:22,830 --> 00:00:26,010 and for a change I wanna use NMCLI 10 00:00:26,010 --> 00:00:26,970 just to show you 11 00:00:26,970 --> 00:00:28,980 that it doesn't have to be this scary. 12 00:00:28,980 --> 00:00:30,810 As I told you before on the exam 13 00:00:30,810 --> 00:00:32,920 I don't recommend using NMCLI on the exam. 14 00:00:32,920 --> 00:00:35,250 You should use NMTUI, 15 00:00:35,250 --> 00:00:37,290 which is much more intuitive. 16 00:00:37,290 --> 00:00:39,510 But for now NMCLI connection, 17 00:00:39,510 --> 00:00:42,660 I'm going to to create a connection. 18 00:00:42,660 --> 00:00:45,080 So connection allows me to do what, we have 19 00:00:45,080 --> 00:00:47,910 add and clone and delete and down 20 00:00:47,910 --> 00:00:50,610 and edit and modify. 21 00:00:50,610 --> 00:00:53,220 Can we get there through modify? 22 00:00:53,220 --> 00:00:55,875 So I'm modifying ENS 33 23 00:00:55,875 --> 00:01:00,875 and oh boy, display all 296 possibilities. 24 00:01:01,110 --> 00:01:02,613 Yeah, I wanna see all of them. 25 00:01:03,840 --> 00:01:05,580 Yes. So give you some insight 26 00:01:05,580 --> 00:01:07,710 in the parameters that are available. 27 00:01:07,710 --> 00:01:12,690 Well, obviously what we need is an IPV 4 dot something. 28 00:01:12,690 --> 00:01:15,000 So I'm going to quit out these options 29 00:01:15,000 --> 00:01:18,040 and I'm going to use IPV 4 DEP DEP 30 00:01:18,990 --> 00:01:23,070 so that we can see a reasonable amount of options. 31 00:01:23,070 --> 00:01:24,780 So what do we need? 32 00:01:24,780 --> 00:01:26,830 IPV 4 four method 33 00:01:27,780 --> 00:01:31,917 and this method is going to be manual. 34 00:01:31,917 --> 00:01:34,350 That's an important one. 35 00:01:34,350 --> 00:01:38,250 If you don't set it to manual, it'll still be automatic 36 00:01:38,250 --> 00:01:39,800 and it might fill. 37 00:01:39,800 --> 00:01:43,710 The next thing we need is the, the address. 38 00:01:43,710 --> 00:01:47,010 So IPV 4 addresses and I'm setting it 39 00:01:47,010 --> 00:01:52,010 to 192, 168, 29, 50/24. 40 00:01:52,781 --> 00:01:54,450 Then what else do we need? 41 00:01:54,450 --> 00:01:57,750 Well, we need gateway. 42 00:01:57,750 --> 00:02:02,163 So IPV 4.gateway 192, 168, 29. two. 43 00:02:06,270 --> 00:02:08,040 And, is there anything else that we need? 44 00:02:08,040 --> 00:02:11,064 Well, probably an IPV 4.DNS. 45 00:02:11,064 --> 00:02:15,950 And let's also set that to 192, 168, 29.2. 46 00:02:18,000 --> 00:02:22,410 pressing enter, and there we can see the result. 47 00:02:22,410 --> 00:02:25,260 Now can we, I'm using IPA 48 00:02:25,260 --> 00:02:28,950 and in IPA we still see the old configuration. 49 00:02:28,950 --> 00:02:32,490 And in the old configuration there is the DHCP 50 00:02:32,490 --> 00:02:36,393 assigned IP address and we have this dynamic option as well. 51 00:02:37,950 --> 00:02:40,790 Now if I'm using NMCLI connection, 52 00:02:43,789 --> 00:02:48,789 there is this connection down on ENS 33 53 00:02:50,640 --> 00:02:54,930 and then I'm using connection up on ENS 33 54 00:02:54,930 --> 00:02:56,253 to bring it up again. 55 00:02:57,180 --> 00:02:59,580 And now we've used IPA. 56 00:02:59,580 --> 00:03:01,720 There, we can see that the new configuration 57 00:03:01,720 --> 00:03:05,760 was correctly used, including the error. 58 00:03:05,760 --> 00:03:10,260 Did you see that? 192, 168, 29 50/25. 59 00:03:10,260 --> 00:03:14,130 That's not the right subnet mask, but that was a typo. 60 00:03:14,130 --> 00:03:17,850 So we need to get back and we need to modify it again. 61 00:03:17,850 --> 00:03:19,680 And the easiest way 62 00:03:19,680 --> 00:03:23,880 is probably just to rerun the entire command. 63 00:03:23,880 --> 00:03:26,610 So now let's bring it down again 64 00:03:26,610 --> 00:03:30,420 and let's bring it up again and IPA 65 00:03:30,420 --> 00:03:34,170 and now you can see that the connection is alright. 66 00:03:34,170 --> 00:03:37,830 Oh, an IP route show is also showing the routing 67 00:03:37,830 --> 00:03:40,410 the default route going through 29.2. 68 00:03:40,410 --> 00:03:42,110 And that's exactly what we wanted.