728x90

Operating System/System Programming(Arif Butt) 30

Lec33) Overview of TCP/IP Architecture and Service

Application Layer Consist of process that use the NW(Network) Porvides progamming interface used for building a program Protocols used are http, telnet, ftp, smtp, ssh Addresses are string based URIs (URL, URN) Transport Layer Provides host to host communication Protocols used are TCP ,UDP , RAW 16 bits Port numbers are used for addressing Internet Layer Break data into fragments small enough fo..

Lec29, 30) Programming With Shared Memory , Memory Mapped Files

Shared Memory allows 2 or more processes to share a memory region or segment of memory for reading and writing purposes the problem with pipes, fifo and message queue is that mode switches are involved as the data has to apss from one process buffer to the kernel buffer and then to another process buffer since access to user-space memory does not require a mode switch , thereofre , shared memory..

Lec26,27) Programming UNIX Pipes and Named Pipes

pipe system call Creating pipe is similar to opening 2 files. A successful call to pipe() returns 2 open file descriptors in the array fd. one contains the read descriptor of the pipe, fd[0] , and the other contains the write descriptor fo the pipe fd[1]. if pipe(fd) fails it returns -1. to make parent process writer and child process reader we close fd[0] from parent process and close fd[1] for..

Lec25) Design and Code Of Signal Handlers

kill system call int kill(pid_t pid, int sig); if sig is zero than normal error checking is performed but no signal is sent. Used to determine if a specified process still exists. if it doesn't exist, a -1 is returned and errno is set to ESRCH if pid > 0 , the signal is sent to the process with the process ID specified by first argument if pid == 0 the signal is sent to every process in the same..

Lec24) Overview Of UNIX IPC And Signals On The Shell

Inter Process Communciation (IPC) Process Persistence Exists as long as it is held open by a process Pipes and FIFOs TCP, UDP sockets Mutex , condition variables , read write locks POSIX memroy based semaphores Kernel Persistence Exists until kernel reboots or IPC objects is explicitly deleted Message Queues , semaphores & shared memory are at least kernel persistent File system Persistence Exis..

728x90