Computer Forums

Member Login

Remember Me? Sign Up! | Forgot Password
 
Slogan
 
Closed Thread
Old 02-05-2006, 08:50 PM   #1 (permalink)
 
Newb Techie

Join Date: Feb 2006

Posts: 3

_Insomnia_

Default Os

What`s happening before the Windows or Linux or other OS boots? I meen how the boot process works?
What kind of test, programs load in memory and what data are consulted from the harddisk before an operating systems starts booting?
And if you know whats happening after that step feel free to tell me please.
Thank you.
_Insomnia_ is offline  
Old 02-07-2006, 09:43 AM   #2 (permalink)
office politics's Avatar
 
It's all just 1s and 0s

Join Date: Jan 2004

Location: in the lab

Posts: 4,425

office politics will become famous soon enough

Default

http://computer.howstuffworks.com/operating-system4.htm
Wake-Up Call

When you turn on the power to a computer, the first program that runs is usually a set of instructions kept in the computer's read-only memory (ROM). This code examines the system hardware to make sure everything is functioning properly. This power-on self test (POST) checks the CPU, memory, and basic input-output systems (BIOS) for errors and stores the result in a special memory location. Once the POST has successfully completed, the software loaded in ROM (sometimes called the BIOS or firmware) will begin to activate the computer's disk drives. In most modern computers, when the computer activates the hard disk drive, it finds the first piece of the operating system: the bootstrap loader.

The bootstrap loader is a small program that has a single function: It loads the operating system into memory and allows it to begin operation. In the most basic form, the bootstrap loader sets up the small driver programs that interface with and control the various hardware subsystems of the computer. It sets up the divisions of memory that hold the operating system, user information and applications. It establishes the data structures that will hold the myriad signals, flags and semaphores that are used to communicate within and between the subsystems and applications of the computer. Then it turns control of the computer over to the operating system.

The operating system's tasks, in the most general sense, fall into six categories:

Processor management
Memory management
Device management
Storage management
Application interface
User interface

While there are some who argue that an operating system should do more than these six tasks, and some operating-system vendors do build many more utility programs and auxiliary functions into their operating systems, these six tasks define the core of nearly all operating systems. Let's look at the tools the operating system uses to perform each of these functions.
office politics is offline  
Old 02-20-2006, 01:30 PM   #3 (permalink)
simple's Avatar
 
True Techie

Join Date: Jan 2006

Location: Earth

Posts: 171

simple

Default

ok well !! i know most of this part you said!! i know the data structures and BIOS etc .. but wht i dont know is what you said below
Quote:
It establishes the data structures that will hold the myriad signals, flags and semaphores that are used to communicate within and between the subsystems and applications of the computer.
i would be glad if you took the time to explain a bit more. thanks and c ya!!!
simple is offline  
Old 02-20-2006, 11:29 PM   #4 (permalink)
office politics's Avatar
 
It's all just 1s and 0s

Join Date: Jan 2004

Location: in the lab

Posts: 4,425

office politics will become famous soon enough

Default

Quote:
that are used to communicate within and between the subsystems and applications of the computer.
it handles to transfer of information from the physical layer of the mobo ops to the application layer of the os.

aka it takes the 1s & 0s from the mobo and translates it to a software language
office politics is offline  
Old 02-21-2006, 02:46 AM   #5 (permalink)
 
Ultra Techie

Join Date: Jul 2005

Posts: 530

TheHeadFL

Send a message via AIM to TheHeadFL
Default

Quote:
Originally posted by csamuels
it handles to transfer of information from the physical layer of the mobo ops to the application layer of the os.

aka it takes the 1s & 0s from the mobo and translates it to a software language
I wouldn't say that this is an accurate description of what was being described in the article.

Signals, semaphores, and flags are used for inter-process communication within an operating system.

They are basically all similar forms of the same thing, so I'll just describe what a semaphore is in general.

If you have two threads (or processes) that need to access the same shared resource, there must be a way to arbitrate which thread may access the resource at which time.

The simplest form of semaphore is the binary semaphore which is always either in a locked or unlocked state.

Consider two threads, Thread A and Thread B, which both want to access some common memory locations X and Y.

Thread A wants to execute:
Y = X + 2
X++

Thread B wants to execute:
X++
Y = X + 2

Now, without semaphores, the order in which these statements are executed is critical to the result.

Assume X initially equals 1.

If Thread A executes entirely before Thread B, then when thread A completes, the value of X will be 2, and Y will be 3. When Thread B completes subsequently, the value of X will be 3 and the value of Y will be 5.

Now, if Thread A is interleaved with Thread B such that the statements are executed A1, B1, A2, B2, the values at the end will be X = 3, Y = 5.

Now interleave them the other way. B1, A1, B2, A2. The values will be X = 3, Y = 4.

Clearly, the results of this execution are unpredictable, and thus unacceptable. If calculations depend on the result of these two small code sections, bugs could be introduced based on subtle timing variations.

Semaphores introduce the concept of the 'atomic operation'. Normally an operation like X++ is actually executed as Temp = X, Add Temp, X, X = Temp. Therefore, this operation could actually be interleaved in any number of unpredictable ways. In order to make these operations 'threadsafe' binary semaphores allow the programmer to ensure that this cannot happen.

Now, you would have the concept of something called a critical section, which is the section of a thread that accesses shared memory.

Therefore you have:

Code:
// Some non-shared code
Request Semaphore
If successful
   // Critical section
   // Release semaphore
Else
   // Wait until semaphore is released
   // Request semaphore
// Some non-shared code
Does any of this make sense?
__________________
Desktop machine: 2 x Opteron 246, Asus K8N-DL, 2GB PC3200 ECC Reg., XFX GeForce 6600GT, 74gb WD Raptor, 2 x 19\" LCDs, Windows XP x64
Server machine: Intel P4 3.0GHz 2MB EM64T, ECS i865pe, 1GB PC3200, 36gb WD Raptor, Windows Server 2003
Laptop: Dell Inspiron 9100 (Intel P4 3.2GHz 1MB Prescott, i865pe, 512MB PC3200, Mobility Radeon 9700, DVD+R/DL Burner), Windows XP
Linux: P3 450Mhz, 386MB ram, Slackware 10.1 (Running mySQL/Apache)
TheHeadFL is offline  
Old 02-21-2006, 11:21 AM   #6 (permalink)
office politics's Avatar
 
It's all just 1s and 0s

Join Date: Jan 2004

Location: in the lab

Posts: 4,425

office politics will become famous soon enough

Default

sounds like order of operations for a multitasking system.
office politics is offline  
 
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On