I. Shell BASIC Concepts

Source: Internet
Author: User

I. What is a shell?      < A;. Shell;     < two; the computer manages the entire hardware in fact is the core of the operating system, the core is protected;     < three; computer hardware, operating system, Shell, the relationship between users;         1. We know that computers are capable of computing, storage, networking, multimedia, and so on, and that the basic condition is that the computer has the appropriate hardware support and that the hardware can be managed and used While the computer manages the hardware is actually the operating system and and hardware-driven support;         2. The core of the operating system is actually a set of programs that control the computer's hardware and manage system activity;         3. On the other level, the computer can not automatically say the calculation, play video, music and so on; These functions can only work if the user has a related command request to the operating system. Because the operating system is the core of the management system hardware, so this core should be protected, users can not casually operate the operating system, because improper operation may cause the entire computer hardware system crash.           4. So, just a shell for the operating system to protect the operating system. The shell (shell), defined and validated, stipulates that the user's operation will not cause damage to the computer's hardware system. And, through the shell Input command, can be correctly parsed and communicated to the operating system, and ensure that the corresponding command request can be implemented correctly. Diagram:                      < four;. It can be understood that shell:      Shell is an application; The shell defines a series of commands that the shell can parse and invoke the specific functions of the correct operating system after the user enters these commands; The commands entered by the user can be the same as a high-level programming language, with variables and parameters, and a control structure, so the shell is a programming language. As the command language, its interactive solutionExecute user-entered commands or automatically interpret and execute a predetermined set of commands; As a programming language, it defines variables and parameters and has control structures, including loops and branches, which are shell Script.    1.shell is a command interpreter capable of interpreting user input commands and invoking operating system functions;  &NBSP;2.SEHLL is the interface between the user and the operating system, the bridge ; that is, protecting the operating system core also provides the conditions for the user to operate the operating system and gain functionality;   3.shell provides commands that can be executed as input to a command, execute, or write logic like a programming language. So the shell is a programming language;
4.shell provides a way for you to communicate with the operating system. There are two kinds: a. Interactive mode:(Input from the keyboard and can be immediately responded to) in fact, one command is entered at a time; B. Non-interactiveWay :To Shell ScriptPerform. Shell script is a string of shell and OS commands placed in a file that can be reused. Essentially, shell script is a simple combination of command-line commands into a file. In this mode, the shell does not interact with you, but instead reads the commands stored in the file and executes them. When it reads the end of the file, the shell terminates. Two. What is bash?    1.Shell type      shell type       in Unix mainly:      bourne Shell (including Sh,ksh,and bash)      bourne shell (SH)       Korn Shell (ksh)      bourne Again shell (bash)      posix Shell (SH)      c Shell (including csh and tcsh)      c Shell (CSH)    & Nbsp; tenex/tops C Shell (tcsh)   2. Most commonly: bash; So, bash is a shell; what is shell script?     shell Script is a "program" written using the shell's function, which uses a pure text file to write some of the shell's language and instructions (including external instructions), with the functions of regular notation, command and flow redirection, to achieve the purpose we want for the purposes we desire.       Shell script is like a batch (. bat) of the early DOS era, the simplest feature is to write many instructions together, so that users can easily be able to use one touch method to deal with complex motion ( execute a file "shell script" to perform multiple instructions at once)。 Shell script also provides important functions such as arrays, loops, conditions, and logically, allowing users to write programs directly from the shell.

I. Shell BASIC Concepts

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.