[Intro Music]
All right, now let me demonstrate
you how you could get the list of
all running processes. For that you
could use command called 'ps'. If you
enter this command, you'll see
currently running processes for
this particular session. And at the
moment, I am inside of the Ubuntu
container. And I'm inside of the
bash process, I'm connected to
standard in of this process. I will
talk about what is standard in,
standard out in one of the next
lectures. Now, you understand that
I am in bash process; and this
process is listed here with
Process ID 1, here it is; and
here is command that was used for
start of corresponding process.
That means that when you enter any
command, Linux Kernel basically
starts specific process. And as you
may have noticed, here is another
process, 'ps'; and this process
appears here, because I have just
entered command 'ps' that has
started corresponding 'ps' process.
But I have got this output from
this 'ps' process. And basically,
this process did its job, and it is
not needed anymore. That's why this
process was terminated, was stopped.
And if you enter 'ps' once again,
you'll see 'ps' process once again on
the list, but this will be brand
new process. You may notice here
difference between those processes
ID, here and here. Alright, you are
also able to get the list of
different options that you are able
to use with 'ps' command using
following, ''ps --help'
command; and actually, if you want
to get help for 'ps' process, you
need to add also here, which
section of help you want to see.
And if you enter here, 'all' or
simply 'a', like this, you'll get all
available options. And if you'll
scroll a bit up, you'll find the
most commonly used options here in
this first section. For example,
with '-A' or '-e'
you are able to get list of all
processes. By default, you'll see
all the processes running by
current user. And if I'll enter
this option now, 'ps -e', I'll see
same two processes 'bash' and 'ps'; and
'bash' has Process ID 1, and 'ps' has
in my case Process ID 5153. And the
reason for that is that I'm
actually running a small Ubuntu
container, and there are no other
users logged into this container,
there is no graphical user
interface for this Ubuntu
container, that's why there are
only two processes in total. But if
I switch to Ubuntu computer and
list all processes here, 'ps -e',
I will see a long list of
different processes, because here
you see now full featured
computer with Ubuntu operating
system. It has this graphical user
interface, it has different
applications running, that's why it
has much much more processes. Here
is complete list. But if I enter
'ps' without any additional options,
I'll see similar output to this
picture. I see only two processes,
'bash' and 'ps'. And that's what I
have told you, with 'ps' command
without any additional options
you'll see only processes
started by a particular user. And
this user in this case is Bogdan.
Alright, that's all for this
introduction lecture, and next
let me demonstrate to you how to start
additional processes, and how to
kill processes. I'll see you next. Bye-Bye.
[no audio]