XK0-005 · Question #505
A systems administrator created a web server for the company and is required to add a tag for the API so end users can connect. Which of the following would the administrator do to complete this…
The correct answer is C. hostnamectl set-hostname Comptia-WebNode -H [email protected]. The command hostnamectl set-hostname Comptia-WebNode -H [email protected] sets the hostname on the remote server at 192.168.2.14 as root via SSH. The -H (or --host) flag is used to operate on a remote machine, which is appropriate when the administrator is configuring a web…
Question
A systems administrator created a web server for the company and is required to add a tag for the API so end users can connect. Which of the following would the administrator do to complete this requirement?
Options
- Ahostnamectl status --no-ask-password
- Bhostnamectl set-hostname "$(perl -le "print" "A" x 86)"
- Chostnamectl set-hostname Comptia-WebNode -H [email protected]
- Dhostnamectl set-hostname Comptia-WebNode --transient
How the community answered
(22 responses)- B9% (2)
- C86% (19)
- D5% (1)
Explanation
The command hostnamectl set-hostname Comptia-WebNode -H [email protected] sets the hostname on the remote server at 192.168.2.14 as root via SSH. The -H (or --host) flag is used to operate on a remote machine, which is appropriate when the administrator is configuring a web server from a management workstation. Option A only displays status. Option B sets an absurdly long hostname (86 'A' characters), which is invalid. Option D uses --transient, which sets a non-persistent runtime hostname that will not survive a reboot.
Topics
Community Discussion
No community discussion yet for this question.