Operating system lab programs source code




















Laboratory Assignments. Process control system calls: The demonstration of fork, execve and wait system calls along with zombie and orphan states. Implement the C program in which main program accepts the integers to be sorted. Main program uses the fork system call to create a new process called a child process. Parent process sorts the integers using merge sort and waits for child process using wait system call to sort the integers using quick sort.

Also demonstrate zombie and orphan states. Implement the C program in which main program accepts an integer array. Parent process sorts an integer array and passes the sorted array to child process through the command line arguments of execve system call. The child process uses execve system call to load new program that uses this sorted array for performing the binary search to search the particular item in the array. Thread management using pthread library.

Implement matrix multiplication using multithreading. Final sum of row-column multiplication must be done by main thread main function. Thread synchronization using counting semaphores and mutual exclusion using mutex.

Deadlock Avoidance Using Semaphores:. Inter process communication in Linux using following. Pipes : Full duplex communication between parent and child processes. Parent process writes a pathname of a file the contents of the file are desired on one pipe to be read by child process and child process writes the contents of the file on second pipe to be read by parent process and displays on standard output. FIFOs: Full duplex communication between two independent processes. First process accepts sentences and writes on one pipe to be read by second process and second process counts number of characters, number of words and number of lines in accepted sentences, writes this output in a text file and writes the contents of the file on second pipe to be read by first process and displays on standard output.

Signals : Detecting the termination of multiple child processes :. A parent process Creates multiple child process minimum three child processes.

Parent process should be Sleeping until it creates the number of child processes. Child processes send SIGCHLD signal to parent process to interrupt from the sleep and force the parent to call wait for the Collection of status of terminated child processes. Linux Kernel configuration, compilation and rebooting from the newly compiled kernel.

Get a Linux kernel source code from www. Creating a monolithic compressed image of a kernel. Compilation of kernel modules. Installation of kernel modules. Finalize installation. Kernel space programming: Implement and add a loadable kernel module to Linux kernel, demonstrate using insmod, lsmod and rmmod commands. A sample kernel space program should print the "Hello World" while loading the kernel module and "Goodbye World" while unloading the kernel module.

Implement a new system call, add this new system call in the Linux kernel any kernel source, any architecture and any Linux kernel distribution and demonstrate the use of same.

Implementing a memory management policy in a Linux OS. Implementing a file system in a Linux OS. Links for Laboratory Assignments:. Contact: Tushar B Kute tushar tusharkute. Operating System. Search web. Laboratory Assignments Process control system calls: The demonstration of fork, execve and wait system calls along with zombie and orphan states.

Requirements: a. Related Articles. Table of Contents. Improve Article. Save Article. Like Article. According to Computer Hierarchy, one which comes at last is Hardware. Program Development and Execution can be done conveniently in System Programs. Some of the System Programs are simply user interfaces, others are complex. It traditionally lies between the user interface and system calls. System Programs can be divided into these categories : File Management — A file is a collection of specific information stored in the memory of a computer system.

File management is defined as the process of manipulating files in the computer system, its management includes the process of creating, modifying and deleting files.

It helps to create new files in the computer system and placing them at specific locations. It helps in easily and quickly locating these files in the computer system. It makes the process of sharing files among different users very easy and user-friendly. It helps to store files in separate folders known as directories. These directories help users to search files quickly or to manage files according to their types of uses.

It helps users to modify the data of files or to modify the name of files in directories. Status Information — Information like date, time amount of available memory, or disk space is asked by some users. Others providing detailed performance, logging, and debugging information which is more complex. All this information is formatted and displayed on output devices or printed.

Terminal or other output devices or files or a window of GUI is used for showing the output of programs. File Modification — For modifying the contents of files we use this. For Files stored on disks or other storage devices, we used different types of editors.

For searching contents of files or perform transformations of files we use special commands. Programming-Language support — For common programming languages, we use Compilers, Assemblers, Debuggers, and interpreters which are already provided to users.



0コメント

  • 1000 / 1000