Recall & Review
beginner
What is the purpose of the SSH config file?
The SSH config file simplifies connecting to remote servers by storing connection details like hostname, user, and port. It lets you use short names instead of full commands.
Click to reveal answer
beginner
Which file path is the default SSH config file for a user?
The default SSH config file for a user is
~/.ssh/config. It stores personal SSH connection settings.Click to reveal answer
beginner
What does the
Host keyword do in an SSH config file?The
Host keyword defines a shortcut name for a remote server. You use this name with the ssh command instead of typing the full hostname and options.Click to reveal answer
beginner
How do you specify a custom SSH port in the config file?
Use the
Port option under a Host entry to set a custom port number for SSH connections to that host.Click to reveal answer
beginner
Give an example of a simple SSH config entry for a server named 'myserver'.
Example:<br>
Host myserver HostName 192.168.1.10 User alice Port 2222This lets you connect by typing
ssh myserver.Click to reveal answer
Where is the SSH config file usually located for a user?
✗ Incorrect
The personal SSH config file is stored at ~/.ssh/config for each user.
What keyword starts a new host entry in the SSH config file?
✗ Incorrect
The 'Host' keyword defines a shortcut name for a server.
How do you specify the username for SSH in the config file?
✗ Incorrect
The 'User' option sets the username for the SSH connection.
If your SSH server listens on port 2222, how do you set this in the config file?
✗ Incorrect
Use 'Port 2222' under the host entry to specify the custom port.
What command lets you connect using the shortcut name defined in the SSH config file?
✗ Incorrect
Simply use 'ssh shortcut' to connect using the config file alias.
Explain how an SSH config file can make connecting to servers easier.
Think about how you avoid typing long commands every time.
You got /5 concepts.
Describe the structure of a basic SSH config file entry.
What keywords and values do you write for each server?
You got /5 concepts.