Bird
0
0

Which of the following is the correct syntax to specify a custom port in an SSH config file?

easy📝 Syntax Q12 of 15
Linux CLI - SSH and Remote Access
Which of the following is the correct syntax to specify a custom port in an SSH config file?
APort: 2222
BSetPort 2222
Cport=2222
DPort 2222
Step-by-Step Solution
Solution:
  1. Step 1: Recall SSH config syntax rules

    SSH config uses keyword followed by a space and then the value, without colons or equals signs.
  2. Step 2: Check each option

    Port 2222 matches the correct syntax: Port 2222. Options A, C, and D use invalid syntax.
  3. Final Answer:

    Port 2222 -> Option D
  4. Quick Check:

    Keyword + space + value = correct syntax [OK]
Quick Trick: Use space, no colon or equals in SSH config lines [OK]
Common Mistakes:
  • Using colon after keyword
  • Using equals sign instead of space
  • Inventing keywords like SetPort

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Linux CLI Quizzes