Spring Sale Special - Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: mxmas70

Home > CompTIA > Linux+ > XK0-006

XK0-006 CompTIA Linux+ V8 Exam Question and Answers

Question # 4

A systems administrator manages multiple Linux servers and needs to set up a reliable and secure way to handle the complexity of managing event records on the OS and application levels. Which of the following should the administrator do?

A.

Create an automated process to retrieve logs from the server by demand.

B.

Implement a centralized log aggregation solution.

C.

Configure daily automatic backups of logs to remote storage.

D.

Deploy log rotation procedures to manage the records.

Full Access
Question # 5

A new drive was recently added to a Linux system. Using the environment and tokens provided, complete the following tasks:

• Create an appropriate device label.

• Format and create an ext4 file system on the new partition.

The current working directory is /.

Full Access
Question # 6

A user states that an NFS share Is reporting random disconnections. The systems administrator obtains the following information

Which of the following best explains the symptoms that are being reported?

A.

The mount point is incorrect for the NFS share.

B.

The IP address of the NFS share is incorrect.

C.

The filesystem is nearly full and is reporting errors.

D.

The interface is reporting a high number of errors and dropped packets.

Full Access
Question # 7

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?

A.

ps -f /data1

B.

du -sh /data1

C.

top -d /data1

D.

lsof | grep /data1

Full Access
Question # 8

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

A.

Fact

B.

Inventory

C.

Playbook

D.

Collection

Full Access
Question # 9

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

A.

USB ports

B.

Network speed

C.

Available swap

D.

CPU architecture

E.

Available memory

F.

Disk storage path

Full Access
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).

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

Full Access
Question # 11

A systems administrator is configuring new Linux systems and needs to enable passwordless authentication between two of the servers. Which of the following commands should the administrator use?

A.

ssh-keygen -t rsa && ssh-copy-id -i ~/.ssh/id_rsa.pub john@server2

B.

ssh-keyscan -t rsa && ssh-copy-id john@server2 -i ~/.ssh/key

C.

ssh-agent -i rsa && ssh-copy-id ~/.ssh/key john@server2

D.

ssh-add -t rsa && scp -rp ~/.ssh john@server2

Full Access
Question # 12

An administrator added a new disk to expand the current storage. Which of the following commands should the administrator run first to add the new disk to the LVM?

A.

vgextend

B.

lvextend

C.

pvcreate

D.

pvresize

Full Access
Question # 13

An administrator logs in to a Linux server and notices the clock is 37 minutes fast. Which of the following commands will fix the issue?

A.

hwclock

B.

ntpdate

C.

timedatectl

D.

ntpd -q

Full Access
Question # 14

A Linux administrator tries to install Ansible in a Linux environment. One of the steps is to change the owner and the group of the directory /opt/Ansible and its contents. Which of the following commands will accomplish this task?

A.

groupmod -g Ansible -n /opt/Ansible

B.

chown -R Ansible:Ansible /opt/Ansible

C.

usermod -aG Ansible /opt/Ansible

D.

chmod -c /opt/Ansible

Full Access
Question # 15

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?

A.

let ENABLE_AUTH=1

B.

ENABLE_AUTH=1

C.

ENABLE_AUTH=$(echo $ENABLE_AUTH)

D.

export ENABLE_AUTH=1

Full Access
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?

A.

lsscsi

B.

lsusb

C.

lsipc

D.

lshw

Full Access
Question # 17

A DevOps engineer made some changes to files in a local repository. The engineer realizes that the changes broke the application and the changes need to be reverted back. Which of the following commands is the best way to accomplish this task?

A.

git pull

B.

git reset

C.

git rebase

D.

git stash

Full Access
Question # 18

An administrator needs to remove the directory /home/user1/data and all of its contents. Which of the following commands should the administrator use?

A.

rmdir -p /home/user1/data

B.

ln -d /home/user1/data

C.

rm -r /home/user1/data

D.

cut -d /home/user1/data

Full Access
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?

A.

getent passwd accounting

B.

id accounting

C.

grep accounting /etc/shadow

D.

who accounting

Full Access
Question # 20

User1 reports "access denied" errors while trying to execute app. Given the following outputs:

Which of the following options will remediate this issue?

A.

Providing execute permissions to user1 in the ACL

B.

Modifying the permissions for others to grant read, write, and execute

C.

Adding user1 to the wheel group

D.

Moving app to a different folder

Full Access
Question # 21

Joe, a user, has taken a position previously held by Ann. As a systems administrator, you

need to archive all the files from Ann's home directory and extract them into Joe's home

directory.

INSTRUCTIONS

Within each tab, click on an object to form the appropriate commands. Command objects may only be used once, but the spacebar _ object may be used multiple times. Not all objects will be used.

If at any time you would like to bring back the initial state of the simulation, please click the Reset All button.

Full Access
Question # 22

Which of the following commands should an administrator use to convert a KVM disk file to a different format?

A.

qemu-kvm

B.

qemu-ng

C.

qemu-io

D.

qemu-img

Full Access
Question # 23

An administrator receives reports that a web service is not responding. The administrator reviews the following outputs:

Which of the following is the reason the web service is not responding?

A.

The private key needs to be renamed from server.crt to server, key so the service can find it.

B.

The private key does not match the public key, and both keys should be replaced.

C.

The private key is not in the correct location and needs to be moved to the correct directory.

D.

The private key has the incorrect permissions and should be changed to 0755 for the service.

Full Access
Question # 24

While hardening a system, an administrator runs a port scan with Nmap, which returned the following output:

Which of the following is the best way to address this security issue?

A.

Configuring a firewall to block traffic on port 23 on the server

B.

Changing the system administrator's password to prevent unauthorized access

C.

Closing port 80 on the network switch to block traffic

D.

Disabling and removing the Telnet service on the server

Full Access
Question # 25

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?

A.

less

B.

tail -f

C.

tr -c

D.

wc -l

Full Access
Question # 26

A junior system administrator removed an LVM volume by mistake.

INSTRUCTIONS

Part 1

Review the output and select the appropriate command to begin the recovery process.

Part 2

Review the output and select the appropriate command to continue the recovery process.

Part 3

Review the output and select the appropriate command to complete the recovery process and access the underlying data.

Full Access