University Of Palestine. Essential System Administration 3rd Edition. Chapter 2 The Unix Way(Cont.). Ch2. University Of Palestine. 2.2 Processes. In simple terms, a process is a single executable program that is running in its own address space.

Copyright Complaint Adult Content Flag as Inappropriate

Download Presentation

Essential System Administration 3rd Edition

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

Real and effective user ID (RUID, EUID) : process's real UID is the UID of the user who started it. Its effective UID is the UID that is used to determine the process's access to system resources (such as files and devices).

Real and effective group ID (RGID, EGID):

Ch2

University Of Palestine

2.2 Processes (Cont.)

2.2.4.1 The life cycle of a process

The following figure illustrates the phases of the process life cycle:

Ch2

University Of Palestine

2.2 Processes (Cont.)

2.2.4.2 The relationship between commands and files

The Unix operating system does not distinguish between commands and files in the ways that some systems do.

Unix commands are executable files stored in one of several standard locations within the filesystem.

Access to commands is exactly equivalent to access to these files. By default, there is no other privilege mechanism.

Ch2

University Of Palestine

2.3 Devices

One of the strengths of Unix is that users don't need to worry about the specific characteristics of devices and device I/O very often.

Device files are characterized by their major and minor numbers , which allow the kernel to determine which device driver to use to access the device (via the major number), as well as its specific method of access (via the minor number).

Major and minor numbers appear in place of the file size in long directory listings.

Ch2

University Of Palestine

2.3 Devices (Cont.)

For example, consider these device files related to the mouse from a Linux system:

$ cd /dev;

ls -l *mouse

crw-rw-r-- 1 root root 10, 10 Jan 19 03:36 adbmouse

crw-rw-r-- 1 root root 10, 4 Jan 19 03:35 amigamouse

crw-rw-r-- 1 root root 10, 5 Jan 19 03:35 atarimouse

crw-rw-r-- 1 root root 10, 8 Jan 19 03:35 smouse

crw-rw-r-- 1 root root 10, 6 Jan 19 03:35 sunmouse

crw-rw-r-- 1 root root 13, 32 Jan 19 03:36 usbmouse

The major number for all but the last special file is 10; only the minor number differs for these devices.

Thus, all of these mouse device variations are handled by the same device driver.

The final item, corresponding to a USB mouse, has a different major number, indicating that a different device driver is used.

Ch2

University Of Palestine

2.3 Devices (Cont.)

Device files are created with the mknod command.

t takes the desired device name and major and minor numbers as its arguments.

Many systems provide a script named MAKEDEV (located in /dev), which is an easy-to-use interface to mknod.