Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

31
  • 70
    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). Commented Nov 17, 2010 at 4:04
  • 14
    @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. Commented Nov 17, 2010 at 19:27
  • 29
    This is the image in my mind for the shell metaphor.
    – ændrük
    Commented Dec 7, 2010 at 19:00
  • 17
    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
    Commented Aug 29, 2011 at 21:12
  • 30
    “…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
    Commented Mar 10, 2012 at 20:34