Professional Documents
Culture Documents
Solaris
Introduction to Solaris
OpenSolaris was the Open Source version of the Solaris operating system
which has been discontinued after Oracle took over in 2010.
OS family: Unix
Programmed in : C
Process
Every process has its own unique integer number called Process ID.
On a single processor, multithreading is generally implemented by timedivision multiplexing (as in multitasking): the processor switches between
different threads. This context switching generally happens frequently enough
that the user perceives the threads or tasks as running at the same time.
The main benefit of threads (as compared to multiple processes) is that the
context switches are much cheaper than those required to change current
processes.
Threads also have private resources (program counter, stack, register context,
etc).
Lightweight Processes
A LWP runs in user space on top of a single kernel thread and shares its
address space and system resources with other LWPs within the same process.
Zombie Processes
The correct answer is to fix the buggy parent code that failed to perform the
wait() properly.
Process ID
Parent process ID
User ID
Scheduling class
Priority
Memory used
pldd- Lists the dynamic libraries that are linked into a process
The Solaris kernel is fully preemptible. This means that all threads,
including the threads that support the kernel's own activities, can be
deferred to allow a higher- priority thread to run.
Solaris recognizes 170 different priorities, 0-169, with 169 being the
largest/highest priority. Within these priorities fall a number of
different scheduling classes.
ts_quantum: This is the default length of time assigned to a process with the
specified priority.
ts_tqexp: This is the new priority that is assigned to a process that uses its
entire time quantum.
ts_slpret: The new priority assigned to a process that blocks before using its
entire time quantum.
ts_maxwait: If a thread does not receive CPU time during a time interval of
ts_maxwait, its priority is raised to ts_lwait.
dispadmin can be used to edit the dispatch table to affect the decay of
priority for compute-bound processes or the growth in priority for I/O-bound
processes.
In any case, the dispatch tables should only be altered slightly at each step in
the tuning process, and should only be altered at all if you have a specific
goal in mind.
The following are some of the sorts of changes that can be made:
ts_slpret can cause I/O-bound objects' priorities to rise more or less rapidly.
In FSS, the time quantum is the length of time that a thread is allowed to run
before it has to release the processor. This can be checked using
dispadmin
-c FSS -g
The QUANTUM is reported in ms. (The output of the above command displays
the resolution in the RES parameter. The default is 1000 slices per second.) It
can be adjusted using dispadmin as well.
Thundering Herd
Real time processes also lock all their pages in memory. This can cause
problems on a system that is underconfigured for the amount of memory that
is required.
Since real time processes run at such a high priority, system daemons may
suffer if the real time process does not permit them to run.
When a real time process forks, the new process also inherits real time
privileges. The programmer must take care to prevent unintended
consequences. Loops can also be hard to stop, so the programmer also needs
to make sure that the program does not get caught in an infinite loop.
References
www.docs.oracle.com
www.princton.edu