2
$\begingroup$

I have a doubt about loading kernel for every user using a Multi-User system. Every user's processes and programs are scheduled to CPU in a time-sharing fashion. But, do every user on the multi-user system have their individual kernel loaded in the main memory, or is there only one kernel loaded which is sort of distributed amongst the users?

$\endgroup$
6
  • $\begingroup$ From my knowledge (Im not an expert), Its only one kernel, and different users just use up different storage in the hard-disk. Thats the file system's problem to handle, so I think only one kernel exists for all of the users $\endgroup$
    – nir shahar
    May 14, 2021 at 15:00
  • $\begingroup$ Also it makes sense, how else would you be able to interact with the login screen? $\endgroup$
    – nir shahar
    May 14, 2021 at 15:01
  • $\begingroup$ @nirshahar For that you would need individual kernel loaded for individual computers, I guess. $\endgroup$
    – Sandeep
    May 14, 2021 at 15:18
  • $\begingroup$ Aren't you talking about a single computer with more than one user in it? $\endgroup$
    – nir shahar
    May 14, 2021 at 15:21
  • $\begingroup$ @nirshahar No, I am talking about a multi-user operating system, where many users can utilize computer resources simultaneously sitting at their own terminal. $\endgroup$
    – Sandeep
    May 14, 2021 at 15:23

2 Answers 2

3
$\begingroup$

The shell (or window manager) which provides a visual interface is not part of the kernel. It's a simple user process and it runs in userspace without elevated privileges. In order for the user to "log in", which involves associating their terminal with the shell (or window manager), a login manager is needed. This program does run with elevated privileges, but it is also not part of the kernel. And there is only one instance of it.

Almost all user processes interact at some point with the kernel, usually by triggering a software interrupt which is caught by the kernel and triggers some kind of kernel request handler. There is only one copy of the executable image which contains kernel functions, but each handler needs to run independently and normally requires some transient storage. This would most naturally be stored on a stack, as with the transient storage for any ordinary procedure. However the "kernel stack" for a process is provided, it will by unique to the process. But it's usually not very big at all.

$\endgroup$
1
$\begingroup$

The multi-user operating system is also a single machine which is desiged to allow multiple users to connect to it at the same time. so you can imagine it as a unix server and users have access to it. so at the end there is just the kernel of the server(or multi-user OS in this case)

$\endgroup$
2
  • $\begingroup$ Yeah. But not everyone's terminal will be open all the time or open at the same time. Each one will also have their login window. $\endgroup$
    – Sandeep
    May 14, 2021 at 15:42
  • $\begingroup$ + ('or is there only one kernel loaded which is sort of distributed amongst the users?'), after accessing it, then the OS will directly ask for the login credentials, hence it will direct the user to its own workplace. (just like a normal os which has multiple users but it's on the cloud), so yeah just one kernel will control everything $\endgroup$
    – MR.-c
    May 14, 2021 at 15:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.