Operating System

Operating System

An operating system, or OS, is a software program that enables the computer hardware to communicate and operate with the computer software. Without a computer operating system, a computer would be useless. Operating Systems are resource managers. The main resource is computer hardware in the form of processors, storage, input/output devices, communication devices, and data. Some of the operating system functions are: implementing the user interface, sharing hardware among users, allowing users to share data among themselves, preventing users from interfering with one another, scheduling resources among users, facilitating input/output, recovering from errors, accounting for resource usage, facilitating parallel operations, organizing data for secure and rapid access, and handling network communications.

Objectives of Operating Systems
Modern Operating systems generally have following three major goals. Operating systems generally accomplish these goals by running processes in low privilege and providing service calls that invoke the operating system kernel in high-privilege state.
  • To hide details of hardware by creating abstraction
    An abstraction is software that hides lower level details and provides a set of higher-level functions. An operating system transforms the physical world of devices, instructions, memory, and time into virtual world that is the result of abstractions built by the operating system. There are several reasons for abstraction.
    , the code needed to control peripheral devices is not standardized. Operating systems provide subroutines called device drivers that perform operations on behalf of programs for example, input/output operations.
    , the operating system introduces new functions as it abstracts the hardware. For instance, operating system introduces the file abstraction so that programs do not have to deal with disks.
    , the operating system transforms the computer hardware into multiple virtual computers, each belonging to a different program. Each program that is running is called a process. Each process views the hardware through the lens of abstraction.
    , the operating system can enforce security through abstraction.
  • To allocate resources to processes (Manage resources)
    An operating system controls how processes (the active agents) may access resources (passive entities).
  • Provide a pleasant and effective user interface
    The user interacts with the operating systems through the user interface and usually interested in the “look and feel” of the operating system. The most important components of the user interface are the command interpreter, the file system, on-line help, and application integration. The recent trend has been toward increasingly integrated graphical user interfaces that encompass the activities of multiple processes on networks of computers.
One can view Operating Systems from two points of views: Resource manager and Extended machines. Form Resource manager point of view Operating Systems manage the different parts of the system efficiently and from extended machines point of view Operating Systems provide a virtual machine to users that is more convenient to use. The structurally Operating Systems can be design as a monolithic system, a hierarchy of layers, a virtual machine system, an exokernel, or using the client-server model. The basic concepts of Operating Systems are processes, memory management, I/O management, the file systems, and security.

System Components
Even though, not all systems have the same structure many modern operating systems share the same goal of supporting the following types of system components.


Process Management
The operating system manages many kinds of activities ranging from user programs to system programs like printer spooler, name servers, file server etc. Each of these activities is encapsulated in a process. A process includes the complete execution context (code, data, PC, registers, OS resources in use etc.).
It is important to note that a process is not a program. A process is only ONE instant of a program in execution. There are many processes can be running the same program. The five major activities of an operating system in regard to process management are
  • Creation and deletion of user and system processes.
  • Suspension and resumption of processes.
  • A mechanism for process synchronization.
  • A mechanism for process communication.
  • A mechanism for deadlock handling.
 Main-Memory Management
Primary-Memory or Main-Memory is a large array of words or bytes. Each word or byte has its own address. Main-memory provides storage that can be access directly by the CPU. That is to say for a program to be executed, it must in the main memory.
The major activities of an operating in regard to memory-management are:
  • Keep track of which part of memory are currently being used and by whom.
  • Decide which process are loaded into memory when memory space becomes available.
  • Allocate and deallocate memory space as needed.


 File Management
A file is a collected of related information defined by its creator. Computer can store files on the disk (secondary storage), which provide long term storage. Some examples of storage media are magnetic tape, magnetic disk and optical disk. Each of these media has its own properties like speed, capacity, data transfer rate and access methods.
A file systems normally organized into directories to ease their use. These directories may contain files and other directions.
The five main major activities of an operating system in regard to file management are
  1. The creation and deletion of files.
  2. The creation and deletion of directions.
  3. The support of primitives for manipulating files and directions.
  4. The mapping of files onto secondary storage.
  5. The backup of files on stable storage media.
  I/O System Management
I/O subsystem hides the peculiarities of specific hardware devices from the user. Only the device driver knows the peculiarities of the specific device to whom it is assigned.

Secondary-Storage Management
Generally speaking, systems have several levels of storage, including primary storage, secondary storage and cache storage. Instructions and data must be placed in primary storage or cache to be referenced by a running program. Because main memory is too small to accommodate all data and programs, and its data are lost when power is lost, the computer system must provide secondary storage to back up main memory. Secondary storage consists of tapes, disks, and other media designed to hold information that will eventually be accessed in primary storage (primary, secondary, cache) is ordinarily divided into bytes or words consisting of a fixed number of bytes. Each location in storage has an address; the set of all addresses available to a program is called an address space.
The three major activities of an operating system in regard to secondary storage management are:
  1. Managing the free space available on the secondary-storage device.
  2. Allocation of storage space when new files have to be written.
  3. Scheduling the requests for memory access.



A distributed systems is a collection of processors that do not share memory, peripheral devices, or a clock. The processors communicate with one another through communication lines called network. The communication-network design must consider routing and connection strategies, and the problems of contention and security.
 Protection System
If a computer systems has multiple users and allows the concurrent execution of multiple processes, then the various processes must be protected from one another's activities. Protection refers to mechanism for controlling the access of programs, processes, or users to the resources defined by a computer systems.
 Command Interpreter System
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.

Operating Systems Services
Following are the five services provided by an operating systems to the convenience of the users.

Program Execution

The purpose of a computer systems is to allow the user to execute programs. So the operating systems provides an environment where the user can conveniently run programs. The user does not have to worry about the memory allocation or multitasking or anything. These things are taken care of by the operating systems.
Running a program involves the allocating and deallocating memory, CPU scheduling in case of multiprocess. These functions cannot be given to the user-level programs. So user-level programs cannot help the user to run programs independently without the help from operating systems.


I/O Operations

Each program requires an input and produces output. This involves the use of I/O. The operating systems hides the user the details of underlying hardware for the I/O. All the user sees is that the I/O has been performed without any details. So the operating systems by providing I/O makes it convenient for the users to run programs.
For efficiently and protection users cannot control I/O so this service cannot be provided by user-level programs.

File System Manipulation

The output of a program may need to be written into new files or input taken from some files. The operating systems provides this service. The user does not have to worry about secondary storage management. User gives a command for reading or writing to a file and sees his her task accomplished. Thus operating systems makes it easier for user programs to accomplished their task.
This service involves secondary storage management. The speed of I/O that depends on secondary storage management is critical to the speed of many programs and hence I think it is best relegated to the operating systems to manage it than giving individual users the control of it. It is not difficult for the user-level programs to provide these services but for above mentioned reasons it is best if this service s left with operating system.


There are instances where processes need to communicate with each other to exchange information. It may be between processes running on the same computer or running on the different computers. By providing this service the operating system relieves the user of the worry of passing messages between processes. In case where the messages need to be passed to processes on the other computers through a network it can be done by the user programs. The user program may be customized to the specifics of the hardware through which the message transits and provides the service interface to the operating system.


Error Detection

An error is one part of the system may cause malfunctioning of the complete system. To avoid such a situation the operating system constantly monitors the system for detecting the errors. This relieves the user of the worry of errors propagating to various part of the system and causing malfunctioning.
This service cannot allowed to be handled by user programs because it involves monitoring and in cases altering area of memory or de-allocation of memory for a faulty process or may be relinquishing the CPU of a process that goes into an infinite loop. These tasks are too critical to be handed over to the user programs.  A user program if given these privileges can interfere with the correct (normal) operation of the operating systems.

System Calls and System Programs

System calls provide an interface between the process and the operating system. System calls allow user-level processes to request some services from the operating system which process itself is not allowed to do. In handling the trap, the operating system will enter in the kernel mode, where it has access to privileged instructions, and can perform the desired service on the behalf of user-level process. It is because of the critical nature of operations that the operating system itself does them every time they are needed. For example, for I/O a process involves a system call telling the operating system to read or write particular area and this request is satisfied by the operating system.
System programs provide basic functioning to users so that they do not need to write their own environment for program development (editors, compilers) and program execution (shells). In some sense, they are bundles of useful system calls.

Types of Operating Systems
An operating system is a software component of a computer system that is responsible for the management of various activities of the computer and the sharing of computer resources. It hosts several applications that run on a computer and handles the operations of computer hardware. Users and application programs access the services offered by the operating systems, by means of system calls and application programming interfaces. Users interact with a computer operating system through Command Line Interfaces (CLIs) or Graphical User Interfaces known as GUIs. In short, an operating system enables user interaction with computer systems by acting as an interface between users or application programs and the computer hardware. Here is an overview of the different types of operating systems.

Real-time Operating System: Real-time systems are usually used to control complex systems that require a lot of processing like machinery and industrial systems. It is a multitasking operating system that aims at executing real-time applications. Real-time operating systems often use specialized scheduling algorithms so that they can achieve a deterministic nature of behavior. The main object of real-time operating systems is their quick and predictable response to events. They either have an event-driven or a time-sharing design. An event-driven system switches between tasks based of their priorities while time-sharing operating systems switch tasks based on clock interrupts.

Multi-user and Single-user Operating Systems: Computer operating systems of this type allow multiple users to access a computer system simultaneously. Time-sharing systems can be classified as multi-user systems as they enable a multiple user access to a computer through time sharing. Single-user operating systems, as opposed to a multi-user operating system, are usable by only one user at a time. Being able to have multiple accounts on a Windows operating system does not make it a multi-user system. Rather, only the network administrator is the real user. But for a Unix-like operating system, it is possible for two users to login at a time and this capability of the OS makes it a multi-user operating system. This type of operating system is seen everywhere today and is the most common type of OS, the Windows operating system would be an example.

Multi-tasking and Single-tasking Operating Systems: When a single program is allowed to run at a time, the system is grouped under the single-tasking system category, while in case the operating system allows for execution of multiple tasks at a time, it is classified as a multi-tasking operating system. Multi-tasking can be of two types namely, pre-emptive or co-operative. In pre-emptive multitasking, the operating system slices the CPU time and dedicates one slot to each of the programs. Unix-like operating systems such as Solaris and Linux support pre-emptive multitasking. If you are aware of the multi-threading terminology, you can consider this type of multi-tasking as similar to interleaved multi-threading. Cooperative multitasking is achieved by relying on each process to give time to the other processes in a defined manner. This kind of multi-tasking is similar to the idea of block multi-threading in which one thread runs till it is blocked by some other event. MS Windows prior to Windows 95 used to support cooperative multitasking.

Distributed Operating System:  In a distributed system, software and data maybe distributed around the system, programs and files maybe stored on different storage devices which are located in different geographical locations and maybe accessed from different computer terminals. The development of networked computers that could be linked and made to communicate with each other, gave rise to distributed computing. Distributed computations are carried out on more than one machine. When computers in a group work in cooperation, they make a distributed system.

Embedded System: The operating systems designed for being used in embedded computer systems are known as embedded operating systems. They are designed to operate on small machines like PDAs with less autonomy. They are able to operate with a limited number of resources. They are very compact and extremely efficient by design. Windows CE, FreeBSD ect. are some examples of embedded operating systems.

Mobile Operating System: Though not a functionally distinct kind of operating system, mobile OS is definitely an important mention in the list of operating system types. A mobile OS controls a mobile device and its design supports wireless communication and mobile applications. It has built-in support for mobile multimedia formats. Tablet PCs and smart-phones run on mobile operating systems.

Batch Processing and Interactive Systems: Batch processing refers to execution of computer programs in 'batches' without manual intervention. In batch processing systems, programs are collected, grouped and processed on a later date. There is no prompting the user for inputs as input data are collected in advance for future processing. Input data are collected and processed in batches, hence the name batch processing. IBM's z/OS has batch processing capabilities. As against this, interactive operating requires user intervention. The process cannot be executed in the user's absence.

Online and Offline Processing: In online processing of data, the user remains in contact with the computer and processes are executed under control of the computer's central processing unit. When processes are not executed under direct control of the CPU, the processing is referred to as offline. Let's take the example of batch processing. Here, the batching or grouping of data can be done without user and CPU intervention; it can be done offline. But the actual process execution may happen under direct control of the processor, that is online.

Operating systems contribute to simplifying human interaction with the computer hardware. They are responsible for linking application programs with the hardware, thus achieving easy user access to computers. Ever imagined a computer without an OS? It wouldn't be so user-friendly then!

Operating System Based on User Interface
Every computer that is to be operated by an individual requires a user interface. The user interface is not actually a part of the operating system—it generally runs in a separate program usually referred to as a shell, but is essential if human interaction is to be supported. The user interface requests services from the operating system that will acquire data from input hardware devices, such as a keyboard, mouse or credit card reader, and requests operating system services to display prompts, status messages and such on output hardware devices, such as a video monitor or printer.
The two most common forms of a user interface have historically been the command-line interface, where computer commands are typed out line-by-line, and the graphical user interface, where a visual environment is present.
i) Command-line interface
A command-line interface (CLI) is a mechanism for interacting with a computer operating system or software by typing commands to perform specific tasks. This text-only interface contrasts with the use of a mouse pointer with a graphical user interface (GUI) to click on options, or menus on a text user interface (TUI) to select options. This method of instructing a computer to perform a given task is referred to as "entering" a command: the system waits for the user to conclude the submitting of the text command by pressing the "Enter" key (a descendant of the "carriage return" key of a typewriter keyboard). A command-line interpreter then receives, parses, and executes the requested user command.
Upon completion, the command usually returns output to the user in the form of text lines on the CLI. This output may be an answer if the command was a question, or otherwise a summary of the operation.

i) Graphical user interface

A graphical user interface (GUI) is a type of user interface that allows users to interact with electronic devices with images rather than text commands. GUIs can be used in computers, hand-held devices such as MP3 players, portable media players or gaming devices, household appliances and office equipment. A GUI represents the information and actions available to a user through graphical icons and visual indicators such as secondary notation, as opposed to text-based interfaces, typed command labels or text navigation. The actions are usually performed through direct manipulation of the graphical elements.

Disk Operating System (DOS)

Disk Operating System (DOS) is an Operating System. It is a command-line interface (CLI) mechanism for interacting with a computer operating system or software by typing commands to perform specific tasks. It works as an interpreter between user and computer. We give English like commands and it converts it into machine language and after the computer has processed the information, returns the results to you in English.

There are two name in DOS and is divided into 2 parts.
1. Primary: File Name
2. Secondary: File extension.
File Name is separated from the File extension with the help of a dot (.)
File Name can be from 1 to 8 characters long and
File extension contains 3 characters and is optional. The extension tells DOS about what kind of file it is.
A valid Character for naming a file: from A to Z and the digit 0 to 9
C :\> Is known as DOS/command prompt, where we give the commands.
DOS command divided into 2 parts.
1. Internal Commands or Memory-Resident Commands
2. External Command or Disk-Residence Commands

There are also called memory-resident commands. These commands are automatically loaded into the computer’s memory during the booting process. They actually included in the Command.com file. So these commands are executable immediately after getting the dos prompt.
1. VER: - All O/S has its own edition number or release or version number. The version
number indicates which edition of O/S you are working on.
Syntax: VER <Enter>
Example: C:\> Ver <Enter>
Result will be: - Microsoft Windows XP [ Version 5.1.2600]
02. VOL: - It is used to display volume label and serial number of the current drive
Syntax: Vol [drive:]
Example: C:\> VOL
3. DATE: - Used to display the current system date and prompt for entering new date.
Syntax: Date <Enter>
Example: C:\> date <Enter>
4. TIME: - Displays the current system Time and prompt for entering new time.
Syntax: Time <Enter>
Example: C:\> Time <Enter>
5. CLS: - Clears the cluster screen.
Syntax: CLS <Enter>
Example: C:\> CLS <Enter>
6. DIR: - This command displays the list of directories and files with details like date of
creation whether it is directory or file etc.
Syntax: DIR <Enter>
/p : To view one screen of files at a time.
/w : Displays only five column of filenames and directories.
/b : Display only file and directory.
/l : Display all the information in lower case letters.
/a — stands for attributes that are given below.
/-h - Hidden ( or not hidden) files
s/-s - System ( or not systems) files
d/-d - Directory ( or not Directory) names
r/-r - Read only( or not read only) files
DIR *.txt : Display all the files with extension .txt
DIR D???.* : Display all the files starting with D and having less than or equal to
four characters in the file name and any extension.
Here “?” And “*” are called “wild card character”.
“*” Stand for any number of the character
“?” Stands for nay one character.
07. MD OR MKDIR: -Used to create a new Directory or nested Directories.
Example: C:\> MD SAMS <Enter>
08. CD OR CHDIR: - This command allows you to change present directory to another
Syntax: CD [DRIVE:] PATH
Example: C:\> CD SAMS and press <Enter>
09. PATH: - This command defines a list of directories DOS Searches for external
Syntax: PATH (Display the current Search Path)
PATH; : - ( Clear the search path so DOS will search for external commands only in the
current directory)
10. RD: - To delete the empty directory.
Syntax: RD [DRIVE:] PATH
NOTE: -The directory must be empty when we use RD.
Example: C:\> RD SAMS and press <Enter>
Switches: - 1. /s – Remove with subdirectories and files.
2. /q – Don’t ask to confirm.
11. COPY CON: -We use this command to create a new file.
Example: C:\> Copy Con sams.txt <Enter>
Note: - Typing here and when you are done, press Ctr+Z or F6 key followed by Enter to
save the current document.
12. TYPE: - This command allows you to see the contents of an existing file on the
SYNTAX: TYPE <file name>
Example: C:\> TYPE SAMS
13. COPY: - Using this command you can make duplicate files of an exiting file from one
location to another or one directory to another with different name or exiting name.
Example: C:\> COPY SAMS.TXT A:\TAJ
Example: C:\> COPY*.TXT +*.BAK TARGET FILENAME And Then Press Enter
Example: C:\> COPY SAMS.TXT C:\SAMS_1\FO\RECEPTION And Then Press Enter
You can also have the option to change the name of files as you copy it.
Example: C:\> COPYold.TXT C:\dos\new.txt And Then Press Enter
14. DEL/ERASE: This command removes one or more files from the disk or current
working directories.
SYNTAX: DEL filespec [/p] or ERASE filespec [/p]
Example: C:\> DEL C:*.BAK /P And Then Press Enter
Example: C:\> DEL abc And Then Press Enter
Example: C:\> DEL ????.COM And Then Press Enter
Switches: - 1. /p –confirmation 2. /q – In quit mode
15. REN: Used to change the name of the file or directory.
SYNTAX: REN <file name>
Example: REN sams sams1 <Enter>
Example: REN *.dat *.mst And Then Press Enter
16 PROMPT: This command allows you to customize the dos prompt.


17. TREE: - It is used to display directory structure of a specified directory graphically.
Syntax : TREE [drive:] [path] [/f]
[/F] : displays the names of the files in each directory.

External Command or Disk-Residence Commands
These are also called Disk-Resident Commands. These commands are meant for special purpose. These are found in separate files on Hard Disk or Floppy Disk, So that they don’t typically consume valuable memory space. They are loaded into memory only when called.
Some External Command are:
1. XCOPY: This command is faster than Copy Command and allows you to copy entire directories/disk including all the sub directories and files to destination.
Syntax: XCOPY Source [ Target][/Y][-Y] [/P][/E]
/-Y : Prompts before copying over existing files.
/y : Overwrites existing files without prompting.
/p : Ask before copying each file.
/e : Copying empty directory also.
/s : Copying subfolders.
2. MOVE : This command moves a file or group of files from one directory to another and also one disk to another disk. It can also be used to rename directories.
SYNTAX: Move [Path File Name] [Destination file name path]
/-Y : Prompt before it overwrites while it copies file that already exists.
/Y : Overwrites existing files without prompting.
EXAMPLE: move c:\sams\fo.txt to d:
EXAMPLE: move c:\sams\fo.txt to d:\ new_sams
4. FC: Stands for File Compare. If you wish to compare two files or two sets of files then you may use this command. This command has the capability to differentiate between the files and display the difference
SYNTAX: FC <files spec 1> <files spec2> [/a][/b][/c][l][/n]
/a : This switch displays only the first and last line of each group.
/b : Compare the files in library mode ( byte-by-byte)
/c : Ignore the case of letters.
/l : Compare the files in text mode.
/n : Displays the line number for lines that are different.
EXAMPLE: FC first.txt second.txt\n and then Press <enter>
5. DOSKEY: Dos can remember only the last command you had entered. But in order to make DOS remember all the commands you enter you will have to load a DOSKEY utility. Also Used To Create Macros
Syntax: DOSKEY and Press <Enter>
Display message on the screen.
DOSKEY Installed.
NOTE: - To display all commands from the history list one the screen.
Example: DOSKEY / History or /h < Enter>.
Now when DOSKEY is in memory, it can help store all the commands which you enter so that any of those commands need not be typed again to be executed. And this all are called HISTORY LIST. Now when you want the same command to be done you can use right arrow key or ‘F1’ or ‘F3’ Issuing following command.
Second feature of DOSKEY is Doskey Macro. Using this macro you can create own command and latter you can run it on the system prompt. For example
Now if you type at the system prompt only C and press enter it will clear the screen.
Recalling Commands: Some key is provided to recall recent commands you have run
since installing DOSKEY.
Key Strok Effect
Up Arrow Display the Preceding Command and further list.
Down Arrow Show the next command you executed after the one that’s being
Page Up Display the oldest command that is still in Doskey.
Page Down Show the most recent command that you executed
F7 Display the entire list of command that you executedd.
F9 Selects a commands
Alt+F7 Erase the command history list.
Alt+F10 Erase all macros in memory
Esc Clear the command line.
Ctrl-T Command separator
6. MEM:
This command displays amount of total available memory ( low, Expanded and
Extended) and all currently programs.
Syntax: MEM [/f][/p][/m]
/f : Using this switch MEM display all the areas of memory that are fee.
/p : Use this option to display the information one screen at a time.
/m : Display information about how a specified program is using memory.
Example: MEM/p and then press <Enter>
A Powerful feature of DOS is its use of filters to process data directly. A DOS FILTER
can process in unique way any data that passes through it and can change what we see
on the screen.
There are three FILTERS include in DOS.
A. MORE: More command used to pause vertical Scrolling on the display screen,
after each screenful, The display pauses and the message - - More - - appears.
Pressing any key display the next screen.
EXAMPLE: C:\> MORE < TYPE FILE.TXT and then press <Enter>
EXAMPLE: C:\> DIR /MORE and then press <Enter>
B. SORT: Reads, Sorts in Order and sends the data to the screen, file or to another
device. Sort to arrange data in an order.
SYNTAX: SORT [drive:][Path][filename][/r][+n]
[drive:][Path][filename] : Specifies the name and location of the file to be
searches. It must be preceded
by the redirection character (<).
[/r] : Sort lines in reverse ASCII Order ( Z-A)
[+n] : Sorts line starting with the contents in column n. The default is 1.
EXAMPLE: C:\> SORT < NAME .TXT and then press <Enter>
EXAMPLE: C:\> SORT /+20 < PHONE .TXT and then press <Enter>
EXAMPLE: C:\> DIR / SORT > PHONE .TXT and then press <Enter>
Note: Sort command doesn’t distinguish between upper and lower case. It can sort file
of maximum 63 k size.
Combining Input & Output redirection :
EXAMPLE: C:\> SORT < NAME .DAT > SORTNAME.DAT and then press
Here the sort command is being directed to take its input from <name.dat and after
sorting, send its output to the > sortname.dat file.
C. FIND: The find Filter is used to search a file one or more designated character (called
a text string) Depending upon the form of the FIND Command. Each line having (or not
having) the text string is sent to an output devices. Such as the Screen, a file or the
printer. The text string is always typed within quotes ( “Text Sring”).
SYNTAX: FIND [/v][/c][/n] “String “ [d:] [path][filename]
[/v] : Displays all the lines that do not contain string.
[/c] : Display the total number of lines found to contain the string.
[/n] : Display the line number as well as the line that contains the string.
[/i] : Ignores uppercase or lowercase during the search.
“String” : Specifies one or more alphabet or numeric character whose maximum
length should not be more than 250 characters and must be enclosed in double quotes.
[d:] [path][filename] : Specifies the name and location of the file to be searches .
EXAMPLE: C:\> FIND “Rajni” my.txt per.txt and then press <Enter>
EXAMPLE: C:\> DIR/ FIND “TXT” and then press <Enter>
Every File on the Disk has its own description like size, space occupied, the type, the
date it was created, etc. Likewise, every file has few attributes. The attributes of a file
indicates whether it is a
i) Read-Only File: r ii) Archive File a
iii) Hidden File: h iv) System File s
With the ATTRIB command you can check the attributes of a file.
SYNTAX: ATTRIB [+r][+a][+h][/+s] [filename]
+r, -r : +r Read-Only attribute or, -r turn of Read-Only attribute
+a,-a : +a archive attribute, or -a turn of archive attribute
+h,-h : +h hidden attribute, or –h turn of hidden attribute
+s, -s : +s system attribute and it should not be used generally.
While Creating a new file every file gets read only attribute and archive attribute by
EXAMPLE: C:\> ATTRIB my.txt +R and then press <Enter>
EXAMPLE: C:\> ATTRIB my.txt +H and then press <Enter>
This command used for deleting an entire directory whether in that directory contains
files or subdirectories and also it will delete hidden files.
Syntax: DELTREE [drive:][path] directories [/y]
EXAMPLE: C:\> DELTREE my.txt and then press <Enter>
9. EDIT:
This is the DOS Editor, which you can use to edit the text file and also creating new file.
Syntax: Edit [drive:][path][filename]
EXAMPLE: C:\> EDIT c:\sams\FO.TXT and then press <Enter>
EXAMPLE: C:\> Edit NEW FILE and then press <Enter>

System Files: Config.sys, IO.sys, MSDOS. sys, autoexec.bat

IO.SYS: A hidden file in the root directory of the primary drive. This file provides the basic I/O capabilities for the system, allowing it the ability to communicate with the different peripherals. IO.SYS directs the overall process of loading the Operating System.
MSDOS.SYS: MSDOS.SYS an important system file on MS-DOS and Windows 9x systems. It is run after IO.SYS. In MS-DOS, it contains the core operating system code, the kernel. On Windows 9x systems, the DOS kernel code is merged into IO.SYS, and MSDOS.SYS is an ASCII file containing configuration directives.
By default, the file is located in the root directory of the bootable drive/partition (normally C:\) and has the hidden, read-only, and system file attributes set. When an application needs to access a device or peripheral, this file translates the request into actions that IO.SYS can perform.
CONFIG.SYS: A user-configurable text file that usually contains device drivers and system setup values. CONFIG.SYS is the primary configuration file for the DOS operating systems. It is a special file that contains setup or configuration instructions for the computer system.
device=c:\dos\emm386.exe ram
shell=c:\dos\command.com c:\dos /e:512 /p
  • The first line loads the HIMEM.SYS driver that enables DOS to use the high memory area.
  • The second line loads the EMM386 memory manager, which emulates expanded memory. The command line argument RAM allows the use of the upper memory area. Another argument that can be given to emm386.exe is NOEMS, which allows use of the upper memory area without emulating expanded memory. The NOEMS switch also frees up more umb blocks.
  • The third line causes DOS to use high memory and upper memory when possible, freeing up more conventional memory for applications to use.
  • The final line sets the shell to the default shell, COMMAND.COM, and starts it with C:\DOS as the working directory, with an environment size of 512 bytes, and the /P indicates that it is the primary process and therefore cannot be shut down by using the exit command.

COMMAND.COM: This is the Command Interpreter. It can accept commands from the user, launch programs and pass this Information to MSDOS.SYS. COMMAND.COM is the filename of the default operating system shell for DOS operating systems and the default command line interpreter on Windows 95, Windows 98 and Windows Me. It has an additional role as the first program run after boot, hence being responsible for setting up the system by running the AUTOEXEC.BAT configuration file, and being the ancestor of all processes.
AUTOEXEC.BAT: Another user-configurable text file that is used to set system variables and load TSRs (Terminate and Stay Resident). AUTOEXEC.BAT is a system file found originally on DOS-type operating systems. It is a plain-text batch file that is located in the root directory of the boot device. The name of the file stands for "automatic execution", which describes its function in automatically executing commands on system startup

Windows Operating System

An enclosed, rectangular area on a display screen. Most modern operating systems and applications have graphical user interfaces (GUIs) that divide display into several windows. Within each window, we can run a different program or display different data.
Windows are particularly valuable in multitasking environments, which allow execute several programs at once. By dividing display into windows, we can see the output from all the programs at the same time. To enter input into a program, we simply click on the desired window to make it the foreground process.

Introduction to GUI and its features
A graphical user interface (GUI) is a pictorial interface to a program. A good GUI can make programs easier to use by providing them with a consistent appearance and with intuitive controls like pushbuttons, list boxes, sliders, menus, and so forth. The GUI should behave in an understandable and predictable manner, so that a user knows what to expect when he or she performs an action. For example, when a mouse click occurs on a pushbutton, the GUI should initiate the action described on the label of the button.
GUIs, such as the one supported by the Apple Macintosh or Windows, enable to set the dimensions and position of each window by moving the mouse and clicking appropriate buttons. Windows can be arranged so that they do not overlap (tiled windows) or so they do overlap (overlaid windows). Overlaid windows (also called cascading windows) resemble a stack of pieces of paper lying on top of one another; only the topmost window is displayed in full. We can move a window to the top of the stack by positioning the pointer in the portion of the window that is visible and clicking the mouse buttons. This is known as popping. We can expand a window to fill the entire screen by selecting the window's zoom box.
In addition to moving windows, changing their size, popping and zooming them, we can also replace an entire window with an icon (this is sometimes called minimizing). An icon is a small picture that represents the program running in the window. By converting a window into an icon, we can free up space on the display screen without erasing the window entirely. It is always possible to reconvert the icon into a window whenever we want.
 A window can also be a logical view of a file. By moving the window, we can view different portions of the file.

World most known Windows Operating system is a Microsoft Windows or MS-Windows. Microsoft Windows is a series of operating systems produced by Microsoft. Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces (GUIs). Microsoft Windows came to dominate the world's personal computer market, overtaking Mac OS, which had been introduced in 1984.

Working with a Window Environment

A menubar provides the facility to launch programs via a menu and may contain additional facilities including a start button, a taskbar, and a system tray.

Title Bars
A titlebar is a window decoration component provided by some window managers which appears at the top of each window. The titlebar is typically used to display the name of the application, or the name of the open document, and may provide title bar buttons for minimizing, maximizing, closing or rolling up of application windows.
Title Bar Buttons
Title bar buttons are included in the titlebar of some window managers, and provide the facility to minimize, maximize, rollup or close application windows. Some window managers may display the titlebar buttons in the taskbar or task panel, rather than in a titlebar.
An autohide facility enables menubars to disappear when the pointer is moved away from the edge of the screen.
A border is a window decoration component provided by some window managers, that appears around the active window. Some window managers may also display a border around background windows.
Context Menu
Some window managers provide a context menu that appears when an alternative click event is applied to a desktop component.
Desktop Wallpaper
Some window managers provide a desktop wallpaper facility that enables a background picture to be displayed in the root window.
Focus Stealing
Focus stealing is a facility provided by some window managers that allows an application that is not in focus to suddenly gain focus and steal user input intended for the previously focused application.
An iconification facility enables running applications to be minimized to a desktop icon or taskpanel icon.
Joined Windows
Some window managers provide a joined windows facility that enables application window frames to be joined together.
Keyboard Equivalents
Some window managers provide keyboard equivalents that enables functionality provided by the mouse to be replicated by using a keyboard.
Menu Panel
A menu panel a component of some window managers that provides the facility to launch programs using a menu. A menu panel is similar to a menubar, but appears as a floating panel, rather than a horizontal or vertical bar.
The menu panel may contain additional facilities including a start button, a task panel, and a system tray.
Mouse focus
The mouse focus model determines how the pointing device affects the input focus within the window manager. The focus model determines which component of the graphical user interface is currently selected to receive input as the pointer is moved around the screen.
Mouse warping
Mouse warping is a facility that centers the pointer on the current application as it is made active.
Multiple Desktops
A window manager may provide a multiple desktops facility. This enables several root windows to be used, and a facility to switch between desktops. This prevents clutter of the root window, because applications can be run on different desktops.
Some window managers provide a pager tool that provides the facility to switch between multiple desktops. The pager may appear as an onscreen window or as a gadget in the taskbar or taskpanel.
Some window managers have a modular construction, enabling plug-in modules to be used to provide features as required.

A rollup facility enables windows to appear as just a titlebar on the desktop.
Root Menu
Some window managers provide a root menu, which appears when the root window or desktop background is touched.
Some window managers provide a shortcut facility, which enables icons to be placed on the root window, which can be used to access specific programs or facilities.
Tabbed Windows
Some window managers provide a tabbed windows facility, that enables applications to be grouped together to share common frames.
Task Switching
The window manager may provide various task switching facilities, to enable selection of the currently focused application, including:
Changing the mouse focus using a pointing device
Keyboard task switching facilities (for example, by pressing Alt-Tab)
Clicking on the task in a taskbar or taskpanel
Some window managers provide a taskbar which shows running applications. The taskbar may show all applications that are running including those that have been minimized, and may provide the facility to switch focus between them. The taskbar may be incorporated into a menubar on some window managers.
Task Panel
A task panel is similar to a taskbar, but appears as a floating panel, rather than a horizontal or vertical bar.
Start Button
A start button is a desktop widget that provides a menu of programs that can be launched. The start button is typically placed on a menubar at the bottom of the screen.
Notification Area
A Notification Area is used to display icons for system and program features that have no desktop window. It contains mainly icons to indicate status information and notifications such as arrival of a new mail message. Some systems may also show a clock in the Notification Area.
Virtual Desktop
A virtual desktop (also called a scrolling desktop) is a facility provided by some window managers that enables the desktop to be larger than the actual screen

Concept of Open Sources Operating System

The term "open source software" refers primarily to a set of terms and conditions associated with the software's license. The term "open source" derives from the fact that the software's source code is at least available and in fact ususally distributed with the executable code (the normal way of distributing software). Per one of the typical terms and conditions in an OSI-compliant license, the software can be (1.) "freely" changed and (2.) somewhat freely redistributed (depending on which open source license is used).
There are a variety of open source software foundations that are more independent than the norm from the companies that use their project code for revenue generation. However even these foundations are heavily funded by technology companies (e.g., Apache Software Foundation by all the major market participants including Microsoft, Mozilla by Google, the Linux Foundation by IBM and HP, and so forth) There are a variety of open source software foundations that are more independent than the norm from the companies that use their project code for revenue generation. However even these foundations are heavily funded by technology companies (e.g., Apache Software Foundation by all the major market participants including Microsoft, Mozilla by Google, the Linux Foundation by IBM and HP, and so forth)

Open Source Platforms(OS)
The most well-known open source OS is Linux, a UNIX operating system derivative named after its creator, Linus Torvalds. The Linux Foundation, where Linus works, is more or less "in charge of" the operating system kernel. (Of course under open source development philosophy, anyone can take it and fork it into something else but Linus owns the name Linux.) The Linux kernel is turned into a platform by adding a wide range of utility software, primarily developed under the banner of the GNU organization.
How do companies profit from open source?
A number of companies have been built around a so-called open source business model, where they license their software for free or very inexpensively, but derive their revenues from support and training services. This model is really no different than most other long-time software companies which almost always sell subscription maintenance service after selling the initial right to use license. In fact, most long-time participants in the software market realize well more than half of their software-related revenue from this source.
Many companies following the so-called open source business model adopt a tiered approach to their product offerings, releasing a completely free community edition of their software, and then charging a license fee for their enterprise edition, which is often based on their community edition but includes additional features or is more highly scalable. Again, this marketing tactic is not different from many publishers of closed-source software.

Introduction to UNIX, Linux

UNIX Operating System Concept
UNIX is a powerful computer operating system originally developed at AT&T Bell Laboratories. It is very popular among the scientific, engineering, and academic communities due to its multi-user and multi-tasking environment, flexibility and portability, electronic mail and networking capabilities, and the numerous programming, text processing and scientific utilities available. It has also gained widespread acceptance in government and business. Over the years, two major forms (with several vendor’s variants of each) of UNIX have evolved: AT&T UNIX System V and the University of California at Berkeley’s Berkeley Software Distribution (BSD). This document will be based on the SunOS 4.1.3_U1, Sun’s combination of BSD UNIX (BSD versions 4.2 and 4.3) and System V because it is the primary version of UNIX available at Rice. Also available are Solaris, a System Vbased version, and IRIX, used by Silicon Graphics machines.

Types of UNIX
 There are many different versions of UNIX, although they share common similarities. The most popular varieties of UNIX are Sun Solaris, GNU/Linux, and MacOS X.

UNIX Components
Unix is made up of three components
  1. the kernel;
  2. the shell; and
  3. Applications.

The kernel
The kernel is the main component of most computer operating systems; it is a bridge between applications and the actual data processing done at the hardware level. The kernel's responsibilities include managing the system's resources (the communication between hardware and software components).[1] Usually as a basic component of an operating system, a kernel can provide the lowest-level abstraction layer for the resources (especially processors and I/O devices) that application software must control to perform its function. It typically makes these facilities available to application processes through inter-process communication mechanisms and system calls.
Operating system tasks are done differently by different kernels, depending on their design and implementation. While monolithic kernels execute all the operating system code in the same address space to increase the performance of the system, micro kernels run most of the operating system services in user space as servers, aiming to improve maintainability and modularity of the operating system.[2] A range of possibilities exists between these two extremes.
The kernel of Unix is the heart of the operating system. It allocates time and memory to programs and handles the filestructure and communication between the different parts of the computer system such as the keyboard and the screen.

The shell
Interact with the system through a command interpreter program called the shell. The shell is an interface between the user and the Unix kernel. When a user logs in Unix checks the username and password, and then starts another program called the shell. The shell interprets the commands the user types and transmits them to the kernel to be executed. These commands are programs.
There are a variety of shells available for the various Unix systems. The expert user can customize their own shell and users can use different shells on the same machine.
Variety of shells:
  • sh - the bourne shell
  • bash - the bourne again shell
  • csh - the c shell
  • ksh - the Korn shell (strangely, not named for the band)
  • zsh - the z shell

Application programs
Programs are not part of the operating system as such.

Linux Operating System Concept

Linux is a free open-source operating system based on UNIX. Linus Torvalds originally created Linux with the assistance of developers from around the world.
  • Free
  • Unix Like
  • Open Source
  • Network operating system
  • Strictly speaking, Linux is a kernel. A kernel provides access to the computer hardware and controls access to resources. The kernel decides who will use a resource, for how long and when. You can download the Linux kernel from the official web site. However, the Linux kernel itself is useless unless you get all the applications such as text editors, email clients, browsers, office applications, etc. Therefore, someone came up with idea of a Linux distribution. A typical Linux distribution includes:
  • Linux kernel
  • GNU application utilities such as text editors, browsers
  • GUI (X windows)
  • Office application software
  • Software development tools and compilers
  • Thousands of ready to use application software packages
  • Linux Installation programs/scripts
  • Linux post installation management tools daily work such as adding users, installing applications, etc

Who created Linux?
In 1991 Linus Torvalds was studying UNIX at a university, where he was using a special educational experimental purpose operating system called Minix (a small version of UNIX to be used in the academic environment). However, Minix had its limitations and Linus felt he could create something better. Therefore, he developed his own version of Minix, known as Linux. Linux was Open Source right from the start.
Linux is kernel developed by Linus. The kernel was bundled with system utilities and libraries from the GNU project to create a usable operating system. Sometime people refer Linux as GNU/Linux because it has system utilities and libraries from the GNU project. Linus Torvalds is credited for creating the Linux Kernel, not the entire Linux operating system.
Linux distribution = Linux kernel + GNU system utilities and libraries + Installation scripts + Management utilities etc.
Please note that Linux is now packaged for different uses in Linux distributions, which contain the sometimes modified kernel along with a variety of other software packages tailored to different requirements such as:
·         Server
·         Desktop
·         Workstation
·         Routers
·         Various embedded devices
·         Mobile phones etc


Computer science, Number Systems, Boolean Algebra,QBASIC, C tutorial, SQL Tutorial, HTML 5 tutorial

Follow by Email