1
00:00:06,620 --> 00:00:13,155
In this video I'll tell you how you can enter boot
parameters to change the way how Linux starts. Boot parameters can be

2
00:00:13,155 --> 00:00:19,690
entered on the grip prompt and to access the grip prompt
while booting, you can press the escape key at the right moment.

3
00:00:20,469 --> 00:00:26,690
Finding the right moment is not always easy by the
way, but keep on trying. I'm sure you will get there.

4
00:00:28,050 --> 00:00:31,750
As an alternative, if a
system boot was not completed successfully,

5
00:00:31,750 --> 00:00:35,450
the next boot will automatically
show the Grub boot menu.

6
00:00:35,969 --> 00:00:40,810
So if ever you wanted to access the
Grub boot prompt and you don't succeed, just reset

7
00:00:40,810 --> 00:00:45,650
your machine while it is booting to automatically
see the boot prompt when it comes up again.

8
00:00:46,350 --> 00:00:52,020
All of the boot arguments that are entered while
booting are non persistent and mainly used for troubleshooting.

9
00:00:53,630 --> 00:00:59,274
And the main boot arguments that you can
use is systemd unit followed by the systemd

10
00:00:59,274 --> 00:01:04,920
unit unit that you want to use. Emergency
Target is for hardcore troubleshooting. Rescue Target is

11
00:01:04,920 --> 00:01:10,564
bringing you a little bit further Multi user
Target is a complete operational environment and graphical

12
00:01:10,564 --> 00:01:16,209
target is what you normally start when
you boot a graphical Linux operating system.

13
00:01:16,849 --> 00:01:20,069
Let me show you how you
can interact with this Grub boot menu.

14
00:01:21,930 --> 00:01:24,750
So I need to
start by rebooting my system.

15
00:01:25,400 --> 00:01:27,000
This is where I
need to pay attention.

16
00:01:28,540 --> 00:01:33,880
My trick is you will see a cursor
appearing when you see the cursor appearing and you

17
00:01:33,880 --> 00:01:39,220
press Escape at that moment and normally you
are all right, but that might depend on your

18
00:01:39,219 --> 00:01:44,560
distribution. No guarantees here. Again, if you can't
access the grip boot menu, just reset the virtual

19
00:01:44,560 --> 00:01:49,900
machine while it is rebooting. Here we
have all the different options for booting.

20
00:01:50,879 --> 00:01:56,730
I'm going to select Centos Stream and press Enter
E for Edit to get access to the different

21
00:01:56,730 --> 00:02:02,580
boot options. And the line that matters here is
the line that starts with Linux. That is the

22
00:02:02,579 --> 00:02:08,430
line that starts the Linux kernel. This Linux kernel
is the VM Linus file that you can see.

23
00:02:08,990 --> 00:02:14,789
Now all of these parameters are
quite okay. I don't like RHGB

24
00:02:14,789 --> 00:02:20,589
and quiet so that is already
a good start to remove them.

25
00:02:20,590 --> 00:02:26,389
And next I'm going to
use systemd unit is Emergency target.

26
00:02:27,710 --> 00:02:34,275
Now we have seen this before. If you want to start
Emergency target on a Red hat based system, you must have

27
00:02:34,275 --> 00:02:40,840
the root password set otherwise it won't work. So I'm
using Control X and then we can see what is happening.

28
00:02:41,539 --> 00:02:48,444
The problem is that this Emergency target is loading
a program with the name Sulogin which is super useful

29
00:02:48,444 --> 00:02:55,349
login. That's an additional level of protection and that
command won't work if you don't have a root password.

30
00:02:56,409 --> 00:02:59,840
From here you can do
whatever kind of troubleshooting you want.

31
00:03:00,360 --> 00:03:07,270
I happen to be not interested at all in troubleshooting, so I'm going
to reboot and I want to show you what it looks like on Ubuntu.

32
00:03:08,210 --> 00:03:10,969
Back on Ubuntu I'm also
going to use sudo reboot.

33
00:03:14,650 --> 00:03:20,860
Did you see that the cursor appeared? I
pressed escape and now I'm in my boot

34
00:03:20,860 --> 00:03:27,070
menu. Now I am going to use E
again to edit this grub boot menu there.

35
00:03:27,069 --> 00:03:33,280
We also have a line that starts
with Linux so that is looking okay.

36
00:03:33,639 --> 00:03:39,474
Well there's one thing that doesn't look okay and
that is this Quiet and splash. I really don't

37
00:03:39,474 --> 00:03:45,310
like this quiet and splash because that is
hiding what is going on while you are booting.

38
00:03:46,610 --> 00:03:52,530
I really like to see what is going on
while booting. That makes troubleshooting easier if that is required.

39
00:03:53,039 --> 00:03:58,393
Now I wanted to show you
systemd unit is emergency target because you

40
00:03:58,393 --> 00:04:03,746
need to understand how that works
on Ubuntu. As in Ubuntu the root

41
00:04:03,746 --> 00:04:09,099
user has no password by default,
so will that fail as well?

42
00:04:10,599 --> 00:04:16,360
Look at that. Ubuntu is prompting Press enter
to maintenance. The difference is at the end of

43
00:04:16,360 --> 00:04:22,120
the emergency target in Ubuntu there is no
SU login program. So I'm pressing enter and then

44
00:04:22,120 --> 00:04:27,879
I'm here in my root shell even if
the root user does not have a password.

45
00:04:28,279 --> 00:04:29,560
So that
works perfectly.
