Professional Documents
Culture Documents
Linux is, in simplest terms, an operating system. It is the software on a computer that enables applications and the computer operator to access the devices on the computer to perform desired functions. The operating system (OS) relays instructions from an application to, for instance, the computer's processor. The processor performs the instructed task, then sends the results back to the application via the operating system.
Features of Linux
Key features of Linux Operating System: Following are the key features of the Linux operating system: Multitasking: several programs running at the same time. Multiuser: several users on the same machine at the same time (and no two-user licenses!). Multiplatform: runs on many different CPUs, not just Intel. Multiprocessor/multithreading: it has native kernel support for multiple independent threads of control within a single process memory space.
Advantages OF Linux
Linux Advantages Low cost: You dont need to spend time and money to obtain licenses since Linux and much of its software come with the GNU General Public License. You can start to work immediately without worrying that your software may stop working anytime because the free trial version expires. Additionally, there are large repositories from which you can freely download high quality software for almost any task you can think of. Stability: Linux doesnt need to be rebooted periodically to maintain performance levels. It doesnt freeze up or slow down over time due to memory leaks and such. Continuous up-times of hundreds of days (up to a year or more) are not uncommon. Performance: Linux provides persistent high performance on workstations and on networks. It can handle unusually large numbers of users simultaneously, and can make old computers sufficiently responsive to be useful again.
Advantages OF Linux
Network friendliness: Linux was developed by a group of programmers over the Internet and has therefore strong support for network functionality; client and server systems can be easily set up on any computer running Linux. It can perform tasks such as network backups faster and more reliably than alternative systems. Flexibility: Linux can be used for high performance server applications, desktop applications, and embedded systems. You can save disk space by only installing the components needed for a particular use. You can restrict the use of specific computers by installing for example only selected office applications instead of the whole suite. Compatibility: It runs all common Unix software packages and can process all common file formats.
Advantages OF Linux
Multitasking: Linux is designed to do many things at the same time; e.g., a large printing job in the background wont slow down your other work. Security: Linux is one of the most secure operating systems. Walls and flexible file access permission systems prevent access by unwanted visitors or viruses. Linux users have to option to select and safely download software, free of charge, from online repositories containing thousands of high quality packages. No purchase transactions requiring credit card numbers or other sensitive personal information are necessary. Open Source: If you develop software that requires knowledge or modification of the operating system code, Linuxs source code is at your fingertips. Most Linux applications are Open Source as well.
Kernal
What is Kernel? Explain the task it performs. Answer Kernel is used in UNIX like systems and is considered to be the heart of the operating system. It is responsible for communication between hardware and software components. It is primarily used for managing the systems resources as well. Kernel Activities: The Kernel task manager allows tasks to run concurrently. Managing the computer resources: Kernel allows the other programs to run and use the resources. Resources include i/o devices, CPU, memory. Kernel is responsible for Process management. It allows multiple processes to run simultaneously allowing user to multitask. Kernel has an access to the systems memory and allows the processes to access the memory when required. Processes may also need to access the devices attached to the system. Kernel assists the processes in doing so. For the processes to access and make use of these services, system calls are used.
1. /bin
Contains several useful commands that are of use to both the system administrator as well as non-privileged users. Usually contains the shells like bash, csh, etc.... and commonly used commands like cp, mv, rm, cat, ls. Also contains programs which boot scripts may depend on There are no (real) subdirectories in /bin
10
1. /bin detail
cat chgrp chmod chown cp date dd df dmesg echo false
Utility to concatenate files to standard output Utility to change file group ownership Utility to change file access permissions Utility to change file owner and group Utility to copy files and directories Utility to print or set the system data and time Utility to convert and copy a file Utility to report filesystem disk space usage Utility to print or control the kernel message buffer Utility to display a line of text Utility to do nothing, unsuccessfully
11
7. /lib
Contains kernel modules and those shared library images (the C programming code library) needed to boot the system and run the commands in the root filesystem, ie. by binaries in /bin and /sbin Windows equivalent to a shared library would be a DLL (dynamically linked library) file
12
4. /etc detail
/etc/hosts : This file is used to define a system name and domain combination with a specific IP address
127.0.0.1 localhost ::1 localhost ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters ff02::3 ip6-allhosts 192.168.0.99 debian.localdomain.com debian
192.168.0.1 ws001
13
5. /home
The user home directories Accessible only to its owner and the system administrator Contains the users personal configuration files Quite large to be used as Users Documents Space
14
10. /mnt
This is a generic mount point under mounted (mount is to make a filesystem available to the system) the filesystems or devices. When a filesystem no longer needs to be mounted, it can be unmounted with umount
15
16
File
Sequence of bytes, with no structure as far as the operating system is concerned. The only operations are to read and write bytes. Interpretation of the data is left to the application using it. File descriptor a handle to a file that the OS provides the user so that it can use the file
File Metadata
Owner: the user who owns this file. Permissions: who is allowed to access this file. Modification time: when this file was last modified. Size: how many bytes of data are there. Data location: where on the disk the files data is stored.
Disk Layout
Boot Block for loading the OS (optional) Swap area (optional) Super Block File system management i-nodes File metadata Data blocks Actual file data
Super Block
Manages the allocation of blocks on the file system area This block contains:
The size of the file system A list of free blocks available on the fs A list of free i-nodes in the fs And more...
Using this information it is possible to allocate disk block for saving file data or file metadata
How do we find the blocks that together constitute the file? How do we find the right block if we want to access the file at a particular offset? How do we make sure not to spend too much space on management data? We need an efficient way to save files of varying sizes.
i-node Structure
System Startup and Shutdown The Boot Process The Initialization Process and Startup Scripts linuxconf and Managing Your Services Shutting Down the Linux System When the System Crashes This chapter explains how to start your Red Hat Linux system, what happens when it starts, and how to properly shut it down. It also covers system crashes and what to do if your system won't boot.