The character based display-interface between human and computer.

learn more… | top users | synonyms

382
votes
3answers
60k views

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

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?
41
votes
2answers
28k views

Linux: Difference between /dev/console , /dev/tty and /dev/tty0

On a Linux system, what is the difference between /dev/console , /dev/tty and /dev/tty0 ? What is their respective use? How do they compare?
29
votes
1answer
764 views

What happens when Ctrl + Alt + F<Num> is pressed?

I am looking for an explanation of what happens in Linux when this key combination is pressed to change the current terminal. In particular, what software component intercepts this key combination and ...
17
votes
2answers
10k views

How to colorize output of ls ?

I'm running CentOS in Linux text mode. When I run the command ls /usr/, the output is too hard to read (dark blue on black). How can I change the text coloring?
14
votes
5answers
8k views

How to clear terminal completely?

When we use clear command or Ctrl+L in terminal, it clears terminal but we can still scroll back to view the last used commands. Is there a way to completely clear the terminal?
14
votes
2answers
1k views

Can I configure bash to execute “clear” before every command typed in the console?

I would like to configure bash to execute clear command every time I type some command in the terminal (before executing my command). How can I do that? I'm using Debian Linux.
13
votes
4answers
611 views

Is there any reason why I get ^[[A when I press up arrow at the console login screen?

Whenever I'm at the console login, I press up arrow intentionally to see the previously typed commands. But I see this ^[[A. But when I press Ctrl Alt Print Screen Scroll Lock Pause Break Page Up ...
10
votes
7answers
12k views

Disable screen blanking on text console

I'm running linux clusters, mostly on SLES10. The servers are mostly blades, accessed via remote console. There is a real console in the server room, but switched off. I would like to disable the ...
10
votes
1answer
4k views

why there are six getty processes running on my desktop?

My desktop system is: $ uname -a Linux xmachine 3.0.0-13-generic #22-Ubuntu SMP Wed Nov 2 13:25:36 UTC 2011 i686 i686 i386 GNU/Linux By running ps a | grep getty, I get this output: 900 tty4 ...
10
votes
6answers
218 views

Options to show images when on the console

When I am on the console (the tty, the virtual terminal, which you reach with Ctrl+Alt+F1-6, not a terminal emulator), what options do I have to view images, tiff, whatever that's not text?
10
votes
1answer
3k views

TTY On External Monitor

When using my laptop at home, I usually use an external monitor, keyboard, and mouse with my laptop's screen as a second monitor. This is all easily configured using a nice GNOME utility that I ...
9
votes
2answers
3k views

What does raw/unraw keyboard mode mean?

In the magic sysrq key combinations, there is the combination alt+sysrq+r which, according to wikipedia, does the following: Switch the keyboard from raw mode, the mode used by programs such as ...
9
votes
1answer
524 views

Redirect linux console on boot

Is it possible on boot to redirect the console output to a screen session? The server has no monitor attached, and I'd like to be able to see the primary console output. I've seen other posts about ...
8
votes
4answers
5k views

How to get file to a host when all you have is a serial console?

When all you have is a serial console (say via telnet through a terminal server), what methods can be used to transfer files in/out of a host? Cut/paste works for the small/printable stuff and I've ...
8
votes
2answers
3k views

How to define a Compose Key in terminal (no desktop environment)?

I would like to define a compose key on my system (Debian Sid "Wheezy"). I have no Xorg (and don't want any desktop environment). Only in terminal. I would like to set it up on my Alt-Gr key (right ...
8
votes
1answer
1k views

Adjusting keyboard sensitivity in a command line terminal?

When using a tty login shell by entering Ctrl-Alt-F1 from an Ubuntu 12.04 install on a laptop the keyboard seems overly sensitive and if my finger lingers for a moment on a button I end up with ...
8
votes
1answer
25k views

How to set the resolution in text consoles (troubleshoot when any `vga=…` fails)

It is a common way to set the resolution of a text consoles (that are usually available by Ctrl-Alt-F1 thru Ctrl-Alt-F6) by using a vga=... kernel parameter. I'm using Ubuntu 10.04 Lucid, output of ...
8
votes
2answers
4k views

Viewing system console messages in GUI

Under Linux, is it possible to view error messages that show up on the text mode terminal while in GUI mode, instead of having to press Ctrl+Alt+F1 or Ctrl+Alt+F2 to view the messages every time and ...
7
votes
2answers
21k views

Command line to return to the GUI after Ctrl-Alt-F1?

I'm unable to return to the GUI with Ctrl-Alt-F7 (or any of the 12 function keys). I have some unsaved work and I don't want to lose them. Are there any other key combinations that will allow me to ...
7
votes
1answer
2k views

How to get fewer ttys with Systemd?

In the old days I just modified /etc/inittab. Now, with systemd, it seems to start tty[1-6] automatically, how should I disable tty[4-6]? Looks like there's only one systemd service file, and it use ...
7
votes
1answer
220 views

How do I prevent system information from being displayed on a terminal?

I'm working on a curses GUI that is supposed to start up automatically on boot-up in the default linux terminal (I have no X server installed). I have this working great, but I have a problem where ...
7
votes
1answer
158 views

Why do we need so many terminal emulator packages and what is their use?

This is something that has been so confusing to me for a long time. I am using Linux but I have gaps in my understanding of certain aspects and one is about the terminal. As I came to understand it ...
7
votes
2answers
542 views

How to map a console keyboard layout to a X keyboard layout in Linux

In my distribution (Slackware 13.37), the console keyboard layout is chosen among some of those available in /usr/share/kbd/keymaps ' sub directories, coming from the kbd package. Under X instead ...
6
votes
3answers
2k views

Shutdown from login prompt in tty

Suppose I boot a Linux machine without GUI. When it displays a tty login prompt, can I shutdown the machine with a keyboard sequence? Of course I could type in my username and password and then sudo ...
6
votes
2answers
574 views

Detect if running in a virtual terminal?

I'd like to autologin to tty1 on login and then use vlock to lock it. How can I detect from Bash if the current terminal is a console virtual terminal (e.g. tty1), so that I can put the vlock line ...
6
votes
2answers
4k views

How do I temporary change my keyboard layout on Debian? (no X)

How can I quickly change my keyboard layout between US and German? setxkbmap does not apply here, as I only have an SSH shell. Persistent changes via dpkg-reconfigure keyboard-configuration ...
6
votes
5answers
257 views

Is it possible to view media on the console?

I know the console (outside X11, e.g. /dev/tty1) works in text-mode, but I think if it is possible to play music using programs like cvlc and mplayer, it should be possible to view pictures and watch ...
6
votes
1answer
2k views

Show a notification across all running X displays

Using the command line, I'd like show a notification on every running X display. ( and running console ) Something like: notify-send-all 'Warning' 'Nuclear launch in 5 minutes, please evacuate' Is ...
6
votes
2answers
575 views

Font getting reset in virtual console on GNU/Linux

I have set a custom font on my virtual console (vt1) using the following command: shell> setfont ter-114f If I switch to X (using Ctrl+Alt+F7) and come back to the virtual console (using ...
6
votes
3answers
6k views

How do I connect a serial terminal to a KVM instance?

Perhaps I'm misunderstanding what KVM is capable of, but the ability to add/remove hardware on the VM seems to imply I can add a serial port that then acts as a terminal. So, my questions are: ...
6
votes
2answers
3k views

How to change cursor shape, color, and blinkrate of Linux Console?

I know I can change some fundamental settings of the Linux console, things like fonts, for instance, with dpkg-reconfigure console-setup. But I'd like to change things like blinkrate, color, and ...
6
votes
2answers
4k views

How to list console and kernel fonts?

I have a number of console fonts installed in /lib/kbd/consolefonts/ installed. How do I list them (obviously all I can do, is just look at the filenames, but not at a list at available fonts). How ...
6
votes
1answer
739 views

using curses with virtual terminals

I'm trying to use Curses on Fedora 12 to output status information to a virtual console (one of the terminals you can get to by pressing CtrlAltFx). When I start up my application on one of the ...
5
votes
3answers
1k views

How to log to file and to console

I know that I can log to file by adding > log.txt to the end of a command but how can I log to file AND to console?
5
votes
2answers
13k views

Refresh env variables after editing bashrc file

I frequently edited the .bashrc file to export new environment variables. Rather than close the console and start a new one to refresh the env variables, is there a convenient way to refresh?
5
votes
1answer
1k views

Fix terminal after displaying a binary file

I'd tried command cat with an executable file: cat /bin/ls Now I can't read any word in this terminal (Linux console). How can I fix it?
5
votes
3answers
523 views

Construct a command by putting a string into a tty

I managed to do this echo -n "command" > /dev/tty1 The letters appear, and the cursor moves, but they are "ghosts" - if you hit enter, nothing happens (they are not in stdin). Edit: In the ...
5
votes
2answers
971 views

Preventing access to TTY when X is killed

Assume I start an X server manually from a virtual console /dev/tty1 with xinit or startx, with the line id:3:initdefault: set in /etc/inittab. The X server gets run and put on another virtual ...
5
votes
2answers
2k views

Change colors in console/virtual terminal

Is there a way to alter all the available colors in console / virtual terminal? By console, I mean what you get after pressing CTRL + ALT + F1 and not anything like xterm or urxvt. So, I guess that ...
5
votes
1answer
122 views

Why are multiple command-line terminal consoles available/running at the same time on RHEL systems?

I'm studying for the RHCSA and am trying to wrap my mind around a seemingly basic concept: terminal consoles. I don't understand how/why RHEL systems make 6 terminal consoles (/dev/ttyN) available ...
5
votes
1answer
870 views

Tmux output is slower when vertical splits exist: why?

When I use Tmux and split the window into panes, I notice that programs are quite a bit slower to print out lines of text when there is vertical split (two panes side by side) than when there is a ...
5
votes
2answers
750 views

Can I start my main desktop graphical session remotely?

So my workstation at work got rebooted and I'm currently not logged in physically there with a graphical session. I have ssh access to it, and I can start a new X windows session and use my graphical ...
5
votes
1answer
988 views

Send a command from the console to a running X server

Is it possible to send a command from the console, say tty1, to the terminal currently occupied with X (in my case tty7 as I use Debian), to tell for example mplayer to play a movie? Edit - made a ...
5
votes
1answer
2k views

What is the difference between a Console, Shell, Terminal, Terminal emulator, Terminal multiplexer, and a Window manager?

For example. What is the difference between a default 'interface/console' of FreeBSD/archlinux, vs Terminal, vs Terminal emulator like Xterm, vs Terminal multiplexer like tmux, vs Window manager like ...
5
votes
2answers
190 views

Fully Disable PrntScr Key

I recently came across a Linux feature I have never seen before, where pressing the PrntScr button on the keyboard prints a physical piece of paper with the contents of my console. I really need to ...
5
votes
1answer
1k views

Read what is written to /dev/tty*

How can I read what is written to /dev/tty*(* = 0 - number of tty)? I tried sudo tail -f /dev/tty1 on one terminal(X) and then sudo cp .emacs /dev/tty1 from another. X didn't show the the content of ...
5
votes
1answer
2k views

Cannot switch to TTYs or back

I just upgraded to Mint 13 - KDE x64 I am unable to switch to ttys by using the CtrlAltF1 .. F6 keys. The gettys are running and I can switch to the terminals with the sudo chvt 1 command. I have ...
5
votes
1answer
465 views

Cannot switch to console anymore after using Alt_R as mod4

I'd like to use the right ALT key as 'mod4' (most notably because, by default, the 'awesome' window manager is using mod4 as a modifier for most WM commands and I like that idea a lot). However I've ...
5
votes
1answer
379 views

Console ScreenSaver without X11

I'm trying to setup a very slimmed down console only Debian system to act as a simple slideshow photo display. I know that it is possible to show graphics (I guess using the framebuffer) in the ...
5
votes
1answer
1k views

How do I configure setfont and loadkeys properly?

I'm installing LFS and I'm struggling with this section. My locale is sv_SE.UTF-8 and I have a Swedish keyboard. So I suppose I should enable unicode and that the keymap is sv-latin1: cat > ...