What is the exact difference between a 'terminal', a 'shell', a 'tty' and a 'console'?












1148















I think these terms almost refer to the same thing, when used loosely:




  • terminal

  • shell

  • tty

  • console


What exactly does each of these terms refer to?










share|improve this question




















  • 75





    The TTY demystified

    – firo
    Mar 7 '13 at 7:54








  • 24





    I'd like to add 'command line' to that :-)

    – teeks99
    Sep 7 '14 at 13:32






  • 1





    The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

    – Marty Fried
    Sep 7 '14 at 18:03






  • 1





    The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

    – Serge Stroobandt
    Dec 10 '15 at 20:28













  • Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

    – Nishant
    Dec 25 '18 at 19:58


















1148















I think these terms almost refer to the same thing, when used loosely:




  • terminal

  • shell

  • tty

  • console


What exactly does each of these terms refer to?










share|improve this question




















  • 75





    The TTY demystified

    – firo
    Mar 7 '13 at 7:54








  • 24





    I'd like to add 'command line' to that :-)

    – teeks99
    Sep 7 '14 at 13:32






  • 1





    The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

    – Marty Fried
    Sep 7 '14 at 18:03






  • 1





    The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

    – Serge Stroobandt
    Dec 10 '15 at 20:28













  • Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

    – Nishant
    Dec 25 '18 at 19:58
















1148












1148








1148


811






I think these terms almost refer to the same thing, when used loosely:




  • terminal

  • shell

  • tty

  • console


What exactly does each of these terms refer to?










share|improve this question
















I think these terms almost refer to the same thing, when used loosely:




  • terminal

  • shell

  • tty

  • console


What exactly does each of these terms refer to?







shell terminal console tty terminology






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 7 '15 at 3:55









Navin

146111




146111










asked Nov 16 '10 at 20:06









LazerLazer

12.7k196273




12.7k196273








  • 75





    The TTY demystified

    – firo
    Mar 7 '13 at 7:54








  • 24





    I'd like to add 'command line' to that :-)

    – teeks99
    Sep 7 '14 at 13:32






  • 1





    The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

    – Marty Fried
    Sep 7 '14 at 18:03






  • 1





    The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

    – Serge Stroobandt
    Dec 10 '15 at 20:28













  • Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

    – Nishant
    Dec 25 '18 at 19:58
















  • 75





    The TTY demystified

    – firo
    Mar 7 '13 at 7:54








  • 24





    I'd like to add 'command line' to that :-)

    – teeks99
    Sep 7 '14 at 13:32






  • 1





    The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

    – Marty Fried
    Sep 7 '14 at 18:03






  • 1





    The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

    – Serge Stroobandt
    Dec 10 '15 at 20:28













  • Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

    – Nishant
    Dec 25 '18 at 19:58










75




75





The TTY demystified

– firo
Mar 7 '13 at 7:54







The TTY demystified

– firo
Mar 7 '13 at 7:54






24




24





I'd like to add 'command line' to that :-)

– teeks99
Sep 7 '14 at 13:32





I'd like to add 'command line' to that :-)

– teeks99
Sep 7 '14 at 13:32




1




1





The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

– Marty Fried
Sep 7 '14 at 18:03





The command line is simply the language used to send commands to the command-line interpreter running in a shell from the terminal/terminal emulator.

– Marty Fried
Sep 7 '14 at 18:03




1




1





The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

– Serge Stroobandt
Dec 10 '15 at 20:28







The teletypewriter (TTY) was first put in operation and exhibited at the Mechanics Institute in New York in 1844. en.wikipedia.org/wiki/Teleprinter

– Serge Stroobandt
Dec 10 '15 at 20:28















Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

– Nishant
Dec 25 '18 at 19:58







Two more useful links - feyrer.de/NetBSD/ttys.html and quora.com/…

– Nishant
Dec 25 '18 at 19:58












9 Answers
9






active

oldest

votes


















1131














A terminal is at the end of an electric wire, a shell is the home of a turtle, tty is a strange abbreviation and a console is a kind of cabinet.



Well, etymologically speaking, anyway.



In unix terminology, the short answer is that




  • terminal = tty = text input/output environment

  • console = physical terminal

  • shell = command line interpreter




Console, terminal and tty are closely related. Originally, they meant a piece of equipment through which you could interact with a computer: in the early days of unix, that meant a teleprinter-style device resembling a typewriter, sometimes called a teletypewriter, or “tty” in shorthand. The name “terminal” came from the electronic point of view, and the name “console” from the furniture point of view. Very early in unix history, electronic keyboards and displays became the norm for terminals.



In unix terminology, a tty is a particular kind of device file which implements a number of additional commands (ioctls) beyond read and write. In its most common meaning, terminal is synonymous with tty. Some ttys are provided by the kernel on behalf of a hardware device, for example with the input coming from the keyboard and the output going to a text mode screen, or with the input and output transmitted over a serial line. Other ttys, sometimes called pseudo-ttys, are provided (through a thin kernel layer) by programs called terminal emulators, such as Xterm (running in the X Window System), Screen (which provides a layer of isolation between a program and another terminal), Ssh (which connects a terminal on one machine with programs on another machine), Expect (for scripting terminal interactions), etc.



The word terminal can also have a more traditional meaning of a device through which one interacts with a computer, typically with a keyboard and display. For example an X terminal is a kind of thin client, a special-purpose computer whose only purpose is to drive a keyboard, display, mouse and occasionally other human interaction peripherals, with the actual applications running on another, more powerful computer.



A console is generally a terminal in the physical sense that is by some definition the primary terminal directly connected to a machine. The console appears to the operating system as a (kernel-implemented) tty. On some systems, such as Linux and FreeBSD, the console appears as several ttys (special key combinations switch between these ttys); just to confuse matters, the name given to each particular tty can be “console”, ”virtual console”, ”virtual terminal”, and other variations.



See also Why is a Virtual Terminal “virtual”, and what/why/where is the “real” Terminal?.





A shell is the primary interface that users see when they log in, whose primary purpose is to start other programs. (I don't know whether the original metaphor is that the shell is the home environment for the user, or that the shell is what other programs are running in.)



In unix circles, shell has specialized to mean a command-line shell, centered around entering the name of the application one wants to start, followed by the names of files or other objects that the application should act on, and pressing the Enter key. Other types of environments don't use the word “shell”; for example, window systems involve “window managers” and “desktop environments”, not a “shell”.



There are many different unix shells.
Popular shells for interactive use include Bash (the default on most Linux installations), zsh (which emphasizes power and customizability) and fish (which emphasizes simplicity).



Command-line shells include flow control constructs to combine commands. In addition to typing commands at an interactive prompt, users can write scripts. The most common shells have a common syntax based on the Bourne_shell. When discussing “shell programming”, the shell is almost always implied to be a Bourne-style shell. Some shells that are often used for scripting but lack advanced interactive features include the Korn shell (ksh) and many ash variants. Pretty much any Unix-like system has a Bourne-style shell installed as /bin/sh, usually ash, ksh or bash.



In unix system administration, a user's shell is the program that is invoked when they log in. Normal user accounts have a command-line shell, but users with restricted access may have a restricted shell or some other specific command (e.g. for file-transfer-only accounts).





The division of labor between the terminal and the shell is not completely obvious. Here are their main tasks.




  • Input: the terminal converts keys into control sequences (e.g. Lefte[D). The shell converts control sequences into commands (e.g. e[Dbackward-char).

  • Line editing, input history and completion are provided by the shell.


    • The terminal may provide its own line editing, history and completion instead, and only send a line to the shell when it's ready to be executed. The only common terminal that operates in this way is M-x shell in Emacs.



  • Output: the shell emits instructions such as “display foo”, “switch the foreground color to green”, “move the cursor to the next line”, etc. The terminal acts on these instructions.

  • The prompt is purely a shell concept.

  • The shell never sees the output of the commands it runs (unless redirected). Output history (scrollback) is purely a terminal concept.

  • Inter-application copy-paste is provided by the terminal (usually with the mouse or key sequences such as Ctrl+Shift+V or Shift+Insert). The shell may have its own internal copy-paste mechanism as well (e.g. Meta+W and Ctrl+Y).


  • Job control (launching programs in the background and managing them) is mostly performed by the shell. However, it's the terminal that handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it.






share|improve this answer





















  • 47





    Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

    – Chris Johnsen
    Nov 17 '10 at 4:04






  • 12





    @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

    – Gilles
    Nov 17 '10 at 19:27








  • 23





    This is the image in my mind for the shell metaphor.

    – ændrük
    Dec 7 '10 at 19:00






  • 12





    There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

    – derobert
    Aug 29 '11 at 21:12








  • 19





    “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

    – Chris Page
    Mar 10 '12 at 20:34



















187














A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen.

Nowadays nearly all terminals and consoles represent "virtual" ones.



The file that represents a terminal is, traditionally, called a tty file. If you look under the "/dev" directory of a UNIX system, you'll find a lot of tty files connected to virtual consoles (e.g. tty1 on linux), virtual terminals (e.g. pts/0) or physically connected hardware (e.g. ttyS0 is the physical serial terminal, if any, attached on first serial port of the host).



A console must be a piece of hardware physically connected to (or part of) the host. It has a special role in the system: it is the main point to access a system for maintenance and some special operation can be done only from a console (e.g. see single user mode). A terminal can be, and usually is, a remote piece of hardware.



Last, but not the least, a shell is a special program that interacts with a user through a controlling tty and offers, to the user, the way of launching other programs (e.g. bash, csh, tcsh).



A terminal emulator is a program that emulates a physical terminal (e.g. xterm, gnome-terminal, minicom).



So when you look to a "text window" on your linux system (under X11) you are looking to: a terminal emulator, connected to a virtual terminal, identified by a tty file, inside which runs a shell.






share|improve this answer





















  • 1





    Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

    – Incnis Mrsi
    Sep 6 '15 at 7:20













  • "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

    – Webwoman
    Sep 9 '18 at 11:45













  • @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

    – Motivated
    Jan 16 at 6:43











  • @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

    – Motivated
    Jan 16 at 6:45






  • 1





    @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

    – andcoz
    Jan 16 at 13:45



















42














SHORT explanation:



The console is a terminal. A system has got one console and potentially multiple terminals. The console is typically the primary interface for managing a computer, eg while it is still booting up.



A terminal is a session which can receive and send input and output for command-line programs. The console is a special case of these.



A TTY is essentially a pseudo device, call it a kernel resource, which is used by processes to access a specific terminal. TTYs can be tied to hardware such as a serial port, or can be virtual, eg created when a user logs in via a network



The shell is a program which is used for controlling and running programs. It is often used interactively, via a terminal. Several Shell programs exist, Bash being arguably the most commonly used shell today. Other shells, in no particular order, includes Bourne Shell, C-shell, Dash, Tsch, Ksh, and the increasingly popular zsh. There are many more.



When you have a GUI, you can use a terminal program to draw a nice resizeable border, add scroll bars, and format the text, and so on, for a terminal session. Often these are called terminal emulators, and sometimes they can handle multiple sessions via a TAB concept. A Terminal Emulator often starts a Shell to allow you to interactively work on a command line.






share|improve this answer





















  • 1





    PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

    – Luciano
    Jun 18 '15 at 21:23





















29














A TTY (i.e. TeleTYpewriter) is a special device that lets people who are deaf, hard of hearing, or speech-impaired use the telephone to communicate, by allowing them to type text messages. A TTY is required at both ends of the conversation in order to communicate.

OR
TTY is terminal which is used to type text message.





Shell :the outside protective covering part of a seed i.e. kernel.

OR

framework or exterior structure to central or essential part of a system.
enter image description here





Console means the keyboard and monitor physically attachements to a computer.






share|improve this answer

































    24














    There are already two great answers, but Ī̲’d like to add information about the phrase “virtual terminal”. Generally, it means something that provides appearance/functionality of a terminal, i. e. a terminal-emulator in broad sense. But in early days of Linux (1994–95) is was used synonymously with “virtual console” (several unrelated user interfaces), by some developers. This usage persists in documentation; two different terms were (and are) used to refer to tty1, tty2… thingies. Nowadays (since ≈ 1996) “virtual terminal” may also refer to pty-based terminal emulators.



    Linux’s vt (the driver of text mode system console) was the first piece of its kernel. It was initially used for connection to mainframes and in this sense it’s a “virtual terminal”, hence the name. The code controlling virtual consoles resides in vt.c as well. Linux kernel engineers consistently use the word “consoles” to denote tty1, tty2… and used “vc_” prefix for them. For example, there is a vc_allocate function. On the other hand, developers of such user-space tools as kbd and console-tools used “virtual console” (VC) and “virtual terminal” (VT) interchangeably. Ī̲ contacted Andries E. Brouwer and asked him to clarify terminology used by early developers (1994–95). Andries kindly provided some answers. He states that VT and VC are synonymous and “indivisible” abbreviations.

    -->
    In general, a virtual console is a virtual terminal, but converse isn’t true. Those “virtual terminals” that are not virtual consoles are indeed pseudoterminals (as Andries states, these are not VT). Unlike virtual consoles, where the kernel provides terminal functionality for a console application, pseudoterminals use PTY “devices” to arrange communication between console applications and the terminal-making program that runs in userspace. Examples are X-based terminal emulators and sshd, that allocates a pseudotty for each login session. A pseudotty may not be called “console” – it’s a mistake.






    share|improve this answer

































      10















      • Terminal = An interface that provides a display for output
        and a key board for input to a shell session .


      • Shell = Interpreter that executes commands typed as string



      • Console: Actually two types of console we use




        • Physical console=The hardware display and keyboard used to interact with a system


        • Virtual console= One of multiple logical consoles that can each support an independent login session.




      • tty(teletype ie terminal). = A terminal is a basically just a user interface device that uses text for input and output.message.







      share|improve this answer


























      • What is a tty ? -- otherwise, your answer is the only one I read

        – loxaxs
        Jul 2 '17 at 21:39





















      5














      You need to dive into history.



      There were typewriter-like devices with paper and keyboard. They were called teletypes (which means "type remotely," since "tele" means "remote") or ttys for short. In the 70s they were obsoleted by devices with CRT monitor called glass ttys.



      Any computer need some way to report its status and errors (and, probably, accept commands). It is done through console which is almost always connected directly to the computer. So, there are 2 meanings for console: something that is used to report status and something that is connected directly.



      UNIX is an interactive system: several users may connect to it and start applications. First computers used teletypes (tty) for that: each user had teletype connected to machine with serial line connection. Such teletype is called terminal.
      UNIX also got special subsystem to handle "users sitting behind terminals" which is also called tty because first terminals were teletypes.
      Each process could be connected to tty in Unix. That means there is a user somewhere sitting near terminal. See http://www.linusakesson.net/programming/tty/ for more info.



      Users need some way to tell kernel to run application. shell (sh, bash, csh, ksh, etc.) is used for that. shell runs on tty, accepts commands from user and asks kernel to run some app.



      But terminals are not always physically connected to the machine. There may be some application that "emulates" terminal accepting keystrokes from user and sending them somewhere (xterm and ssh are good examples). There is an API in Kernel called pseudo terminal for that.
      So your tty may really be connected to some application instead of real terminal. Xterm uses X11 to display text and ssh uses network connection for it.



      IBM PC has keyboard and video card (they are also called console sometimes).
      Linux can do different things with it:




      • Use it as "engine to report errors and status": Linux console. If you pass console=/dev/ttyS0 to kernel it will use something connected to COM1 as console, and if you do not it will use PC console.

      • Use it to emulate terminal, so called virtual terminal (vty).


      It also may stop emulating terminal on console and give it to some app. App may switch its video mode and use it exclusively (X11 or svgalib may do that).



      So, here are modern meanings:




      • terminal: Something with real user sitting behind it. Could be physical terminal (rare) or pseudo terminal (xterm, ssh) or virtual terminal (vty in Linux)

      • shell: application (bash, tcsh, etc) that helps user to interact with system.

      • tty: either terminal or kernel subsystem to support terminals.

      • console: something where status and errors are reported (/dev/console) or physical keyboard and video display connected to computer.






      share|improve this answer

































        3














        Here is the short answer -



        Kernel - the innermost part of any modern operating system which directly talks to actual hardware.



        Shell - wrapper around the actual Kernel. Whenever we run command, we actually talk to shell which in turn invokes appropriate Kernel instructions. Apart from this, the shell is capable of performing some other stuffs like finding appropriate program while having commands, some file name short hand, piping commands etc.



        Terminal - in the era of earlier computing, computers (known as Mainframe) were giant. So, it was easy to have a single processing unit and connect it from many places. Terminal is the actual hardware with keyboard and output devices connected to mainframe.



        Console - Special type of terminal which is directly connected to Mainframe for the purpose of OS Administration.



        tty - TeleTypewriter used to send and receive data to and from Mainframe. Used before Video Terminals were available. But conventionally it has been still named as tty. Even the coommand stty



        The long detailed answer is here - Terminal, Console, Shell, Kernel, Commands - Different parts of a Computer






        share|improve this answer


























        • thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

          – Webwoman
          Sep 9 '18 at 11:59





















        2














        Apart from the accepted answer and The TTY demystified article, I really loved reading these two articles:



        This one is based on NetBSD.




        Back in the stone ages of Unix, computer systems consisted of a
        mainframe, a big box of blinking lights which had memory, mass storage
        and computing units, and that run processes started by users or
        operators. As the hardware was very expensive, the systems were used
        as true multiuser systems, with many people interacting with the
        system at the same time. What it usually didn't have - unlike today's
        Unix workstations - was a fixed monitor and keyboard. Instead, issuing
        commands to the machine and retrieving output was done over serial
        lines, using teletypers first, and CRT (cathode ray tube) terminals
        later. Teletypers - that's where the "ttys" in Unix come from - are
        electronic typewriters that send keys pressed over the serial line to
        the host, and replies were sent back to the teletyper char by char
        over the serial line, with the built-in printer putting the reply on
        paper, much like a typewriter.




        This one is based on Linux.




        Terminals are devices that provide enhanced input/output capabilities
        beyond what could be achieved with only regular files, pipes, and
        sockets. These features are designed to make it easier for humans to
        interact with computers, and are useless for programs trying to talk
        to each other.







        share|improve this answer






















          protected by Anthon Jul 7 '17 at 22:02



          Thank you for your interest in this question.
          Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).



          Would you like to answer one of these unanswered questions instead?














          9 Answers
          9






          active

          oldest

          votes








          9 Answers
          9






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1131














          A terminal is at the end of an electric wire, a shell is the home of a turtle, tty is a strange abbreviation and a console is a kind of cabinet.



          Well, etymologically speaking, anyway.



          In unix terminology, the short answer is that




          • terminal = tty = text input/output environment

          • console = physical terminal

          • shell = command line interpreter




          Console, terminal and tty are closely related. Originally, they meant a piece of equipment through which you could interact with a computer: in the early days of unix, that meant a teleprinter-style device resembling a typewriter, sometimes called a teletypewriter, or “tty” in shorthand. The name “terminal” came from the electronic point of view, and the name “console” from the furniture point of view. Very early in unix history, electronic keyboards and displays became the norm for terminals.



          In unix terminology, a tty is a particular kind of device file which implements a number of additional commands (ioctls) beyond read and write. In its most common meaning, terminal is synonymous with tty. Some ttys are provided by the kernel on behalf of a hardware device, for example with the input coming from the keyboard and the output going to a text mode screen, or with the input and output transmitted over a serial line. Other ttys, sometimes called pseudo-ttys, are provided (through a thin kernel layer) by programs called terminal emulators, such as Xterm (running in the X Window System), Screen (which provides a layer of isolation between a program and another terminal), Ssh (which connects a terminal on one machine with programs on another machine), Expect (for scripting terminal interactions), etc.



          The word terminal can also have a more traditional meaning of a device through which one interacts with a computer, typically with a keyboard and display. For example an X terminal is a kind of thin client, a special-purpose computer whose only purpose is to drive a keyboard, display, mouse and occasionally other human interaction peripherals, with the actual applications running on another, more powerful computer.



          A console is generally a terminal in the physical sense that is by some definition the primary terminal directly connected to a machine. The console appears to the operating system as a (kernel-implemented) tty. On some systems, such as Linux and FreeBSD, the console appears as several ttys (special key combinations switch between these ttys); just to confuse matters, the name given to each particular tty can be “console”, ”virtual console”, ”virtual terminal”, and other variations.



          See also Why is a Virtual Terminal “virtual”, and what/why/where is the “real” Terminal?.





          A shell is the primary interface that users see when they log in, whose primary purpose is to start other programs. (I don't know whether the original metaphor is that the shell is the home environment for the user, or that the shell is what other programs are running in.)



          In unix circles, shell has specialized to mean a command-line shell, centered around entering the name of the application one wants to start, followed by the names of files or other objects that the application should act on, and pressing the Enter key. Other types of environments don't use the word “shell”; for example, window systems involve “window managers” and “desktop environments”, not a “shell”.



          There are many different unix shells.
          Popular shells for interactive use include Bash (the default on most Linux installations), zsh (which emphasizes power and customizability) and fish (which emphasizes simplicity).



          Command-line shells include flow control constructs to combine commands. In addition to typing commands at an interactive prompt, users can write scripts. The most common shells have a common syntax based on the Bourne_shell. When discussing “shell programming”, the shell is almost always implied to be a Bourne-style shell. Some shells that are often used for scripting but lack advanced interactive features include the Korn shell (ksh) and many ash variants. Pretty much any Unix-like system has a Bourne-style shell installed as /bin/sh, usually ash, ksh or bash.



          In unix system administration, a user's shell is the program that is invoked when they log in. Normal user accounts have a command-line shell, but users with restricted access may have a restricted shell or some other specific command (e.g. for file-transfer-only accounts).





          The division of labor between the terminal and the shell is not completely obvious. Here are their main tasks.




          • Input: the terminal converts keys into control sequences (e.g. Lefte[D). The shell converts control sequences into commands (e.g. e[Dbackward-char).

          • Line editing, input history and completion are provided by the shell.


            • The terminal may provide its own line editing, history and completion instead, and only send a line to the shell when it's ready to be executed. The only common terminal that operates in this way is M-x shell in Emacs.



          • Output: the shell emits instructions such as “display foo”, “switch the foreground color to green”, “move the cursor to the next line”, etc. The terminal acts on these instructions.

          • The prompt is purely a shell concept.

          • The shell never sees the output of the commands it runs (unless redirected). Output history (scrollback) is purely a terminal concept.

          • Inter-application copy-paste is provided by the terminal (usually with the mouse or key sequences such as Ctrl+Shift+V or Shift+Insert). The shell may have its own internal copy-paste mechanism as well (e.g. Meta+W and Ctrl+Y).


          • Job control (launching programs in the background and managing them) is mostly performed by the shell. However, it's the terminal that handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it.






          share|improve this answer





















          • 47





            Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

            – Chris Johnsen
            Nov 17 '10 at 4:04






          • 12





            @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

            – Gilles
            Nov 17 '10 at 19:27








          • 23





            This is the image in my mind for the shell metaphor.

            – ændrük
            Dec 7 '10 at 19:00






          • 12





            There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

            – derobert
            Aug 29 '11 at 21:12








          • 19





            “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

            – Chris Page
            Mar 10 '12 at 20:34
















          1131














          A terminal is at the end of an electric wire, a shell is the home of a turtle, tty is a strange abbreviation and a console is a kind of cabinet.



          Well, etymologically speaking, anyway.



          In unix terminology, the short answer is that




          • terminal = tty = text input/output environment

          • console = physical terminal

          • shell = command line interpreter




          Console, terminal and tty are closely related. Originally, they meant a piece of equipment through which you could interact with a computer: in the early days of unix, that meant a teleprinter-style device resembling a typewriter, sometimes called a teletypewriter, or “tty” in shorthand. The name “terminal” came from the electronic point of view, and the name “console” from the furniture point of view. Very early in unix history, electronic keyboards and displays became the norm for terminals.



          In unix terminology, a tty is a particular kind of device file which implements a number of additional commands (ioctls) beyond read and write. In its most common meaning, terminal is synonymous with tty. Some ttys are provided by the kernel on behalf of a hardware device, for example with the input coming from the keyboard and the output going to a text mode screen, or with the input and output transmitted over a serial line. Other ttys, sometimes called pseudo-ttys, are provided (through a thin kernel layer) by programs called terminal emulators, such as Xterm (running in the X Window System), Screen (which provides a layer of isolation between a program and another terminal), Ssh (which connects a terminal on one machine with programs on another machine), Expect (for scripting terminal interactions), etc.



          The word terminal can also have a more traditional meaning of a device through which one interacts with a computer, typically with a keyboard and display. For example an X terminal is a kind of thin client, a special-purpose computer whose only purpose is to drive a keyboard, display, mouse and occasionally other human interaction peripherals, with the actual applications running on another, more powerful computer.



          A console is generally a terminal in the physical sense that is by some definition the primary terminal directly connected to a machine. The console appears to the operating system as a (kernel-implemented) tty. On some systems, such as Linux and FreeBSD, the console appears as several ttys (special key combinations switch between these ttys); just to confuse matters, the name given to each particular tty can be “console”, ”virtual console”, ”virtual terminal”, and other variations.



          See also Why is a Virtual Terminal “virtual”, and what/why/where is the “real” Terminal?.





          A shell is the primary interface that users see when they log in, whose primary purpose is to start other programs. (I don't know whether the original metaphor is that the shell is the home environment for the user, or that the shell is what other programs are running in.)



          In unix circles, shell has specialized to mean a command-line shell, centered around entering the name of the application one wants to start, followed by the names of files or other objects that the application should act on, and pressing the Enter key. Other types of environments don't use the word “shell”; for example, window systems involve “window managers” and “desktop environments”, not a “shell”.



          There are many different unix shells.
          Popular shells for interactive use include Bash (the default on most Linux installations), zsh (which emphasizes power and customizability) and fish (which emphasizes simplicity).



          Command-line shells include flow control constructs to combine commands. In addition to typing commands at an interactive prompt, users can write scripts. The most common shells have a common syntax based on the Bourne_shell. When discussing “shell programming”, the shell is almost always implied to be a Bourne-style shell. Some shells that are often used for scripting but lack advanced interactive features include the Korn shell (ksh) and many ash variants. Pretty much any Unix-like system has a Bourne-style shell installed as /bin/sh, usually ash, ksh or bash.



          In unix system administration, a user's shell is the program that is invoked when they log in. Normal user accounts have a command-line shell, but users with restricted access may have a restricted shell or some other specific command (e.g. for file-transfer-only accounts).





          The division of labor between the terminal and the shell is not completely obvious. Here are their main tasks.




          • Input: the terminal converts keys into control sequences (e.g. Lefte[D). The shell converts control sequences into commands (e.g. e[Dbackward-char).

          • Line editing, input history and completion are provided by the shell.


            • The terminal may provide its own line editing, history and completion instead, and only send a line to the shell when it's ready to be executed. The only common terminal that operates in this way is M-x shell in Emacs.



          • Output: the shell emits instructions such as “display foo”, “switch the foreground color to green”, “move the cursor to the next line”, etc. The terminal acts on these instructions.

          • The prompt is purely a shell concept.

          • The shell never sees the output of the commands it runs (unless redirected). Output history (scrollback) is purely a terminal concept.

          • Inter-application copy-paste is provided by the terminal (usually with the mouse or key sequences such as Ctrl+Shift+V or Shift+Insert). The shell may have its own internal copy-paste mechanism as well (e.g. Meta+W and Ctrl+Y).


          • Job control (launching programs in the background and managing them) is mostly performed by the shell. However, it's the terminal that handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it.






          share|improve this answer





















          • 47





            Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

            – Chris Johnsen
            Nov 17 '10 at 4:04






          • 12





            @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

            – Gilles
            Nov 17 '10 at 19:27








          • 23





            This is the image in my mind for the shell metaphor.

            – ændrük
            Dec 7 '10 at 19:00






          • 12





            There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

            – derobert
            Aug 29 '11 at 21:12








          • 19





            “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

            – Chris Page
            Mar 10 '12 at 20:34














          1131












          1131








          1131







          A terminal is at the end of an electric wire, a shell is the home of a turtle, tty is a strange abbreviation and a console is a kind of cabinet.



          Well, etymologically speaking, anyway.



          In unix terminology, the short answer is that




          • terminal = tty = text input/output environment

          • console = physical terminal

          • shell = command line interpreter




          Console, terminal and tty are closely related. Originally, they meant a piece of equipment through which you could interact with a computer: in the early days of unix, that meant a teleprinter-style device resembling a typewriter, sometimes called a teletypewriter, or “tty” in shorthand. The name “terminal” came from the electronic point of view, and the name “console” from the furniture point of view. Very early in unix history, electronic keyboards and displays became the norm for terminals.



          In unix terminology, a tty is a particular kind of device file which implements a number of additional commands (ioctls) beyond read and write. In its most common meaning, terminal is synonymous with tty. Some ttys are provided by the kernel on behalf of a hardware device, for example with the input coming from the keyboard and the output going to a text mode screen, or with the input and output transmitted over a serial line. Other ttys, sometimes called pseudo-ttys, are provided (through a thin kernel layer) by programs called terminal emulators, such as Xterm (running in the X Window System), Screen (which provides a layer of isolation between a program and another terminal), Ssh (which connects a terminal on one machine with programs on another machine), Expect (for scripting terminal interactions), etc.



          The word terminal can also have a more traditional meaning of a device through which one interacts with a computer, typically with a keyboard and display. For example an X terminal is a kind of thin client, a special-purpose computer whose only purpose is to drive a keyboard, display, mouse and occasionally other human interaction peripherals, with the actual applications running on another, more powerful computer.



          A console is generally a terminal in the physical sense that is by some definition the primary terminal directly connected to a machine. The console appears to the operating system as a (kernel-implemented) tty. On some systems, such as Linux and FreeBSD, the console appears as several ttys (special key combinations switch between these ttys); just to confuse matters, the name given to each particular tty can be “console”, ”virtual console”, ”virtual terminal”, and other variations.



          See also Why is a Virtual Terminal “virtual”, and what/why/where is the “real” Terminal?.





          A shell is the primary interface that users see when they log in, whose primary purpose is to start other programs. (I don't know whether the original metaphor is that the shell is the home environment for the user, or that the shell is what other programs are running in.)



          In unix circles, shell has specialized to mean a command-line shell, centered around entering the name of the application one wants to start, followed by the names of files or other objects that the application should act on, and pressing the Enter key. Other types of environments don't use the word “shell”; for example, window systems involve “window managers” and “desktop environments”, not a “shell”.



          There are many different unix shells.
          Popular shells for interactive use include Bash (the default on most Linux installations), zsh (which emphasizes power and customizability) and fish (which emphasizes simplicity).



          Command-line shells include flow control constructs to combine commands. In addition to typing commands at an interactive prompt, users can write scripts. The most common shells have a common syntax based on the Bourne_shell. When discussing “shell programming”, the shell is almost always implied to be a Bourne-style shell. Some shells that are often used for scripting but lack advanced interactive features include the Korn shell (ksh) and many ash variants. Pretty much any Unix-like system has a Bourne-style shell installed as /bin/sh, usually ash, ksh or bash.



          In unix system administration, a user's shell is the program that is invoked when they log in. Normal user accounts have a command-line shell, but users with restricted access may have a restricted shell or some other specific command (e.g. for file-transfer-only accounts).





          The division of labor between the terminal and the shell is not completely obvious. Here are their main tasks.




          • Input: the terminal converts keys into control sequences (e.g. Lefte[D). The shell converts control sequences into commands (e.g. e[Dbackward-char).

          • Line editing, input history and completion are provided by the shell.


            • The terminal may provide its own line editing, history and completion instead, and only send a line to the shell when it's ready to be executed. The only common terminal that operates in this way is M-x shell in Emacs.



          • Output: the shell emits instructions such as “display foo”, “switch the foreground color to green”, “move the cursor to the next line”, etc. The terminal acts on these instructions.

          • The prompt is purely a shell concept.

          • The shell never sees the output of the commands it runs (unless redirected). Output history (scrollback) is purely a terminal concept.

          • Inter-application copy-paste is provided by the terminal (usually with the mouse or key sequences such as Ctrl+Shift+V or Shift+Insert). The shell may have its own internal copy-paste mechanism as well (e.g. Meta+W and Ctrl+Y).


          • Job control (launching programs in the background and managing them) is mostly performed by the shell. However, it's the terminal that handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it.






          share|improve this answer















          A terminal is at the end of an electric wire, a shell is the home of a turtle, tty is a strange abbreviation and a console is a kind of cabinet.



          Well, etymologically speaking, anyway.



          In unix terminology, the short answer is that




          • terminal = tty = text input/output environment

          • console = physical terminal

          • shell = command line interpreter




          Console, terminal and tty are closely related. Originally, they meant a piece of equipment through which you could interact with a computer: in the early days of unix, that meant a teleprinter-style device resembling a typewriter, sometimes called a teletypewriter, or “tty” in shorthand. The name “terminal” came from the electronic point of view, and the name “console” from the furniture point of view. Very early in unix history, electronic keyboards and displays became the norm for terminals.



          In unix terminology, a tty is a particular kind of device file which implements a number of additional commands (ioctls) beyond read and write. In its most common meaning, terminal is synonymous with tty. Some ttys are provided by the kernel on behalf of a hardware device, for example with the input coming from the keyboard and the output going to a text mode screen, or with the input and output transmitted over a serial line. Other ttys, sometimes called pseudo-ttys, are provided (through a thin kernel layer) by programs called terminal emulators, such as Xterm (running in the X Window System), Screen (which provides a layer of isolation between a program and another terminal), Ssh (which connects a terminal on one machine with programs on another machine), Expect (for scripting terminal interactions), etc.



          The word terminal can also have a more traditional meaning of a device through which one interacts with a computer, typically with a keyboard and display. For example an X terminal is a kind of thin client, a special-purpose computer whose only purpose is to drive a keyboard, display, mouse and occasionally other human interaction peripherals, with the actual applications running on another, more powerful computer.



          A console is generally a terminal in the physical sense that is by some definition the primary terminal directly connected to a machine. The console appears to the operating system as a (kernel-implemented) tty. On some systems, such as Linux and FreeBSD, the console appears as several ttys (special key combinations switch between these ttys); just to confuse matters, the name given to each particular tty can be “console”, ”virtual console”, ”virtual terminal”, and other variations.



          See also Why is a Virtual Terminal “virtual”, and what/why/where is the “real” Terminal?.





          A shell is the primary interface that users see when they log in, whose primary purpose is to start other programs. (I don't know whether the original metaphor is that the shell is the home environment for the user, or that the shell is what other programs are running in.)



          In unix circles, shell has specialized to mean a command-line shell, centered around entering the name of the application one wants to start, followed by the names of files or other objects that the application should act on, and pressing the Enter key. Other types of environments don't use the word “shell”; for example, window systems involve “window managers” and “desktop environments”, not a “shell”.



          There are many different unix shells.
          Popular shells for interactive use include Bash (the default on most Linux installations), zsh (which emphasizes power and customizability) and fish (which emphasizes simplicity).



          Command-line shells include flow control constructs to combine commands. In addition to typing commands at an interactive prompt, users can write scripts. The most common shells have a common syntax based on the Bourne_shell. When discussing “shell programming”, the shell is almost always implied to be a Bourne-style shell. Some shells that are often used for scripting but lack advanced interactive features include the Korn shell (ksh) and many ash variants. Pretty much any Unix-like system has a Bourne-style shell installed as /bin/sh, usually ash, ksh or bash.



          In unix system administration, a user's shell is the program that is invoked when they log in. Normal user accounts have a command-line shell, but users with restricted access may have a restricted shell or some other specific command (e.g. for file-transfer-only accounts).





          The division of labor between the terminal and the shell is not completely obvious. Here are their main tasks.




          • Input: the terminal converts keys into control sequences (e.g. Lefte[D). The shell converts control sequences into commands (e.g. e[Dbackward-char).

          • Line editing, input history and completion are provided by the shell.


            • The terminal may provide its own line editing, history and completion instead, and only send a line to the shell when it's ready to be executed. The only common terminal that operates in this way is M-x shell in Emacs.



          • Output: the shell emits instructions such as “display foo”, “switch the foreground color to green”, “move the cursor to the next line”, etc. The terminal acts on these instructions.

          • The prompt is purely a shell concept.

          • The shell never sees the output of the commands it runs (unless redirected). Output history (scrollback) is purely a terminal concept.

          • Inter-application copy-paste is provided by the terminal (usually with the mouse or key sequences such as Ctrl+Shift+V or Shift+Insert). The shell may have its own internal copy-paste mechanism as well (e.g. Meta+W and Ctrl+Y).


          • Job control (launching programs in the background and managing them) is mostly performed by the shell. However, it's the terminal that handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 16 '17 at 14:06

























          answered Nov 16 '10 at 22:31









          GillesGilles

          542k12810961615




          542k12810961615








          • 47





            Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

            – Chris Johnsen
            Nov 17 '10 at 4:04






          • 12





            @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

            – Gilles
            Nov 17 '10 at 19:27








          • 23





            This is the image in my mind for the shell metaphor.

            – ændrük
            Dec 7 '10 at 19:00






          • 12





            There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

            – derobert
            Aug 29 '11 at 21:12








          • 19





            “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

            – Chris Page
            Mar 10 '12 at 20:34














          • 47





            Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

            – Chris Johnsen
            Nov 17 '10 at 4:04






          • 12





            @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

            – Gilles
            Nov 17 '10 at 19:27








          • 23





            This is the image in my mind for the shell metaphor.

            – ændrük
            Dec 7 '10 at 19:00






          • 12





            There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

            – derobert
            Aug 29 '11 at 21:12








          • 19





            “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

            – Chris Page
            Mar 10 '12 at 20:34








          47




          47





          Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

          – Chris Johnsen
          Nov 17 '10 at 4:04





          Only quibble: I would say that both kinds of ttys are “provided by” the kernel. The difference I would emphasize is that hardware ttys (e.g. serial lines and the built-in, text-mode console) have one end connected to hardware and one end connected to software (e.g. login programs and/or shells) while pseudo-ttys have both ends connected to software (e.g. a terminal emulator on one end and shell on the other).

          – Chris Johnsen
          Nov 17 '10 at 4:04




          12




          12





          @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

          – Gilles
          Nov 17 '10 at 19:27







          @phunehehe: Right, that's a different meaning of “shell”, in common use in operating system design: the shell is the outer part of the kernel. It's not unix terminology: Unix kernels don't tend to have a component that one could call a shell.

          – Gilles
          Nov 17 '10 at 19:27






          23




          23





          This is the image in my mind for the shell metaphor.

          – ændrük
          Dec 7 '10 at 19:00





          This is the image in my mind for the shell metaphor.

          – ændrük
          Dec 7 '10 at 19:00




          12




          12





          There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

          – derobert
          Aug 29 '11 at 21:12







          There is also another meaning of "console" under Linux. The console (there is only one) is where printk of sufficient priority goes (e.g., kernel panics). It is set by passing console=DEVICE,... on the kernel command line (e.g., console=ttyS0,115200 for a the first serial port, at 115,200 bps). Normally it defaults to the virtual-terminal, but that can be changed when the kernel is compiled.

          – derobert
          Aug 29 '11 at 21:12






          19




          19





          “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

          – Chris Page
          Mar 10 '12 at 20:34





          “…the terminal…handles key combinations like Ctrl+C to kill the foreground job and Ctrl+Z to suspend it” Not quite: the terminal still merely sends control characters, it’s the tty device that decides how to handle them, and it’s configurable. By default the tty device converts the control characters into signals sent to the shell (and other processes).

          – Chris Page
          Mar 10 '12 at 20:34













          187














          A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen.

          Nowadays nearly all terminals and consoles represent "virtual" ones.



          The file that represents a terminal is, traditionally, called a tty file. If you look under the "/dev" directory of a UNIX system, you'll find a lot of tty files connected to virtual consoles (e.g. tty1 on linux), virtual terminals (e.g. pts/0) or physically connected hardware (e.g. ttyS0 is the physical serial terminal, if any, attached on first serial port of the host).



          A console must be a piece of hardware physically connected to (or part of) the host. It has a special role in the system: it is the main point to access a system for maintenance and some special operation can be done only from a console (e.g. see single user mode). A terminal can be, and usually is, a remote piece of hardware.



          Last, but not the least, a shell is a special program that interacts with a user through a controlling tty and offers, to the user, the way of launching other programs (e.g. bash, csh, tcsh).



          A terminal emulator is a program that emulates a physical terminal (e.g. xterm, gnome-terminal, minicom).



          So when you look to a "text window" on your linux system (under X11) you are looking to: a terminal emulator, connected to a virtual terminal, identified by a tty file, inside which runs a shell.






          share|improve this answer





















          • 1





            Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

            – Incnis Mrsi
            Sep 6 '15 at 7:20













          • "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

            – Webwoman
            Sep 9 '18 at 11:45













          • @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

            – Motivated
            Jan 16 at 6:43











          • @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

            – Motivated
            Jan 16 at 6:45






          • 1





            @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

            – andcoz
            Jan 16 at 13:45
















          187














          A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen.

          Nowadays nearly all terminals and consoles represent "virtual" ones.



          The file that represents a terminal is, traditionally, called a tty file. If you look under the "/dev" directory of a UNIX system, you'll find a lot of tty files connected to virtual consoles (e.g. tty1 on linux), virtual terminals (e.g. pts/0) or physically connected hardware (e.g. ttyS0 is the physical serial terminal, if any, attached on first serial port of the host).



          A console must be a piece of hardware physically connected to (or part of) the host. It has a special role in the system: it is the main point to access a system for maintenance and some special operation can be done only from a console (e.g. see single user mode). A terminal can be, and usually is, a remote piece of hardware.



          Last, but not the least, a shell is a special program that interacts with a user through a controlling tty and offers, to the user, the way of launching other programs (e.g. bash, csh, tcsh).



          A terminal emulator is a program that emulates a physical terminal (e.g. xterm, gnome-terminal, minicom).



          So when you look to a "text window" on your linux system (under X11) you are looking to: a terminal emulator, connected to a virtual terminal, identified by a tty file, inside which runs a shell.






          share|improve this answer





















          • 1





            Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

            – Incnis Mrsi
            Sep 6 '15 at 7:20













          • "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

            – Webwoman
            Sep 9 '18 at 11:45













          • @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

            – Motivated
            Jan 16 at 6:43











          • @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

            – Motivated
            Jan 16 at 6:45






          • 1





            @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

            – andcoz
            Jan 16 at 13:45














          187












          187








          187







          A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen.

          Nowadays nearly all terminals and consoles represent "virtual" ones.



          The file that represents a terminal is, traditionally, called a tty file. If you look under the "/dev" directory of a UNIX system, you'll find a lot of tty files connected to virtual consoles (e.g. tty1 on linux), virtual terminals (e.g. pts/0) or physically connected hardware (e.g. ttyS0 is the physical serial terminal, if any, attached on first serial port of the host).



          A console must be a piece of hardware physically connected to (or part of) the host. It has a special role in the system: it is the main point to access a system for maintenance and some special operation can be done only from a console (e.g. see single user mode). A terminal can be, and usually is, a remote piece of hardware.



          Last, but not the least, a shell is a special program that interacts with a user through a controlling tty and offers, to the user, the way of launching other programs (e.g. bash, csh, tcsh).



          A terminal emulator is a program that emulates a physical terminal (e.g. xterm, gnome-terminal, minicom).



          So when you look to a "text window" on your linux system (under X11) you are looking to: a terminal emulator, connected to a virtual terminal, identified by a tty file, inside which runs a shell.






          share|improve this answer















          A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen.

          Nowadays nearly all terminals and consoles represent "virtual" ones.



          The file that represents a terminal is, traditionally, called a tty file. If you look under the "/dev" directory of a UNIX system, you'll find a lot of tty files connected to virtual consoles (e.g. tty1 on linux), virtual terminals (e.g. pts/0) or physically connected hardware (e.g. ttyS0 is the physical serial terminal, if any, attached on first serial port of the host).



          A console must be a piece of hardware physically connected to (or part of) the host. It has a special role in the system: it is the main point to access a system for maintenance and some special operation can be done only from a console (e.g. see single user mode). A terminal can be, and usually is, a remote piece of hardware.



          Last, but not the least, a shell is a special program that interacts with a user through a controlling tty and offers, to the user, the way of launching other programs (e.g. bash, csh, tcsh).



          A terminal emulator is a program that emulates a physical terminal (e.g. xterm, gnome-terminal, minicom).



          So when you look to a "text window" on your linux system (under X11) you are looking to: a terminal emulator, connected to a virtual terminal, identified by a tty file, inside which runs a shell.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Feb 21 '14 at 19:22









          crisron

          309315




          309315










          answered Nov 16 '10 at 21:53









          andcozandcoz

          12.8k33139




          12.8k33139








          • 1





            Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

            – Incnis Mrsi
            Sep 6 '15 at 7:20













          • "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

            – Webwoman
            Sep 9 '18 at 11:45













          • @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

            – Motivated
            Jan 16 at 6:43











          • @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

            – Motivated
            Jan 16 at 6:45






          • 1





            @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

            – andcoz
            Jan 16 at 13:45














          • 1





            Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

            – Incnis Mrsi
            Sep 6 '15 at 7:20













          • "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

            – Webwoman
            Sep 9 '18 at 11:45













          • @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

            – Motivated
            Jan 16 at 6:43











          • @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

            – Motivated
            Jan 16 at 6:45






          • 1





            @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

            – andcoz
            Jan 16 at 13:45








          1




          1





          Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

          – Incnis Mrsi
          Sep 6 '15 at 7:20







          Any desktop computer has system console (in my 2015 or poster’s 2010, don’t matter). As it was correctly stated, it’s a piece of hardware. But stating “Nowadays nearly all… consoles represent "virtual" ones” is nearly contradictory and obviously not good.

          – Incnis Mrsi
          Sep 6 '15 at 7:20















          "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

          – Webwoman
          Sep 9 '18 at 11:45







          "A terminal or a console is a piece of hardware, using which a user can interact with a host. Basically a keyboard coupled with a text screen." awesome explication by its concrete aspect

          – Webwoman
          Sep 9 '18 at 11:45















          @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

          – Motivated
          Jan 16 at 6:43





          @andcoz - What do you mean by "text window"? Isn't a terminal emulator a virtual terminal? If i run at the command tty in a terminal emulator such as KDE's Konsole, the output is /dev/pts/0.

          – Motivated
          Jan 16 at 6:43













          @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

          – Motivated
          Jan 16 at 6:45





          @IncnisMrsi - Isn't a desktop computer the console? If not, what do you mean by it has a system console?

          – Motivated
          Jan 16 at 6:45




          1




          1





          @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

          – andcoz
          Jan 16 at 13:45





          @Motivated /dev/pts/0 is a tty file, an handler to a programmatic interface exposed by the kernel. Through this handler, a program (e.g. the shell) can interact with a terminal (real or virtual). A terminal emulator is a software that emulates a terminal. The emulator asks the kernel to create an handler to let programs to interact with itself (see man openpty). So information flows from the terminal (emulator) to the kernel tty handler, to the program (and vice versa). Programs and terminals do not talk each other directly but only through the tty file (the handler).

          – andcoz
          Jan 16 at 13:45











          42














          SHORT explanation:



          The console is a terminal. A system has got one console and potentially multiple terminals. The console is typically the primary interface for managing a computer, eg while it is still booting up.



          A terminal is a session which can receive and send input and output for command-line programs. The console is a special case of these.



          A TTY is essentially a pseudo device, call it a kernel resource, which is used by processes to access a specific terminal. TTYs can be tied to hardware such as a serial port, or can be virtual, eg created when a user logs in via a network



          The shell is a program which is used for controlling and running programs. It is often used interactively, via a terminal. Several Shell programs exist, Bash being arguably the most commonly used shell today. Other shells, in no particular order, includes Bourne Shell, C-shell, Dash, Tsch, Ksh, and the increasingly popular zsh. There are many more.



          When you have a GUI, you can use a terminal program to draw a nice resizeable border, add scroll bars, and format the text, and so on, for a terminal session. Often these are called terminal emulators, and sometimes they can handle multiple sessions via a TAB concept. A Terminal Emulator often starts a Shell to allow you to interactively work on a command line.






          share|improve this answer





















          • 1





            PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

            – Luciano
            Jun 18 '15 at 21:23


















          42














          SHORT explanation:



          The console is a terminal. A system has got one console and potentially multiple terminals. The console is typically the primary interface for managing a computer, eg while it is still booting up.



          A terminal is a session which can receive and send input and output for command-line programs. The console is a special case of these.



          A TTY is essentially a pseudo device, call it a kernel resource, which is used by processes to access a specific terminal. TTYs can be tied to hardware such as a serial port, or can be virtual, eg created when a user logs in via a network



          The shell is a program which is used for controlling and running programs. It is often used interactively, via a terminal. Several Shell programs exist, Bash being arguably the most commonly used shell today. Other shells, in no particular order, includes Bourne Shell, C-shell, Dash, Tsch, Ksh, and the increasingly popular zsh. There are many more.



          When you have a GUI, you can use a terminal program to draw a nice resizeable border, add scroll bars, and format the text, and so on, for a terminal session. Often these are called terminal emulators, and sometimes they can handle multiple sessions via a TAB concept. A Terminal Emulator often starts a Shell to allow you to interactively work on a command line.






          share|improve this answer





















          • 1





            PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

            – Luciano
            Jun 18 '15 at 21:23
















          42












          42








          42







          SHORT explanation:



          The console is a terminal. A system has got one console and potentially multiple terminals. The console is typically the primary interface for managing a computer, eg while it is still booting up.



          A terminal is a session which can receive and send input and output for command-line programs. The console is a special case of these.



          A TTY is essentially a pseudo device, call it a kernel resource, which is used by processes to access a specific terminal. TTYs can be tied to hardware such as a serial port, or can be virtual, eg created when a user logs in via a network



          The shell is a program which is used for controlling and running programs. It is often used interactively, via a terminal. Several Shell programs exist, Bash being arguably the most commonly used shell today. Other shells, in no particular order, includes Bourne Shell, C-shell, Dash, Tsch, Ksh, and the increasingly popular zsh. There are many more.



          When you have a GUI, you can use a terminal program to draw a nice resizeable border, add scroll bars, and format the text, and so on, for a terminal session. Often these are called terminal emulators, and sometimes they can handle multiple sessions via a TAB concept. A Terminal Emulator often starts a Shell to allow you to interactively work on a command line.






          share|improve this answer















          SHORT explanation:



          The console is a terminal. A system has got one console and potentially multiple terminals. The console is typically the primary interface for managing a computer, eg while it is still booting up.



          A terminal is a session which can receive and send input and output for command-line programs. The console is a special case of these.



          A TTY is essentially a pseudo device, call it a kernel resource, which is used by processes to access a specific terminal. TTYs can be tied to hardware such as a serial port, or can be virtual, eg created when a user logs in via a network



          The shell is a program which is used for controlling and running programs. It is often used interactively, via a terminal. Several Shell programs exist, Bash being arguably the most commonly used shell today. Other shells, in no particular order, includes Bourne Shell, C-shell, Dash, Tsch, Ksh, and the increasingly popular zsh. There are many more.



          When you have a GUI, you can use a terminal program to draw a nice resizeable border, add scroll bars, and format the text, and so on, for a terminal session. Often these are called terminal emulators, and sometimes they can handle multiple sessions via a TAB concept. A Terminal Emulator often starts a Shell to allow you to interactively work on a command line.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited 39 mins ago









          Prajwal Dhatwalia

          1575




          1575










          answered Mar 19 '13 at 9:22









          JohanJohan

          2,76721829




          2,76721829








          • 1





            PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

            – Luciano
            Jun 18 '15 at 21:23
















          • 1





            PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

            – Luciano
            Jun 18 '15 at 21:23










          1




          1





          PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

          – Luciano
          Jun 18 '15 at 21:23







          PTY is a pseudo TTY. TTY can be, but ins't essentially virtual (either pseudo) terminal.

          – Luciano
          Jun 18 '15 at 21:23













          29














          A TTY (i.e. TeleTYpewriter) is a special device that lets people who are deaf, hard of hearing, or speech-impaired use the telephone to communicate, by allowing them to type text messages. A TTY is required at both ends of the conversation in order to communicate.

          OR
          TTY is terminal which is used to type text message.





          Shell :the outside protective covering part of a seed i.e. kernel.

          OR

          framework or exterior structure to central or essential part of a system.
          enter image description here





          Console means the keyboard and monitor physically attachements to a computer.






          share|improve this answer






























            29














            A TTY (i.e. TeleTYpewriter) is a special device that lets people who are deaf, hard of hearing, or speech-impaired use the telephone to communicate, by allowing them to type text messages. A TTY is required at both ends of the conversation in order to communicate.

            OR
            TTY is terminal which is used to type text message.





            Shell :the outside protective covering part of a seed i.e. kernel.

            OR

            framework or exterior structure to central or essential part of a system.
            enter image description here





            Console means the keyboard and monitor physically attachements to a computer.






            share|improve this answer




























              29












              29








              29







              A TTY (i.e. TeleTYpewriter) is a special device that lets people who are deaf, hard of hearing, or speech-impaired use the telephone to communicate, by allowing them to type text messages. A TTY is required at both ends of the conversation in order to communicate.

              OR
              TTY is terminal which is used to type text message.





              Shell :the outside protective covering part of a seed i.e. kernel.

              OR

              framework or exterior structure to central or essential part of a system.
              enter image description here





              Console means the keyboard and monitor physically attachements to a computer.






              share|improve this answer















              A TTY (i.e. TeleTYpewriter) is a special device that lets people who are deaf, hard of hearing, or speech-impaired use the telephone to communicate, by allowing them to type text messages. A TTY is required at both ends of the conversation in order to communicate.

              OR
              TTY is terminal which is used to type text message.





              Shell :the outside protective covering part of a seed i.e. kernel.

              OR

              framework or exterior structure to central or essential part of a system.
              enter image description here





              Console means the keyboard and monitor physically attachements to a computer.







              share|improve this answer














              share|improve this answer



              share|improve this answer








              edited Dec 20 '15 at 1:53

























              answered Dec 20 '15 at 1:44









              PremrajPremraj

              1,10011118




              1,10011118























                  24














                  There are already two great answers, but Ī̲’d like to add information about the phrase “virtual terminal”. Generally, it means something that provides appearance/functionality of a terminal, i. e. a terminal-emulator in broad sense. But in early days of Linux (1994–95) is was used synonymously with “virtual console” (several unrelated user interfaces), by some developers. This usage persists in documentation; two different terms were (and are) used to refer to tty1, tty2… thingies. Nowadays (since ≈ 1996) “virtual terminal” may also refer to pty-based terminal emulators.



                  Linux’s vt (the driver of text mode system console) was the first piece of its kernel. It was initially used for connection to mainframes and in this sense it’s a “virtual terminal”, hence the name. The code controlling virtual consoles resides in vt.c as well. Linux kernel engineers consistently use the word “consoles” to denote tty1, tty2… and used “vc_” prefix for them. For example, there is a vc_allocate function. On the other hand, developers of such user-space tools as kbd and console-tools used “virtual console” (VC) and “virtual terminal” (VT) interchangeably. Ī̲ contacted Andries E. Brouwer and asked him to clarify terminology used by early developers (1994–95). Andries kindly provided some answers. He states that VT and VC are synonymous and “indivisible” abbreviations.

                  -->
                  In general, a virtual console is a virtual terminal, but converse isn’t true. Those “virtual terminals” that are not virtual consoles are indeed pseudoterminals (as Andries states, these are not VT). Unlike virtual consoles, where the kernel provides terminal functionality for a console application, pseudoterminals use PTY “devices” to arrange communication between console applications and the terminal-making program that runs in userspace. Examples are X-based terminal emulators and sshd, that allocates a pseudotty for each login session. A pseudotty may not be called “console” – it’s a mistake.






                  share|improve this answer






























                    24














                    There are already two great answers, but Ī̲’d like to add information about the phrase “virtual terminal”. Generally, it means something that provides appearance/functionality of a terminal, i. e. a terminal-emulator in broad sense. But in early days of Linux (1994–95) is was used synonymously with “virtual console” (several unrelated user interfaces), by some developers. This usage persists in documentation; two different terms were (and are) used to refer to tty1, tty2… thingies. Nowadays (since ≈ 1996) “virtual terminal” may also refer to pty-based terminal emulators.



                    Linux’s vt (the driver of text mode system console) was the first piece of its kernel. It was initially used for connection to mainframes and in this sense it’s a “virtual terminal”, hence the name. The code controlling virtual consoles resides in vt.c as well. Linux kernel engineers consistently use the word “consoles” to denote tty1, tty2… and used “vc_” prefix for them. For example, there is a vc_allocate function. On the other hand, developers of such user-space tools as kbd and console-tools used “virtual console” (VC) and “virtual terminal” (VT) interchangeably. Ī̲ contacted Andries E. Brouwer and asked him to clarify terminology used by early developers (1994–95). Andries kindly provided some answers. He states that VT and VC are synonymous and “indivisible” abbreviations.

                    -->
                    In general, a virtual console is a virtual terminal, but converse isn’t true. Those “virtual terminals” that are not virtual consoles are indeed pseudoterminals (as Andries states, these are not VT). Unlike virtual consoles, where the kernel provides terminal functionality for a console application, pseudoterminals use PTY “devices” to arrange communication between console applications and the terminal-making program that runs in userspace. Examples are X-based terminal emulators and sshd, that allocates a pseudotty for each login session. A pseudotty may not be called “console” – it’s a mistake.






                    share|improve this answer




























                      24












                      24








                      24







                      There are already two great answers, but Ī̲’d like to add information about the phrase “virtual terminal”. Generally, it means something that provides appearance/functionality of a terminal, i. e. a terminal-emulator in broad sense. But in early days of Linux (1994–95) is was used synonymously with “virtual console” (several unrelated user interfaces), by some developers. This usage persists in documentation; two different terms were (and are) used to refer to tty1, tty2… thingies. Nowadays (since ≈ 1996) “virtual terminal” may also refer to pty-based terminal emulators.



                      Linux’s vt (the driver of text mode system console) was the first piece of its kernel. It was initially used for connection to mainframes and in this sense it’s a “virtual terminal”, hence the name. The code controlling virtual consoles resides in vt.c as well. Linux kernel engineers consistently use the word “consoles” to denote tty1, tty2… and used “vc_” prefix for them. For example, there is a vc_allocate function. On the other hand, developers of such user-space tools as kbd and console-tools used “virtual console” (VC) and “virtual terminal” (VT) interchangeably. Ī̲ contacted Andries E. Brouwer and asked him to clarify terminology used by early developers (1994–95). Andries kindly provided some answers. He states that VT and VC are synonymous and “indivisible” abbreviations.

                      -->
                      In general, a virtual console is a virtual terminal, but converse isn’t true. Those “virtual terminals” that are not virtual consoles are indeed pseudoterminals (as Andries states, these are not VT). Unlike virtual consoles, where the kernel provides terminal functionality for a console application, pseudoterminals use PTY “devices” to arrange communication between console applications and the terminal-making program that runs in userspace. Examples are X-based terminal emulators and sshd, that allocates a pseudotty for each login session. A pseudotty may not be called “console” – it’s a mistake.






                      share|improve this answer















                      There are already two great answers, but Ī̲’d like to add information about the phrase “virtual terminal”. Generally, it means something that provides appearance/functionality of a terminal, i. e. a terminal-emulator in broad sense. But in early days of Linux (1994–95) is was used synonymously with “virtual console” (several unrelated user interfaces), by some developers. This usage persists in documentation; two different terms were (and are) used to refer to tty1, tty2… thingies. Nowadays (since ≈ 1996) “virtual terminal” may also refer to pty-based terminal emulators.



                      Linux’s vt (the driver of text mode system console) was the first piece of its kernel. It was initially used for connection to mainframes and in this sense it’s a “virtual terminal”, hence the name. The code controlling virtual consoles resides in vt.c as well. Linux kernel engineers consistently use the word “consoles” to denote tty1, tty2… and used “vc_” prefix for them. For example, there is a vc_allocate function. On the other hand, developers of such user-space tools as kbd and console-tools used “virtual console” (VC) and “virtual terminal” (VT) interchangeably. Ī̲ contacted Andries E. Brouwer and asked him to clarify terminology used by early developers (1994–95). Andries kindly provided some answers. He states that VT and VC are synonymous and “indivisible” abbreviations.

                      -->
                      In general, a virtual console is a virtual terminal, but converse isn’t true. Those “virtual terminals” that are not virtual consoles are indeed pseudoterminals (as Andries states, these are not VT). Unlike virtual consoles, where the kernel provides terminal functionality for a console application, pseudoterminals use PTY “devices” to arrange communication between console applications and the terminal-making program that runs in userspace. Examples are X-based terminal emulators and sshd, that allocates a pseudotty for each login session. A pseudotty may not be called “console” – it’s a mistake.







                      share|improve this answer














                      share|improve this answer



                      share|improve this answer








                      edited Apr 13 '17 at 12:36









                      Community

                      1




                      1










                      answered Sep 7 '15 at 13:14









                      Incnis MrsiIncnis Mrsi

                      1,376923




                      1,376923























                          10















                          • Terminal = An interface that provides a display for output
                            and a key board for input to a shell session .


                          • Shell = Interpreter that executes commands typed as string



                          • Console: Actually two types of console we use




                            • Physical console=The hardware display and keyboard used to interact with a system


                            • Virtual console= One of multiple logical consoles that can each support an independent login session.




                          • tty(teletype ie terminal). = A terminal is a basically just a user interface device that uses text for input and output.message.







                          share|improve this answer


























                          • What is a tty ? -- otherwise, your answer is the only one I read

                            – loxaxs
                            Jul 2 '17 at 21:39


















                          10















                          • Terminal = An interface that provides a display for output
                            and a key board for input to a shell session .


                          • Shell = Interpreter that executes commands typed as string



                          • Console: Actually two types of console we use




                            • Physical console=The hardware display and keyboard used to interact with a system


                            • Virtual console= One of multiple logical consoles that can each support an independent login session.




                          • tty(teletype ie terminal). = A terminal is a basically just a user interface device that uses text for input and output.message.







                          share|improve this answer


























                          • What is a tty ? -- otherwise, your answer is the only one I read

                            – loxaxs
                            Jul 2 '17 at 21:39
















                          10












                          10








                          10








                          • Terminal = An interface that provides a display for output
                            and a key board for input to a shell session .


                          • Shell = Interpreter that executes commands typed as string



                          • Console: Actually two types of console we use




                            • Physical console=The hardware display and keyboard used to interact with a system


                            • Virtual console= One of multiple logical consoles that can each support an independent login session.




                          • tty(teletype ie terminal). = A terminal is a basically just a user interface device that uses text for input and output.message.







                          share|improve this answer
















                          • Terminal = An interface that provides a display for output
                            and a key board for input to a shell session .


                          • Shell = Interpreter that executes commands typed as string



                          • Console: Actually two types of console we use




                            • Physical console=The hardware display and keyboard used to interact with a system


                            • Virtual console= One of multiple logical consoles that can each support an independent login session.




                          • tty(teletype ie terminal). = A terminal is a basically just a user interface device that uses text for input and output.message.








                          share|improve this answer














                          share|improve this answer



                          share|improve this answer








                          edited Jul 3 '17 at 9:34

























                          answered Apr 12 '17 at 8:23









                          RakibRakib

                          999813




                          999813













                          • What is a tty ? -- otherwise, your answer is the only one I read

                            – loxaxs
                            Jul 2 '17 at 21:39





















                          • What is a tty ? -- otherwise, your answer is the only one I read

                            – loxaxs
                            Jul 2 '17 at 21:39



















                          What is a tty ? -- otherwise, your answer is the only one I read

                          – loxaxs
                          Jul 2 '17 at 21:39







                          What is a tty ? -- otherwise, your answer is the only one I read

                          – loxaxs
                          Jul 2 '17 at 21:39













                          5














                          You need to dive into history.



                          There were typewriter-like devices with paper and keyboard. They were called teletypes (which means "type remotely," since "tele" means "remote") or ttys for short. In the 70s they were obsoleted by devices with CRT monitor called glass ttys.



                          Any computer need some way to report its status and errors (and, probably, accept commands). It is done through console which is almost always connected directly to the computer. So, there are 2 meanings for console: something that is used to report status and something that is connected directly.



                          UNIX is an interactive system: several users may connect to it and start applications. First computers used teletypes (tty) for that: each user had teletype connected to machine with serial line connection. Such teletype is called terminal.
                          UNIX also got special subsystem to handle "users sitting behind terminals" which is also called tty because first terminals were teletypes.
                          Each process could be connected to tty in Unix. That means there is a user somewhere sitting near terminal. See http://www.linusakesson.net/programming/tty/ for more info.



                          Users need some way to tell kernel to run application. shell (sh, bash, csh, ksh, etc.) is used for that. shell runs on tty, accepts commands from user and asks kernel to run some app.



                          But terminals are not always physically connected to the machine. There may be some application that "emulates" terminal accepting keystrokes from user and sending them somewhere (xterm and ssh are good examples). There is an API in Kernel called pseudo terminal for that.
                          So your tty may really be connected to some application instead of real terminal. Xterm uses X11 to display text and ssh uses network connection for it.



                          IBM PC has keyboard and video card (they are also called console sometimes).
                          Linux can do different things with it:




                          • Use it as "engine to report errors and status": Linux console. If you pass console=/dev/ttyS0 to kernel it will use something connected to COM1 as console, and if you do not it will use PC console.

                          • Use it to emulate terminal, so called virtual terminal (vty).


                          It also may stop emulating terminal on console and give it to some app. App may switch its video mode and use it exclusively (X11 or svgalib may do that).



                          So, here are modern meanings:




                          • terminal: Something with real user sitting behind it. Could be physical terminal (rare) or pseudo terminal (xterm, ssh) or virtual terminal (vty in Linux)

                          • shell: application (bash, tcsh, etc) that helps user to interact with system.

                          • tty: either terminal or kernel subsystem to support terminals.

                          • console: something where status and errors are reported (/dev/console) or physical keyboard and video display connected to computer.






                          share|improve this answer






























                            5














                            You need to dive into history.



                            There were typewriter-like devices with paper and keyboard. They were called teletypes (which means "type remotely," since "tele" means "remote") or ttys for short. In the 70s they were obsoleted by devices with CRT monitor called glass ttys.



                            Any computer need some way to report its status and errors (and, probably, accept commands). It is done through console which is almost always connected directly to the computer. So, there are 2 meanings for console: something that is used to report status and something that is connected directly.



                            UNIX is an interactive system: several users may connect to it and start applications. First computers used teletypes (tty) for that: each user had teletype connected to machine with serial line connection. Such teletype is called terminal.
                            UNIX also got special subsystem to handle "users sitting behind terminals" which is also called tty because first terminals were teletypes.
                            Each process could be connected to tty in Unix. That means there is a user somewhere sitting near terminal. See http://www.linusakesson.net/programming/tty/ for more info.



                            Users need some way to tell kernel to run application. shell (sh, bash, csh, ksh, etc.) is used for that. shell runs on tty, accepts commands from user and asks kernel to run some app.



                            But terminals are not always physically connected to the machine. There may be some application that "emulates" terminal accepting keystrokes from user and sending them somewhere (xterm and ssh are good examples). There is an API in Kernel called pseudo terminal for that.
                            So your tty may really be connected to some application instead of real terminal. Xterm uses X11 to display text and ssh uses network connection for it.



                            IBM PC has keyboard and video card (they are also called console sometimes).
                            Linux can do different things with it:




                            • Use it as "engine to report errors and status": Linux console. If you pass console=/dev/ttyS0 to kernel it will use something connected to COM1 as console, and if you do not it will use PC console.

                            • Use it to emulate terminal, so called virtual terminal (vty).


                            It also may stop emulating terminal on console and give it to some app. App may switch its video mode and use it exclusively (X11 or svgalib may do that).



                            So, here are modern meanings:




                            • terminal: Something with real user sitting behind it. Could be physical terminal (rare) or pseudo terminal (xterm, ssh) or virtual terminal (vty in Linux)

                            • shell: application (bash, tcsh, etc) that helps user to interact with system.

                            • tty: either terminal or kernel subsystem to support terminals.

                            • console: something where status and errors are reported (/dev/console) or physical keyboard and video display connected to computer.






                            share|improve this answer




























                              5












                              5








                              5







                              You need to dive into history.



                              There were typewriter-like devices with paper and keyboard. They were called teletypes (which means "type remotely," since "tele" means "remote") or ttys for short. In the 70s they were obsoleted by devices with CRT monitor called glass ttys.



                              Any computer need some way to report its status and errors (and, probably, accept commands). It is done through console which is almost always connected directly to the computer. So, there are 2 meanings for console: something that is used to report status and something that is connected directly.



                              UNIX is an interactive system: several users may connect to it and start applications. First computers used teletypes (tty) for that: each user had teletype connected to machine with serial line connection. Such teletype is called terminal.
                              UNIX also got special subsystem to handle "users sitting behind terminals" which is also called tty because first terminals were teletypes.
                              Each process could be connected to tty in Unix. That means there is a user somewhere sitting near terminal. See http://www.linusakesson.net/programming/tty/ for more info.



                              Users need some way to tell kernel to run application. shell (sh, bash, csh, ksh, etc.) is used for that. shell runs on tty, accepts commands from user and asks kernel to run some app.



                              But terminals are not always physically connected to the machine. There may be some application that "emulates" terminal accepting keystrokes from user and sending them somewhere (xterm and ssh are good examples). There is an API in Kernel called pseudo terminal for that.
                              So your tty may really be connected to some application instead of real terminal. Xterm uses X11 to display text and ssh uses network connection for it.



                              IBM PC has keyboard and video card (they are also called console sometimes).
                              Linux can do different things with it:




                              • Use it as "engine to report errors and status": Linux console. If you pass console=/dev/ttyS0 to kernel it will use something connected to COM1 as console, and if you do not it will use PC console.

                              • Use it to emulate terminal, so called virtual terminal (vty).


                              It also may stop emulating terminal on console and give it to some app. App may switch its video mode and use it exclusively (X11 or svgalib may do that).



                              So, here are modern meanings:




                              • terminal: Something with real user sitting behind it. Could be physical terminal (rare) or pseudo terminal (xterm, ssh) or virtual terminal (vty in Linux)

                              • shell: application (bash, tcsh, etc) that helps user to interact with system.

                              • tty: either terminal or kernel subsystem to support terminals.

                              • console: something where status and errors are reported (/dev/console) or physical keyboard and video display connected to computer.






                              share|improve this answer















                              You need to dive into history.



                              There were typewriter-like devices with paper and keyboard. They were called teletypes (which means "type remotely," since "tele" means "remote") or ttys for short. In the 70s they were obsoleted by devices with CRT monitor called glass ttys.



                              Any computer need some way to report its status and errors (and, probably, accept commands). It is done through console which is almost always connected directly to the computer. So, there are 2 meanings for console: something that is used to report status and something that is connected directly.



                              UNIX is an interactive system: several users may connect to it and start applications. First computers used teletypes (tty) for that: each user had teletype connected to machine with serial line connection. Such teletype is called terminal.
                              UNIX also got special subsystem to handle "users sitting behind terminals" which is also called tty because first terminals were teletypes.
                              Each process could be connected to tty in Unix. That means there is a user somewhere sitting near terminal. See http://www.linusakesson.net/programming/tty/ for more info.



                              Users need some way to tell kernel to run application. shell (sh, bash, csh, ksh, etc.) is used for that. shell runs on tty, accepts commands from user and asks kernel to run some app.



                              But terminals are not always physically connected to the machine. There may be some application that "emulates" terminal accepting keystrokes from user and sending them somewhere (xterm and ssh are good examples). There is an API in Kernel called pseudo terminal for that.
                              So your tty may really be connected to some application instead of real terminal. Xterm uses X11 to display text and ssh uses network connection for it.



                              IBM PC has keyboard and video card (they are also called console sometimes).
                              Linux can do different things with it:




                              • Use it as "engine to report errors and status": Linux console. If you pass console=/dev/ttyS0 to kernel it will use something connected to COM1 as console, and if you do not it will use PC console.

                              • Use it to emulate terminal, so called virtual terminal (vty).


                              It also may stop emulating terminal on console and give it to some app. App may switch its video mode and use it exclusively (X11 or svgalib may do that).



                              So, here are modern meanings:




                              • terminal: Something with real user sitting behind it. Could be physical terminal (rare) or pseudo terminal (xterm, ssh) or virtual terminal (vty in Linux)

                              • shell: application (bash, tcsh, etc) that helps user to interact with system.

                              • tty: either terminal or kernel subsystem to support terminals.

                              • console: something where status and errors are reported (/dev/console) or physical keyboard and video display connected to computer.







                              share|improve this answer














                              share|improve this answer



                              share|improve this answer








                              edited Jul 8 '17 at 7:17









                              Scott

                              6,99152750




                              6,99152750










                              answered Jul 7 '17 at 18:33









                              user996142user996142

                              43739




                              43739























                                  3














                                  Here is the short answer -



                                  Kernel - the innermost part of any modern operating system which directly talks to actual hardware.



                                  Shell - wrapper around the actual Kernel. Whenever we run command, we actually talk to shell which in turn invokes appropriate Kernel instructions. Apart from this, the shell is capable of performing some other stuffs like finding appropriate program while having commands, some file name short hand, piping commands etc.



                                  Terminal - in the era of earlier computing, computers (known as Mainframe) were giant. So, it was easy to have a single processing unit and connect it from many places. Terminal is the actual hardware with keyboard and output devices connected to mainframe.



                                  Console - Special type of terminal which is directly connected to Mainframe for the purpose of OS Administration.



                                  tty - TeleTypewriter used to send and receive data to and from Mainframe. Used before Video Terminals were available. But conventionally it has been still named as tty. Even the coommand stty



                                  The long detailed answer is here - Terminal, Console, Shell, Kernel, Commands - Different parts of a Computer






                                  share|improve this answer


























                                  • thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                    – Webwoman
                                    Sep 9 '18 at 11:59


















                                  3














                                  Here is the short answer -



                                  Kernel - the innermost part of any modern operating system which directly talks to actual hardware.



                                  Shell - wrapper around the actual Kernel. Whenever we run command, we actually talk to shell which in turn invokes appropriate Kernel instructions. Apart from this, the shell is capable of performing some other stuffs like finding appropriate program while having commands, some file name short hand, piping commands etc.



                                  Terminal - in the era of earlier computing, computers (known as Mainframe) were giant. So, it was easy to have a single processing unit and connect it from many places. Terminal is the actual hardware with keyboard and output devices connected to mainframe.



                                  Console - Special type of terminal which is directly connected to Mainframe for the purpose of OS Administration.



                                  tty - TeleTypewriter used to send and receive data to and from Mainframe. Used before Video Terminals were available. But conventionally it has been still named as tty. Even the coommand stty



                                  The long detailed answer is here - Terminal, Console, Shell, Kernel, Commands - Different parts of a Computer






                                  share|improve this answer


























                                  • thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                    – Webwoman
                                    Sep 9 '18 at 11:59
















                                  3












                                  3








                                  3







                                  Here is the short answer -



                                  Kernel - the innermost part of any modern operating system which directly talks to actual hardware.



                                  Shell - wrapper around the actual Kernel. Whenever we run command, we actually talk to shell which in turn invokes appropriate Kernel instructions. Apart from this, the shell is capable of performing some other stuffs like finding appropriate program while having commands, some file name short hand, piping commands etc.



                                  Terminal - in the era of earlier computing, computers (known as Mainframe) were giant. So, it was easy to have a single processing unit and connect it from many places. Terminal is the actual hardware with keyboard and output devices connected to mainframe.



                                  Console - Special type of terminal which is directly connected to Mainframe for the purpose of OS Administration.



                                  tty - TeleTypewriter used to send and receive data to and from Mainframe. Used before Video Terminals were available. But conventionally it has been still named as tty. Even the coommand stty



                                  The long detailed answer is here - Terminal, Console, Shell, Kernel, Commands - Different parts of a Computer






                                  share|improve this answer















                                  Here is the short answer -



                                  Kernel - the innermost part of any modern operating system which directly talks to actual hardware.



                                  Shell - wrapper around the actual Kernel. Whenever we run command, we actually talk to shell which in turn invokes appropriate Kernel instructions. Apart from this, the shell is capable of performing some other stuffs like finding appropriate program while having commands, some file name short hand, piping commands etc.



                                  Terminal - in the era of earlier computing, computers (known as Mainframe) were giant. So, it was easy to have a single processing unit and connect it from many places. Terminal is the actual hardware with keyboard and output devices connected to mainframe.



                                  Console - Special type of terminal which is directly connected to Mainframe for the purpose of OS Administration.



                                  tty - TeleTypewriter used to send and receive data to and from Mainframe. Used before Video Terminals were available. But conventionally it has been still named as tty. Even the coommand stty



                                  The long detailed answer is here - Terminal, Console, Shell, Kernel, Commands - Different parts of a Computer







                                  share|improve this answer














                                  share|improve this answer



                                  share|improve this answer








                                  edited Jul 7 '17 at 18:01

























                                  answered Jul 7 '17 at 16:47









                                  Palash Kanti KunduPalash Kanti Kundu

                                  696




                                  696













                                  • thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                    – Webwoman
                                    Sep 9 '18 at 11:59





















                                  • thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                    – Webwoman
                                    Sep 9 '18 at 11:59



















                                  thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                  – Webwoman
                                  Sep 9 '18 at 11:59







                                  thanks but basically if the terminal exist, why exist still tty also in ubuntu system for personal computers, accessible with alt + f-1/6 please, I can't figure out their utility above the fact they can be accessed without graphics system usage if I have well understood

                                  – Webwoman
                                  Sep 9 '18 at 11:59













                                  2














                                  Apart from the accepted answer and The TTY demystified article, I really loved reading these two articles:



                                  This one is based on NetBSD.




                                  Back in the stone ages of Unix, computer systems consisted of a
                                  mainframe, a big box of blinking lights which had memory, mass storage
                                  and computing units, and that run processes started by users or
                                  operators. As the hardware was very expensive, the systems were used
                                  as true multiuser systems, with many people interacting with the
                                  system at the same time. What it usually didn't have - unlike today's
                                  Unix workstations - was a fixed monitor and keyboard. Instead, issuing
                                  commands to the machine and retrieving output was done over serial
                                  lines, using teletypers first, and CRT (cathode ray tube) terminals
                                  later. Teletypers - that's where the "ttys" in Unix come from - are
                                  electronic typewriters that send keys pressed over the serial line to
                                  the host, and replies were sent back to the teletyper char by char
                                  over the serial line, with the built-in printer putting the reply on
                                  paper, much like a typewriter.




                                  This one is based on Linux.




                                  Terminals are devices that provide enhanced input/output capabilities
                                  beyond what could be achieved with only regular files, pipes, and
                                  sockets. These features are designed to make it easier for humans to
                                  interact with computers, and are useless for programs trying to talk
                                  to each other.







                                  share|improve this answer




























                                    2














                                    Apart from the accepted answer and The TTY demystified article, I really loved reading these two articles:



                                    This one is based on NetBSD.




                                    Back in the stone ages of Unix, computer systems consisted of a
                                    mainframe, a big box of blinking lights which had memory, mass storage
                                    and computing units, and that run processes started by users or
                                    operators. As the hardware was very expensive, the systems were used
                                    as true multiuser systems, with many people interacting with the
                                    system at the same time. What it usually didn't have - unlike today's
                                    Unix workstations - was a fixed monitor and keyboard. Instead, issuing
                                    commands to the machine and retrieving output was done over serial
                                    lines, using teletypers first, and CRT (cathode ray tube) terminals
                                    later. Teletypers - that's where the "ttys" in Unix come from - are
                                    electronic typewriters that send keys pressed over the serial line to
                                    the host, and replies were sent back to the teletyper char by char
                                    over the serial line, with the built-in printer putting the reply on
                                    paper, much like a typewriter.




                                    This one is based on Linux.




                                    Terminals are devices that provide enhanced input/output capabilities
                                    beyond what could be achieved with only regular files, pipes, and
                                    sockets. These features are designed to make it easier for humans to
                                    interact with computers, and are useless for programs trying to talk
                                    to each other.







                                    share|improve this answer


























                                      2












                                      2








                                      2







                                      Apart from the accepted answer and The TTY demystified article, I really loved reading these two articles:



                                      This one is based on NetBSD.




                                      Back in the stone ages of Unix, computer systems consisted of a
                                      mainframe, a big box of blinking lights which had memory, mass storage
                                      and computing units, and that run processes started by users or
                                      operators. As the hardware was very expensive, the systems were used
                                      as true multiuser systems, with many people interacting with the
                                      system at the same time. What it usually didn't have - unlike today's
                                      Unix workstations - was a fixed monitor and keyboard. Instead, issuing
                                      commands to the machine and retrieving output was done over serial
                                      lines, using teletypers first, and CRT (cathode ray tube) terminals
                                      later. Teletypers - that's where the "ttys" in Unix come from - are
                                      electronic typewriters that send keys pressed over the serial line to
                                      the host, and replies were sent back to the teletyper char by char
                                      over the serial line, with the built-in printer putting the reply on
                                      paper, much like a typewriter.




                                      This one is based on Linux.




                                      Terminals are devices that provide enhanced input/output capabilities
                                      beyond what could be achieved with only regular files, pipes, and
                                      sockets. These features are designed to make it easier for humans to
                                      interact with computers, and are useless for programs trying to talk
                                      to each other.







                                      share|improve this answer













                                      Apart from the accepted answer and The TTY demystified article, I really loved reading these two articles:



                                      This one is based on NetBSD.




                                      Back in the stone ages of Unix, computer systems consisted of a
                                      mainframe, a big box of blinking lights which had memory, mass storage
                                      and computing units, and that run processes started by users or
                                      operators. As the hardware was very expensive, the systems were used
                                      as true multiuser systems, with many people interacting with the
                                      system at the same time. What it usually didn't have - unlike today's
                                      Unix workstations - was a fixed monitor and keyboard. Instead, issuing
                                      commands to the machine and retrieving output was done over serial
                                      lines, using teletypers first, and CRT (cathode ray tube) terminals
                                      later. Teletypers - that's where the "ttys" in Unix come from - are
                                      electronic typewriters that send keys pressed over the serial line to
                                      the host, and replies were sent back to the teletyper char by char
                                      over the serial line, with the built-in printer putting the reply on
                                      paper, much like a typewriter.




                                      This one is based on Linux.




                                      Terminals are devices that provide enhanced input/output capabilities
                                      beyond what could be achieved with only regular files, pipes, and
                                      sockets. These features are designed to make it easier for humans to
                                      interact with computers, and are useless for programs trying to talk
                                      to each other.








                                      share|improve this answer












                                      share|improve this answer



                                      share|improve this answer










                                      answered Dec 25 '18 at 20:10









                                      NishantNishant

                                      207110




                                      207110

















                                          protected by Anthon Jul 7 '17 at 22:02



                                          Thank you for your interest in this question.
                                          Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).



                                          Would you like to answer one of these unanswered questions instead?



                                          Popular posts from this blog

                                          Loup dans la culture

                                          How to solve the problem of ntp “Unable to contact time server” from KDE?

                                          ASUS Zenbook UX433/UX333 — Configure Touchpad-embedded numpad on Linux