What is a command interpreter and why is it separate from the kernel?
A command interpreter is an interface of the operating system
with the user. The user gives commands with are executed by
operating system (usually by turning them into system calls). The
main function of a command interpreter is to get and execute the
next user specified command. Command-Interpreter is usually not
part of the kernel, since multiple command interpreters (shell, in
UNIX terminology) may be support by an operating system, and they
do not really need to run in kernel mode. There are two main
advantages to separating the command interpreter from the
kernel.
1. If we want to change the way the command interpreter looks,
i.e., I want to change the interface of command interpreter, I am
able to do that if the command interpreter is separate from the
kernel. I cannot change the code of the kernel so I cannot modify
the interface.
2. If the command interpreter is a part of the kernel it is
possible for a malicious process to gain access to certain part of
the kernel that it showed not have to avoid this ugly scenario it
is advantageous to have the command interpreter separate from
kernel