A shell is a command interpreter that sits between you and the operating system. You type a command, the shell finds and starts the program, and it shows the output or error.
Why it matters
Shells are how servers are administered, automated, and debugged. A shell script chains commands to repeat tasks such as backups or deployments. Common shells include bash, zsh, and sh on Unix systems, and PowerShell and cmd on Windows.
The shell is separate from the terminal, which is only the window that displays text.
Example
$ echo $SHELL
/bin/bash
$ ls -l | wc -l
The first command prints your login shell. The second pipes the file listing into a line counter, showing how a shell connects programs.
Common mistakes
- Writing scripts for bash and running them with sh, where features such as arrays may be missing.
- Forgetting to quote variables, so spaces in filenames break commands.
- Mixing up the shell and the terminal emulator.
Related
Get notified when this term updates
Plus occasional practical tips on uptime and monitoring, nothing else. Unsubscribe anytime.
यह पेज सामान्य जानकारी है, जिसे हमारी संपादकीय टीम ने लिखा है और दस्तावेज़ीकरण बदलने पर अपडेट किया जाता है। सर्वर और प्रदाता अलग-अलग होते हैं, इसलिए बदलाव पहले सुरक्षित तरीके से जाँचें। देखें: संपादकीय नीति और अस्वीकरण.