Exam4Training

CompTIA XK0-005 CompTIA Linux+ Exam Online Training

Question #1

A junior administrator is setting up a new Linux server that is intended to be used as a router at a remote site.

Which of the following parameters will accomplish this goal?

A)

B)

C)

D)

  • A . Option A
  • B . Option B
  • C . Option C
  • D . Option D

Reveal Solution Hide Solution

Correct Answer: A
Question #2

An administrator transferred a key for SSH authentication to a home directory on a remote server. The key file was moved to .ssh/authorized_keys location in order to establish SSH connection without a password. However, the SSH command still asked for the password.

Given the following output:

Which of the following commands would resolve the issue?

  • A . restorecon .ssh/authorized_keys
  • B . ssh_keygen -t rsa -o .ssh/authorized_keys
  • C . chown root:root .ssh/authorized_keys
  • D . chmod 600 .ssh/authorized_keys

Reveal Solution Hide Solution

Correct Answer: A
Question #3

A Linux administrator is tasked with creating resources using containerization. When deciding how to create this type of deployment, the administrator identifies some key features, including portability, high availability, and scalability in production.

Which of the following should the Linux administrator choose for the new design?

  • A . Docker
  • B . On-premises systems
  • C . Cloud-based systems
  • D . Kubernetes

Reveal Solution Hide Solution

Correct Answer: D
Question #4

A Linux administrator was notified that a virtual server has an I/O bottleneck.

The Linux administrator analyzes the following output:

Given there is a single CPU in the sever, which of the following is causing the slowness?

  • A . The system is running out of swap space.
  • B . The CPU is overloaded.
  • C . The memory is exhausted.
  • D . The processes are paging.

Reveal Solution Hide Solution

Correct Answer: B
Question #5

A Linux engineer receives reports that files created within a certain group are being modified by users who are not group members. The engineer wants to reconfigure the server so that only file owners and group members can modify new files by default.

Which of the following commands would accomplish this task?

  • A . chmod 775
  • B . umask. 002
  • C . chactr -Rv
  • D . chown -cf

Reveal Solution Hide Solution

Correct Answer: B
Question #6

The security team has identified a web service that is running with elevated privileges A Linux administrator is working to change the systemd service file to meet security compliance standards.

Given the following output:

Which of the following remediation steps will prevent the web service from running as a privileged user?

  • A . Removing the ExecStarWusr/sbin/webserver -D SOPTIONS from the service file
  • B . Updating the Environment File line in the [Service] section to/home/webservice/config
  • C . Adding the User-webservice to the [Service] section of the service file
  • D . Changing the:nulti-user.target in the [Install] section to basic.target

Reveal Solution Hide Solution

Correct Answer: A
Question #7

Which of the following commands will display the operating system?

  • A . uname -n
  • B . uname -s
  • C . uname -o
  • D . uname -m

Reveal Solution Hide Solution

Correct Answer: C
Question #8

An administrator accidentally deleted the /boot/vmlinuz file and must resolve the issue before the server is rebooted.

Which of the following commands should the administrator use to identify the correct

version of this file?

  • A . rpm -qa | grep kernel; uname -a
  • B . yum -y update; shutdown -r now
  • C . cat /etc/centos-release; rpm -Uvh –nodeps
  • D . telinit 1; restorecon -Rv /boot

Reveal Solution Hide Solution

Correct Answer: A
Question #9

A systems administrator created a new Docker image called test. After building the image, the administrator forgot to version the release.

Which of the following will allow the administrator to assign the v1 version to the image?

  • A . docker image save test test:v1
  • B . docker image build test:vl
  • C . docker image tag test test:vl
  • D . docker image version test:v1

Reveal Solution Hide Solution

Correct Answer: C
Question #10

Users have been unable to reach www.comptia.org from a Linux server.

A systems administrator is troubleshooting the issue and does the following:

Based on the information above, which of the following is causing the issue?

  • A . The name www.comptia.org does not point to a valid IP address.
  • B . The server 192.168.168.53 is unreachable.
  • C . No default route is set on the server.
  • D . The network interface eth0 is disconnected.

Reveal Solution Hide Solution

Correct Answer: C

Question #11

What is the main objective when using Application Control?

  • A . To filter out specific content.
  • B . To assist the firewall blade with handling traffic.
  • C . To see what users are doing.
  • D . Ensure security and privacy of information.

Reveal Solution Hide Solution

Correct Answer: C
Question #12

A Linux administrator has logged in to a server for the first time and needs to know which services are allowed through the firewall.

Which of the following options will return the results for which the administrator is looking?

  • A . firewall-cmd ―get-services
  • B . firewall-cmd ―check-config
  • C . firewall-cmd ―list-services
  • D . systemctl status firewalld

Reveal Solution Hide Solution

Correct Answer: C
Question #13

A Linux administrator needs to create an image named sda.img from the sda disk and store it in the /tmp directory.

Which of the following commands should be used to accomplish this task?

  • A . dd of=/dev/sda if=/tmp/sda.img
  • B . dd if=/dev/sda of=/tmp/sda.img
  • C . dd –if=/dev/sda –of=/tmp/sda.img
  • D . dd –of=/dev/sda –if=/tmp/sda.img

Reveal Solution Hide Solution

Correct Answer: B
Question #14

A systems administrator is tasked with creating a cloud-based server with a public IP address.

Which of the following technologies did the systems administrator use to complete this task?

  • A . Puppet
  • B . Git
  • C . Ansible
  • D . Terraform

Reveal Solution Hide Solution

Correct Answer: D
Question #15

A Linux administrator needs to analyze a failing application that is running inside a container.

Which of the following commands allows the Linux administrator to enter the running container and analyze the logs that are stored inside?

  • A . docker run -ti app /bin/sh
  • B . podman exec -ti app /bin/sh
  • C . podman run -d app /bin/bash
  • D . docker exec -d app /bin/bash

Reveal Solution Hide Solution

Correct Answer: B
Exit mobile version