Questions tagged [operating-system]

An operating System (OS) is a software program whose role is to be an abstract layer between software requisitions for resources and the hardware available, manage input/output, memory allocation/deallocation, file systems, among other basic tasks a device (not necessarily a computer) should do.

An operating system (OS) is a basic software whose role is to be an abstract layer between software requisitions for resources and the hardware available. The basic components of an operational system can be listed as:

  • Boot loader

Although some may say it is not part of the OS, it's the starting point where the hardware after doing booting routines transfers the control to a small procedure that will bring up the entire system

  • User interface

Can be graphical or text-based, is the central point of communication between the user and the OS

  • Kernel

The core of the OS that manages all the resources of the hardware according to the requisitions. Kernels can be either a micro kernel or a monolithic kernel. Both types include the following functionality:

  • Process management (scheduling, multitasking, pseudo-parallelism, and so on)
  • Memory (and virtual memory) management
  • Inter-process communications (IPC)
  • Interrupt management

Monolithic kernels include these additional features:

  • File system and disk access organization
  • Device management (with the aid of device drivers, plug-and-play routines, dynamic modules, and so on)

These features are not included directly in a micro-kernel, but are instead implemented in tasks. One example of a fairly widely used micro-kernel is QNX. As well, many hypervisors are micro kernel designs. A major argument for micro-kernels is that their small size makes them easier to analyze and more secure.Tanenbaum

Most well known operating systems are monolithic. In fact, the majority of commercial and Open source OS's are monolithic. Generally they allow faster hardware response.

Book : Operating System Concepts by Abraham Silberschatz

Recommended preliminary reading before posting a question: OSDev Wiki

See also: .

13710 questions
5
votes
1 answer

Understanding os bootloading - assembly

I am trying to go more indepth os understanding. So, the linux boot has to deal with an assembly file. I know about mov, push, pop, but here I am quite lost with this : .globl __start .ent __start __start: br $29,2f 2: ldgp …
epsilones
  • 11,279
  • 21
  • 61
  • 85
5
votes
4 answers

What happens in the CPU when there is no user code to run?

It sounds reasonable that the os/rtos would schedule an "Idle task". In that case, wouldn't it be power consuming? (it sounds reasonable that the idle task will execute: while (true) {} )
Yony
  • 680
  • 1
  • 9
  • 20
5
votes
1 answer

Python: os.path.isfile won't recognise files beginning with a number

So, I'm trying to incorporate os.path.isfile or os.path.exists into my code with success in finding certain regular files(pdf,png) when searching for filenames that begin with a letter. The file naming standard that I'm using (and can't change due…
user2111029
  • 51
  • 1
  • 2
5
votes
1 answer

Adding my application to the Finder's context menu?

I have an application that I'm developing that deals with files of any type. I would like the user to be able to right click on any type of file in the Finder and have my menu option show up. I understand you have to add your application as a…
SevenBits
  • 2,836
  • 1
  • 20
  • 33
5
votes
2 answers

How are system calls handled in a virtual machine?

I was wondering how a system call is treated when used in a virtual machine. Does it send some kind of signal through the virtualizing kernel and then to the "real" kernel (of the physical machine)? I googled the subject but I can't seem to find…
n00b1990
  • 1,189
  • 5
  • 17
  • 25
5
votes
2 answers

Why do we need separate kernel stack for each CPU

In practice, many operating systems are designed to have one kernel stack for each thread, or at least one for each CPU. But for an operating system that the kernel is locked every time a process traps, it seems unnecessary to have separated kernel…
Phil Guo
  • 67
  • 2
5
votes
1 answer

Writing character device driver, ioctl() vs normal read/write?

I've been toying with writing a character device module for the linux kernel and I came to a bit of a confusing stop. I see online there is talk of using ioctl() to transfer commands/data from user programs to kernel space and vice-versa. But a lot…
John Lotacs
  • 1,184
  • 4
  • 20
  • 34
5
votes
4 answers

How does external fragmentation happen?

As processes are loaded and removed from memory , the free memory space is broken into little pieces ,causing fragmentation ... but how does this happen ? And what is the best solution to external fragmentation ?
user1849908
5
votes
4 answers

Can I run C and C++ on any platform?

If I write in C or C++ on for example: Windows. Is it guaranteed than I can compile and run it on any other operating system such as Mac OS, Linux, Unix-like systems? So, does it mean C or C++ is cross-platform language?
user963241
  • 6,758
  • 19
  • 65
  • 93
5
votes
2 answers

Privilege levels implementation

I understand that in general a cpu can run in one of two modes: a high level permission mode that in which access to "secure" zones in the hardware is enabled, and a low level permission mode that is used when accessing the rest of the cpu…
crimsonsky2005
  • 2,953
  • 4
  • 16
  • 14
5
votes
1 answer

Reading output of git push from PHP exec() function

I'm writing a deployment command for my framework's command line tool. It uses git to deploy. I have a line where I do this: exec("git push {$remote} {$branch}:{$branch}", $shell_output, $status); I would like to have the output of the push inside…
Nathan Kot
  • 2,392
  • 1
  • 21
  • 31
5
votes
3 answers

how to get process id attached with particular port in sunos

I am trying to get processes attached with a port 7085 on SunOS. i tried following commands. netstat -ntlp | grep 7085 didn't return anything netstat -anop | grep 7085 tried this one also. This switches are not valid in SunOs I am getting the…
LOGAN
  • 1,025
  • 2
  • 10
  • 14
5
votes
9 answers

What's the advantage of writing an OS entirely in assembly?

MenuetOS is an example of an OS written entirely in Assembly. Is there any advantage to writing it in Assembly instead of a low-level programming language such as C?
Lawand
  • 1,094
  • 2
  • 16
  • 40
5
votes
5 answers

Firefox OS Architecture

Is there any information available on the core architecture of the Firefox OS? I don't mean developer-facing information only. I am interested in the underlying architecture similar to that of Android available here:…
recluze
  • 1,920
  • 4
  • 21
  • 34
5
votes
4 answers

When could 2 virtual addresses map to the same physical address?

An operating system/computer architecture question here. I was reading about caches, about how virtually indexing the cache is an option to reduce address translation time. I came across the following: "Virtual cache difficulties include: …
JDS
  • 16,388
  • 47
  • 161
  • 224