Appendix C The Command-Line Interface 227
THE OFFICIAL RASPBERRY PI BEGINNER’S GUIDE
This will end your command-line interface session and close the Terminal app.
Using the TTYs
The Terminal application isn’t the only way to use the command-line interface: you can also
switch to one of a number of already-running terminals known as the teletypes or TTYs. Hold
the CTRL and A LT keys on your keyboard and press the F2 key to switch to ‘tty2’.
You’ll need to log in again with your user name and password, after which you can use the
command-line interface just like in the Terminal. Using these TTYs is handy when, for whatever
reason, the main desktop interface isn’t working.
To switch away from the TTY, press and hold CTRL+ALT, then press F7: the desktop will
reappear. Press CTRL+ALT+F2 again and you’ll switch back to ‘tty2’ – and anything you were
running in it will still be there.
Before switching again, type:
exit
Then press CTRL+ALT+F7 to get back to the desktop. The reason for exiting before switching
away from the TTY is that anybody with access to the keyboard can switch to a TTY, and if you’re
still logged in they’ll be able to access your account without having to know your password!
Congratulations: you’ve taken your first steps in mastering the Raspbian
command-line interface!