Winter Sale - Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: top65certs

Free and Premium CompTIA XK0-006 Dumps Questions Answers

Page: 1 / 7
Total 87 questions

CompTIA Linux+ V8 Exam Questions and Answers

Question 1

A systems administrator is having issues with a third-party API endpoint. The administrator receives the following output:

Which of the following actions should the administrator take to resolve the issue?

Options:

A.

Open a secure port in the server's firewall.

B.

Request a new API endpoint from a third party.

C.

Review and fix the DNS client configuration file.

D.

Enable internet connectivity on the host.

Buy Now
Question 2

A systems administrator receives reports from users who are having issues while trying to modify newly created files in a shared directory. The administrator sees the following outputs:

Which of the following provides the best resolution to this issue?

Options:

A.

Adding a setuid bit to the user in the shared folder

B.

Manually changing the group of the newly created files

C.

Changing all directory contents to be writable and readable for everyone

D.

Adding a setgid bit to the group in the shared folder

Question 3

A systems administrator receives reports about connection issues to a secure web server. Given the following firewall and web server outputs:

Firewall output:

Status: active

To Action From

443/tcp DENY Anywhere

443/tcp (v6) DENY Anywhere (v6)

Web server output:

tcp LISTEN 0 4096 *:443 :

Which of the following commands best resolves this issue?

Options:

A.

ufw disable

B.

ufw allow 80/tcp

C.

ufw delete deny https/tcp

D.

ufw allow 4096/tcp

Question 4

Which of the following commands should a Linux administrator use to determine the version of a kernel module?

Options:

A.

modprobe bluetooth

B.

lsmod bluetooth

C.

depmod bluetooth

D.

modinfo bluetooth

Question 5

An administrator receives the following output while attempting to unmount a filesystem:

umount /data1: target is busy.

Which of the following commands should the administrator run next to determine why the filesystem is busy?

Options:

A.

ps -f /data1

B.

du -sh /data1

C.

top -d /data1

D.

lsof | grep /data1

Question 6

Which of the following is a characteristic of Python 3?

Options:

A.

It is closed source.

B.

It is extensible through modules.

C.

It is fully backwards compatible.

D.

It is binary compatible with Java.

Question 7

Which of the following best describes journald?

Options:

A.

A system service that collects and stores logging data

B.

A feature that creates crash dumps in case of kernel failure

C.

A service responsible for keeping the filesystem journal

D.

A service responsible for writing audit records to a disk

Question 8

Which of the following can reduce the attack surface area in relation to Linux hardening?

Options:

A.

Customizing the log-in banner

B.

Reducing the number of directories created

C.

Extending the SSH startup timeout period

D.

Enforcing password strength and complexity

Question 9

Which of the following is the main reason for setting up password expiry policies?

Options:

A.

To avoid using the same passwords repeatedly

B.

To mitigate the use of exposed passwords

C.

To force usage of passwordless authentication

D.

To increase password strength and complexity

Question 10

A technician wants to temporarily use a Linux virtual machine as a router for the network segment 10.10.204.0/24. Which of the following commands should the technician issue? (Select three).

Options:

A.

echo "1" > /proc/sys/net/ipv4/ip_forward

B.

iptables -A FORWARD -j ACCEPT

C.

iptables -A PREROUTING -j ACCEPT

D.

iptables -t nat -s 10.10.204.0/24 -p tcp -A PREROUTING -j MASQUERADE

E.

echo "0" > /proc/sys/net/ipv4/ip_forward

F.

echo "1" > /proc/net/tcp

G.

iptables -t nat -s 10.10.204.0/24 -A POSTROUTING -j MASQUERADE

Question 11

A Linux administrator wants to make the enable_auth variable set to 1 and available to the environment of subsequently executed commands. Which of the following should the administrator use for this task?

Options:

A.

let ENABLE_AUTH=1

B.

ENABLE_AUTH=1

C.

ENABLE_AUTH=$(echo $ENABLE_AUTH)

D.

export ENABLE_AUTH=1

Question 12

Which of the following Ansible components contains a list of hosts and host groups?

Options:

A.

Fact

B.

Inventory

C.

Playbook

D.

Collection

Question 13

Which of the following is a reason multiple password changes on the same day are not allowed?

Options:

A.

To avoid brute-forced password attacks by making them too long to perform

B.

To increase password complexity and the system's security

C.

To stop users from circulating through the password history to return to the originally used password

D.

To enforce using multifactor authentication with stronger encryption algorithms instead of passwords

Question 14

A Linux user frequently tests shell scripts located in the /home/user/scripts directory. Which of the following commands allows the user to run the program by invoking only the script name?

Options:

A.

export SHELL=$SHELL=/home/user/scripts

B.

export TERM=$TERM=/home/user/scripts

C.

export PATH=$PATH:/home/user/scripts

D.

export alias /home/user/scripts='/bin'

Question 15

A systems administrator is writing a script to analyze the number of files in the directory /opt/application/home/. Which of the following commands should the administrator use in conjunction with ls -l | to count the files?

Options:

A.

less

B.

tail -f

C.

tr -c

D.

wc -l

Question 16

A systems administrator needs to integrate a new storage array into the company's existing storage pool. The administrator wants to ensure that the server is able to detect the new storage array. Which of the following commands should the administrator use to ensure that the new storage array is presented to the systems?

Options:

A.

lsscsi

B.

lsusb

C.

lsipc

D.

lshw

Question 17

Users cannot access a server after it has been restarted. At the server console, the administrator runs the following commands;

Which of the following is the cause of the issue?

Options:

A.

The DNS entry does not have a valid IP address.

B.

The SSH service has not been allowed on the firewall.

C.

The server load average is too high.

D.

The wrong protocol is being used to connect to the web server.

Question 18

Which of the following utilities supports the automation of security compliance and vulnerability management?

Options:

A.

SELinux

B.

Nmap

C.

AIDE

D.

OpenSCAP

Question 19

An administrator needs to verify the user ID, home directory, and assigned shell for the user named "accounting." Which of the following commands should the administrator use to retrieve this information?

Options:

A.

getent passwd accounting

B.

id accounting

C.

grep accounting /etc/shadow

D.

who accounting

Question 20

To perform a live migration, which of the following must match on both host servers? (Choose two)

Options:

A.

USB ports

B.

Network speed

C.

Available swap

D.

CPU architecture

E.

Available memory

F.

Disk storage path

Question 21

An administrator wants to search a file named myFile and look for all occurrences of strings containing at least five characters, where characters two and five are i, but character three is not b. Which of the following commands should the administrator execute to get the intended result?

Options:

A.

grep .a*^b-.a myFile

B.

grep .a., [a] myFile

C.

grepa^b*a myFile

D.

grep .i[^b].i myFile

Question 22

A Linux administrator attempts to log in to a server over SSH as root and receives the following error message: Permission denied, please try again. The administrator is able to log in to the console of the server directly with root and confirms the password is correct. The administrator reviews the configuration of the SSH service and gets the following output:

Based on the above output, which of the following will most likely allow the administrator to log in over SSH to the server?

Options:

A.

Log out other user sessions because only one is allowed at a time.

B.

Enable PAM and configure the SSH module.

C.

Modify the SSH port to use 2222.

D.

Use a key to log in as root over SSH.

Question 23

A systems administrator wants to review the amount of time the NetworkManager service took to start. Which of the following commands accomplishes this goal?

Options:

A.

resolvectl

B.

journalctl

C.

systemctl daemon-reload

D.

systemd-analyze blame

Question 24

A Linux administrator needs to securely erase the contents of a hard disk. Which of the following commands is the best for this task?

Options:

A.

sudo rm -rf /dev/sda1

B.

sudo shred /dev/sda1

C.

sudo parted rm /dev/sda1

D.

sudo dd if=/dev/null of=/dev/sda1

Question 25

A Linux administrator is testing a web application on a laboratory service and needs to temporarily allow DNS and HTTP/HTTPS traffic from the internal network. Which of the following commands will accomplish this task?

Options:

A.

firewalld -- add-service=dns, http,https -- zone=internal

B.

iptables -- enable-service='dns|http|https' -- zone=internal

C.

firewall-cmd --add-service={dns, http, https} --zone=internal

D.

systemctl mask firewalld --for={dns, http, https} --zone=internal

Question 26

Which of the following describes how a user's public key is used during SSH authentication?

Options:

A.

The user's public key is used to hash the password during SSH authentication.

B.

The user's public key is verified against a list of authorized keys. If it is found, the user is allowed to log in.

C.

The user's public key is used instead of a password to allow server access.

D.

The user's public key is used to encrypt the communication between the client and the server.

Page: 1 / 7
Total 87 questions