Labour Day Special Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: netbudy65

XK0-005 CompTIA Linux+ Exam Questions and Answers

Questions 4

A Linux administrator is creating a new sudo profile for the accounting user. Which of the following should be added by the administrator to the sudo

configuration file so that the accounting user can run / opt/ acc/ report as root?

Options:

A.

accounting localhost=/opt/acc/report

B.

accounting ALL=/opt/acc/report

C.

%accounting ALL=(ALL) NOPASSWD: /opt/acc/report

D.

accounting /opt/acc/report= (ALL) NOPASSWD: ALL

Buy Now
Questions 5

A network administrator issues the dig ww. comptia. org command and receives an NXDOMAIN response. Which of the following files should the administrator check first?

Options:

A.

/etc/resolv.conf

B.

/etc/hosts

C.

/etc/sysconfig/network-scripts

D.

/etc/nsswitch.conf

Buy Now
Questions 6

An administrator needs to increase the system priority of a process with PID 2274. Which of the following commands should the administrator use to

accomplish this task?

Options:

A.

renice —n —15 2274

B.

nice -15 2274

C.

echo "—15" > /proc/PID/2274/priority

D.

ps —ef I grep 2274

Buy Now
Questions 7

A systems administrator needs to reconfigure a Linux server to allow persistent IPv4 packet forwarding. Which of the following commands is the correct way to accomplish this task?

Options:

A.

echo 1 > /proc/sys/net/ipv4/ipv_forward

B.

sysctl -w net.ipv4.ip_forward=1

C.

firewall-cmd --enable ipv4_forwarding

D.

systemct1 start ipv4_forwarding

Buy Now
Questions 8

A systems administrator is investigating a service that is not starting up. Given the following information:

Which of the following systemd commands should the administrator use in order to obtain more details about the failing service?

Options:

A.

systemct1 analyze network

B.

systemct1 info network

C.

sysctl -a network

D.

journalctl -xu network

Buy Now
Questions 9

Which of the following should be used to verify the integrity of a file?

Options:

A.

sha256sum

B.

fsck

C.

gpg —d

D.

hashcat

Buy Now
Questions 10

A Linux administrator needs to resolve a service that has failed to start. The administrator runs the following command:

The following output is returned

Which of the following is MOST likely the issue?

Options:

A.

The service does not have permissions to read write the startupfile.

B.

The service startupfile size cannot be 81k.

C.

The service startupfile cannot be owned by root.

D.

The service startupfile should not be owned by the root group.

Buy Now
Questions 11

A Linux administrator is installing a web server and needs to check whether web traffic has already been allowed through the firewall. Which of the following commands should the administrator use to accomplish this task?

Options:

A.

firewalld query-service-http

B.

firewall-cmd --check-service http

C.

firewall-cmd --query-service http

D.

firewalld --check-service http

Buy Now
Questions 12

Which of the following directories is the mount point in a UEFI system?

Options:

A.

/sys/efi

B.

/boot/efi

C.

/efi

D.

/etc/efi

Buy Now
Questions 13

A cloud engineer needs to block the IP address 192.168.10.50 from accessing a Linux server. Which of the following commands will achieve this goal?

Options:

A.

iptables -F INPUT -j 192.168.10.50 -m DROP

B.

iptables -A INPUT -s 192.168.10.30 -j DROP

C.

iptables -i INPUT --ipv4 192.168.10.50 -z DROP

D.

iptables -j INPUT 192.168.10.50 -p DROP

Buy Now
Questions 14

Users are reporting that writes on a system configured with SSD drives have been taking longer than expected, but reads do not seem to be affected. A Linux systems administrator is investigating this issue and working on a solution. Which of the following should the administrator do to help solve the issue?

Options:

A.

Run the corresponding command to trim the SSD drives.

B.

Use fsck on the filesystem hosted on the SSD drives.

C.

Migrate to high-density SSD drives for increased performance.

D.

Reduce the amount of files on the SSD drives.

Buy Now
Questions 15

Which of the following would significantly help to reduce data loss if more than one drive fails at the same time?

Options:

A.

Server clustering

B.

Load balancing

C.

RAID

D.

VDI

Buy Now
Questions 16

A DevOps engineer wants to allow the same Kubernetes container configurations to be deployed in development, testing, and production environments. A key requirement is that the containers should be configured so that developers do not have to statically configure custom, environment-specific locations. Which of the following should the engineer use to meet this requirement?

Options:

A.

Custom scheduler

B.

Node affinity

C.

Overlay network

D.

Ambassador container

Buy Now
Questions 17

A systems administrator wants to check for running containers. Which of the following commands can be used to show this information?

Options:

A.

docker pull

B.

docker stats

C.

docker ps

D.

docker list

Buy Now
Questions 18

A systems administrator is compiling a report containing information about processes that are listening on the network ports of a Linux server. Which of the following commands will allow the administrator to obtain the needed information?

Options:

A.

ss -pint

B.

tcpdump -nL

C.

netstat -pn

D.

lsof -It

Buy Now
Questions 19

A Linux administrator needs to create a new user named user02. However, user02 must be in a different home directory, which is under /comptia/projects. Which of the following commands will accomplish this task?

Options:

A.

useradd -d /comptia/projects user02

B.

useradd -m /comptia/projects user02

C.

useradd -b /comptia/projects user02

D.

useradd -s /comptia/projects user02

Buy Now
Questions 20

While troubleshooting server issues, a Linux systems administrator obtains the following output:

[rootGhost ~]# totalfree -m usedfreesharedbuf f/cache available

Mem:373635988824829

Swap:20471824223

Which of the following best describes the state of the system?

Options:

A.

The system has consumed the system memory and swap space.

B.

The system has enough free memory space.

C.

The system has swap disabled.

D.

The system has allocated enough buffer space.

Buy Now
Questions 21

A Linux administrator is creating a primary partition on the replacement hard drive for an application server. Which of the following commands should the administrator issue to verify the device name of this partition?

Options:

A.

sudo fdisk /dev/sda

B.

sudo fdisk -s /dev/sda

C.

sudo fdisk -l

D.

sudo fdisk -h

Buy Now
Questions 22

As part of the requirements for installing a new application, the swappiness parameter needs to be changed to O. This change needs to persist across re-boots and be applied immediately. A Linux systems administrator is performing this change. Which of the following steps should the administrator complete to accomplish this task?

Options:

A.

echo "vm. swappiness—()" >> /etc/sysctl . conf && sysctl —p

B.

echo "vrn. >> / proc/meminfo && sysctl —a

C.

sysctl —v >> / proc/meminfo & & echo "vm. swapiness=0"

D.

sysctl —h "vm. swapiness—O" && echo / etc/vmswapiness

Buy Now
Questions 23

A systems administrator needs to clone the partition /dev/sdc1 to /dev/sdd1. Which of the following commands will accomplish this task?

Options:

A.

tar -cvzf /dev/sdd1 /dev/sdc1

B.

rsync /dev/sdc1 /dev/sdd1

C.

dd if=/dev/sdc1 of=/dev/sdd1

D.

scp /dev/sdc1 /dev/sdd1

Buy Now
Questions 24

A systems administrator is deploying three identical, cloud-based servers. The administrator is using the following code to complete the task:

Which of the following technologies is the administrator using?

Options:

A.

Ansible

B.

Puppet

C.

Chef

D.

Terraform

Buy Now
Questions 25

An administrator recently updated the BIND software package and would like to review the default configuration that shipped with this version. Which of the following files should the administrator review?

Options:

A.

/etc/named.conf.rpmnew

B.

/etc/named.conf.rpmsave

C.

/etc/named.conf

D.

/etc/bind/bind.conf

Buy Now
Questions 26

Which of the following is a function of a bootloader?

Options:

A.

It initializes all the devices that are required to load the OS.

B.

It mounts the root filesystem that is required to load the OS.

C.

It helps to load the different kernels to initiate the OS startup process.

D.

It triggers the start of all the system services.

Buy Now
Questions 27

A Linux administrator wants to prevent the httpd web service from being started both manually and automatically on a server. Which of the following should the administrator use to accomplish this task?

Options:

A.

systemctl mask httpd

B.

systemctl disable httpd

C.

systemctl stop httpd

D.

systemctl reload httpd

Buy Now
Questions 28

A Linux administrator is trying to remove the ACL from the file /home/user/data. txt but receives the following error message:

Given the following analysis:

Which of the following is causing the error message?

Options:

A.

The administrator is not using a highly privileged account.

B.

The filesystem is mounted with the wrong options.

C.

SELinux file context is denying the ACL changes.

D.

File attributes are preventing file modification.

Buy Now
Questions 29

A Linux administrator copied a Git repository locally, created a feature branch, and committed some changes to the feature branch. Which of the following Git actions should the Linux administrator use to publish the changes to the main branch of the remote repository?

Options:

A.

rebase

B.

tag

C.

commit

D.

push

Buy Now
Questions 30

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?

Options:

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

Buy Now
Questions 31

A Linux administrator needs to create a new cloud.cpio archive containing all the files from the current directory. Which of the following commands can help to accomplish this task?

Options:

A.

ls | cpio -iv > cloud.epio

B.

ls | cpio -iv < cloud.epio

C.

ls | cpio -ov > cloud.cpio

D.

ls cpio -ov < cloud.cpio

Buy Now
Questions 32

A new application container was built with an incorrect version number. Which of the following commands should be used to rename the image to match the correct version 2.1.2?

Options:

A.

docker tag comptia/app:2.1.1 comptia/app:2.1.2

B.

docker push comptia/app:2.1.1 comptia/app:2.1.2

C.

docker rmi comptia/app:2.1.1 comptia/app:2.1.2

D.

docker update comptia/app:2.1.1 comptia/app:2.1.2

Buy Now
Questions 33

A systems administrator is notified that the mysqld process stopped unexpectedly. The systems administrator issues the following command:

sudo grep –i -r ‘out of memory’ /var/log

The output of the command shows the following:

kernel: Out of memory: Kill process 9112 (mysqld) score 511 or sacrifice child.

Which of the following commands should the systems administrator execute NEXT to troubleshoot this issue? (Select two).

Options:

A.

free -h

B.

nc -v 127.0.0.1 3306

C.

renice -15 $( pidof mysql )

D.

lsblk

E.

killall -15

F.

vmstat -a 1 4

Buy Now
Questions 34

A systems administrator wants to be sure the sudo rules just added to /etc/sudoers are valid. Which of the following commands can be used for this task?

Options:

A.

visudo -c

B.

test -f /etc/sudoers

C.

sudo vi check

D.

cat /etc/sudoers | tee test

Buy Now
Questions 35

Which of the following technologies provides load balancing, encryption, and observability in containerized environments?

Options:

A.

Virtual private network

B.

Sidecar pod

C.

Overlay network

D.

Service mesh

Buy Now
Questions 36

A DevOps engineer is working on a local copy of a Git repository. The engineer would like to switch from the main branch to the staging branch but notices the staging branch does not exist. Which of the following Git commands should the engineer use to perform this task?

Options:

A.

git branch —m staging

B.

git commit —m staging

C.

git status —b staging

D.

git checkout —b staging

Buy Now
Questions 37

Users have been unable to save documents to /home/tmp/temp and have been receiving the following error:

Path not found

A junior technician checks the locations and sees that /home/tmp/tempa was accidentally created instead of /home/tmp/temp. Which of the following commands should the technician use to fix this issue?

Options:

A.

cp /home/tmp/tempa /home/tmp/temp

B.

mv /home/tmp/tempa /home/tmp/temp

C.

cd /temp/tmp/tempa

D.

ls /home/tmp/tempa

Buy Now
Questions 38

An administrator would like to mirror the website files on the primary web server, www1, to the backup web server, www2. Which of the following commands

should the administrator use to most efficiently accomplish this task?

Options:

A.

[wwwl ] rsync —a —e ssh /var/www/html/ user1@www2 : /var/www/html

B.

[ wwwl ] scp —r /var/www/html user1@www2 : / var/www/html

C.

[www2 ] cd /var/www/html; wget —m http: //wwwl/

D.

[wwwl ] cd /var/www/html && tar cvf —

Buy Now
Questions 39

After installing a new version of a package, a systems administrator notices a new version of the corresponding, service file was Installed In order to use the new version of the, service file, which of the following commands must be Issued FIRST?

Options:

A.

systemct1 status

B.

systemct1 stop

C.

systemct1 reinstall

D.

systemct1 daemon-reload

Buy Now
Questions 40

An administrator attempts to rename a file on a server but receives the following error.

The administrator then runs a few commands and obtains the following output:

Which of the following commands should the administrator run NEXT to allow the file to be renamed by any user?

Options:

A.

chgrp reet files

B.

chacl -R 644 files

C.

chown users files

D.

chmod -t files

Buy Now
Questions 41

User1 is a member of the accounting group. Members of this group need to be able to execute but not make changes to a script maintained by User2. The script should not be accessible to other users or groups. Which of the following will give proper access to the script?

Options:

A.

chown user2:accounting script.sh

chmod 750 script.sh

B.

chown user1:accounting script.sh

chmod 777 script.sh

C.

chown accounting:user1 script.sh

chmod 057 script.sh

D.

chown user2:accounting script.sh

chmod u+x script.sh

Buy Now
Questions 42

A systems administrator wants to permit access temporarily to an application running on port 1234/TCP on a Linux server. Which of the following commands will permit this traffic?

Options:

A.

firewall-cmd —new-service=1234/tcp

B.

firewall-cmd —service=1234 —protocol=tcp

C.

firewall-cmd —add—port=1234/tcp

D.

firewall-cmd —add-whitelist-uid=1234

Buy Now
Questions 43

A DevOps engineer needs to allow incoming traffic to ports in the range of 4000 to 5000 on a Linux server. Which of the following commands will enforce this rule?

Options:

A.

iptables -f filter -I INPUT -p tcp --dport 4000:5000 -A ACCEPT

B.

iptables -t filter -A INPUT -p tcp --dport 4000:5000 -j ACCEPT

C.

iptables filter -A INPUT -p tcp --dport 4000:5000 -D ACCEPT

D.

iptables filter -S INPUT -p tcp --dport 4000:5000 -A ACCEPT

Buy Now
Questions 44

The development team wants to prevent a file from being modified by all users in a Linux system, including the root account. Which of the following commands can be used to accomplish this objective?

Options:

A.

chmod / app/conf/file

B.

setenforce / app/ conf/ file

C.

chattr +i /app/conf/file

D.

chmod 0000 /app/conf/file

Buy Now
Questions 45

A systems administrator needs to remove a disk from a Linux server. The disk size is 500G, and it is the only one that size on that machine. Which of the following commands can the

administrator use to find the corresponding device name?

Options:

A.

fdisk -V

B.

partprobe -a

C.

lsusb -t

D.

lsscsi -s

Buy Now
Questions 46

In order to copy data from another VLAN, a systems administrator wants to temporarily assign IP address 10.0.6 5/24 to the newly added network interface enp1s0f1. Which of the following commands should the administrator run to achieve the goal?

Options:

A.

ip addr add 10.0.6.5/24 dev enpls0f1

B.

echo "IPV4_ADDRESS=10.0.6.5/24" > /etc/sysconfig/network-scripts/ifcfg-enplsOfl

C.

ifconfig 10.0.6.5/24 enpsIs0f1

D.

nmcli conn add lpv4.address-10.0.6.5/24 ifname enpls0f1

Buy Now
Questions 47

A systems administrator frequently connects to a remote host via SSH and a non-standard port. The systems administrator would like to avoid passing the port parameter on the command line every time. Which of the following files can be used to set a different port value for that host?

Options:

A.

/etc/ssh/sshd_config

B.

/etc/ssh/moduli

C.

~/.ssh/config

D.

~/.ssh/authorized_keys

Buy Now
Questions 48

A systems administrator wants to back up the directory /data and all its contents to /backup/data on a remote server named remote. Which of the following commands will achieve the desired effect?

Options:

A.

scp -p /data remote:/backup/data

B.

ssh -i /remote:/backup/ /data

C.

rsync -a /data remote:/backup/

D.

cp -r /data /remote/backup/

Buy Now
Questions 49

A technician just fixed a few issues in some code and is ready to deploy the code into production. Which of the following steps should the technician take next?

Options:

A.

Create a new branch using git checkout.

B.

Perform a git clone to pull main down.

C.

Create a git pull request to merge into main.

D.

Perform a git pull to update the local copy of the code.

Buy Now
Questions 50

A user created the following script file:

# ! /bin/bash

# FILENAME: /home/user/ script . sh

echo "hello world"

exit 1

However, when the user tried to run the script file using the command "script . sh, an error returned indicating permission was denied. Which of the follow-ing should the user execute in

order for the script to run properly?

Options:

A.

chmod u+x /home/user/script . sh

B.

chmod 600 /home/user/script . sh

C.

chmod /home/user/script . sh

D.

chmod 0+r /horne/user/script. sh

Buy Now
Questions 51

A cloud engineer needs to check the link status of a network interface named eth1 in a Linux server. Which of the following commands can help to achieve the goal?

Options:

A.

ifconfig hw eth1

B.

netstat -r eth1

C.

ss -ti eth1

D.

ip link show eth1

Buy Now
Questions 52

Which of the following data structures is written in JSON?

A)

B)

C)

D)

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 53

Which of the following tools is BEST suited to orchestrate a large number of containers across many different servers?

Options:

A.

Kubernetes

B.

Ansible

C.

Podman

D.

Terraform

Buy Now
Questions 54

A non-privileged user is attempting to use commands that require elevated account permissions, but the commands are not successful. Which of the following most likely needs to be updated?

Options:

A.

/etc/passwd

B.

/etc/shadow

C.

/etc/sudoers

D.

/etc/bashrc

Buy Now
Questions 55

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?

Options:

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

Buy Now
Questions 56

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?

Options:

A.

Docker

B.

On-premises systems

C.

Cloud-based systems

D.

Kubernetes

Buy Now
Questions 57

A Linux administrator is troubleshooting an issue in which users are not able to access https://portal.comptia.org from a specific workstation. The

administrator runs a few commands and receives the following output:

Which of the following tasks should the administrator perform to resolve this issue?

Options:

A.

Update the name server in resolv. conf to use an external DNS server.

B.

Remove the entry for portal . comptia.org from the local hosts file.

C.

Add a network route from the 10.10.10.0/24 to the 192.168.0.0/16.

D.

Clear the local DNS cache on the workstation and rerun the host command.

Buy Now
Questions 58

A Linux administrator is alerted to a storage capacity issue on a server without a specific mount point or directory. Which of the following commands would be MOST helpful for troubleshooting? (Choose two.)

Options:

A.

parted

B.

df

C.

mount

D.

du

E.

fdisk

F.

dd

G.

ls

Buy Now
Questions 59

Which of the following actions are considered good security practices when hardening a Linux server? (Select two).

Options:

A.

Renaming the root account to something else

B.

Removing unnecessary packages

C.

Changing the default shell to /bin/csh

D.

Disabling public key authentication

E.

Disabling the SSH root login possibility

F.

Changing the permissions on the root filesystem to 600

Buy Now
Questions 60

A systems administrator is tasked with preventing logins from accounts other than root, while the file /etc/nologin exists. Which of the following PAM modules will accomplish this task?

Options:

A.

pam_login.so

B.

pam_access.so

C.

pam_logindef.so

D.

pam_nologin.so

Buy Now
Questions 61

A Linux administrator is troubleshooting a memory-related issue. Based on the output of the commands:

Which of the following commands would address the issue?

Options:

A.

top -p 8321

B.

kill -9 8321

C.

renice -10 8321

D.

free 8321

Buy Now
Questions 62

A Linux administrator needs to ensure that Java 7 and Java 8 are both locally available for developers to use when deploying containers. Currently only Java 8 is available. Which of the following commands should the administrator run to ensure both versions are available?

Options:

A.

docker image load java:7

B.

docker image pull java:7

C.

docker image import java:7

D.

docker image build java:7

Buy Now
Questions 63

An administrator has source code and needs to rebuild a kernel module. Which of the following command sequences is most commonly used to rebuild this

type of module?

Options:

A.

./configure

make

make install

B.

wget

gcc

cp

C.

tar xvzf

build

cp

D.

build

install

configure

Buy Now
Questions 64

While inspecting a recently compromised Linux system, the administrator identified a number of processes that should not have been running:

Which of the following commands should the administrator use to terminate all of the identified processes?

Options:

A.

pkill -9 -f "upload*.sh"

B.

kill -9 "upload*.sh"

C.

killall -9 -upload*.sh"

D.

skill -9 "upload*.sh"

Buy Now
Questions 65

Which of the following enables administrators to configure and enforce MFA on a Linux system?

Options:

A.

Kerberos

B.

SELinux

C.

PAM

D.

PKI

Buy Now
Questions 66

Ann, a security administrator, is performing home directory audits on a Linux server. Ann issues the su Joe command and then issues the Is command. The

output displays files that reside in Ann's home directory instead of Joe's. Which of the following represents the command Ann should have issued in order to list Joe's files?

Options:

A.

su - Joe

B.

sudo Joe

C.

visudo Joe

D.

pkexec joe

Buy Now
Questions 67

When trying to log in remotely to a server, a user receives the following message:

The server administrator is investigating the issue on the server and receives the following outputs:

Which of the following is causing the issue?

Options:

A.

The wrong permissions are on the user’s home directory.

B.

The account was locked out due to three failed logins.

C.

The user entered the wrong password.

D.

The user has the wrong shell assigned to the account.

Buy Now
Questions 68

A systems administrator is investigating an issue in which one of the servers is not booting up properly. The journalctl entries show the following:

Which of the following will allow the administrator to boot the Linux system to normal mode quickly?

Options:

A.

Comment out the /opt/app filesystem in /etc/fstab and reboot.

B.

Reformat the /opt/app filesystem and reboot.

C.

Perform filesystem checks on local filesystems and reboot.

D.

Trigger a filesystem relabel and reboot.

Buy Now
Questions 69

A Linux administrator generated a list of users who have root-level command-line access to the Linux server to meet an audit requirement. The administrator analyzes the following /etc/passwd and /etc/sudoers files:

$ cat /etc/passwd

root:x: 0:0: :/home/root: /bin/bash

lee: x: 500: 500: :/home/lee:/bin/tcsh

mallory:x: 501:501: :/root:/bin/bash

eve:x: 502: 502: /home/eve:/bin/nologin

carl:x:0:503: :/home/carl:/bin/sh

bob:x: 504: 504: : /home/bob:/bin/ksh

alice:x: 505:505: :/home/alice:/bin/rsh

$ cat /etc/sudoers

Cmnd_Alias SHELLS = /bin/tcsh, /bin/sh, /bin/bash

Cmnd_Alias SYSADMIN = /usr/sbin/tcpdump

ALL = (ALL) ALL

ALL = NOPASSWD: SYSADMIN

Which of the following users, in addition to the root user, should be listed in the audit report as having root-level command-line access? (Select two).

Options:

A.

Carl

B.

Lee

C.

Mallory

D.

Eve

E.

Bob

F.

Alice

Buy Now
Questions 70

A Linux administrator needs to obtain a list of all volumes that are part of a volume group. Which of the following commands should the administrator use to accomplish this task?

Options:

A.

vgs

B.

lvs

C.

fdisk -1

D.

pvs

Buy Now
Questions 71

A Linux administrator found many containers in an exited state. Which of the following commands will allow the administrator to clean up the containers in an exited state?

Options:

A.

docker rm --all

B.

docker rm $(docker ps -aq)

C.

docker images prune *

D.

docker rm --state exited

Buy Now
Questions 72

A Linux administrator reviews a set of log output files and needs to identify files that contain any occurrence of the word denied. All log files containing entries in uppercase or lowercase letters should be included in the list. Which of the following commands should the administrator use to accomplish this task?

Options:

A.

find . -type f -print | xrags grep -ln denied

B.

find . -type f -print | xrags grep -nv denied

C.

find . -type f -print | xrags grep -wL denied

D.

find . -type f -print | xrags grep -li denied

Buy Now
Questions 73

A User on a Linux workstation needs to remotely start an application on a Linux server and then forward the graphical display of that application back to the Linux workstation. Which of the following would enable the user to perform this action?

Options:

A.

ssh -X user@server application

B.

ssh -y user@server application

C.

ssh user@server application

D.

ssh -D user@server application

Buy Now
Questions 74

A cloud engineer needs to launch a container named web-01 in background mode. Which of the following commands will accomplish this task''

Options:

A.

docker builder -f —name web-01 httpd

B.

docker load --name web-01 httpd

C.

docker ps -a --name web-01 httpd

D.

docker run -d --name web-01 httpd

Buy Now
Questions 75

A systems administrator wants to list all local accounts in which the UID is greater than 500. Which of the following commands will give the correct

output?

Options:

A.

find /etc/passwd —size +500

B.

cut —d: fl / etc/ passwd > 500

C.

awk -F: ‘$3 > 500 {print $1}' /etc/passwd

D.

sed '/UID/' /etc/passwd < 500

Buy Now
Questions 76

A systems administrator wants to upgrade /bin/ someapp to a new version, but the administrator does not know the package name. Which of the following will

show the RPM package name that provides that binary file?

Options:

A.

rpm —qf /bin/ someapp

B.

rpm —Vv / bin/ someapp

C.

rpm - P / bin/ some app

D.

rpm —i / bin/ someapp

Buy Now
Questions 77

A Linux engineer needs to create a custom script, cleanup.sh, to run at boot as part of the system services. Which of the following processes would accomplish this task?

Options:

A.

Create a unit file in the /etc/default/ directory.

systemct1 enable cleanup

systemct1 is-enabled cleanup

B.

Create a unit file in the /etc/ske1/ directory.

systemct1 enable cleanup

systemct1 is-enabled cleanup

C.

Create a unit file in the /etc/systemd/system/ directory.

systemct1 enable cleanup

systemct1 is-enabled cleanup

D.

Create a unit file in the /etc/sysctl.d/ directory.

systemct1 enable cleanup

systemct1 is-enabled cleanup

Buy Now
Questions 78

A systems administrator is investigating why one of the servers has stopped connecting to the internet.

Which of the following is causing the issue?

Options:

A.

The DNS address has been commented out in the configuration file.

B.

The search entry in the /etc/resolv.conf file is incorrect.

C.

Wired connection 1 is offline.

D.

No default route is defined.

Buy Now
Questions 79

A server is experiencing intermittent connection issues. Some connections to the Internet work as intended, but some fail as if there is no connectivity. The systems administrator inspects the server configuration:

Which of the following is MOST likely the cause of the issue?

Options:

A.

An internal-only DNS server is configured.

B.

The IP netmask is wrong for ens3.

C.

Two default routes are configured.

D.

The ARP table contains incorrect entries.

Buy Now
Questions 80

A cloud engineer is asked to copy the file deployment.yaml from a container to the host where the container is running. Which of the following commands can accomplish this task?

Options:

A.

docker cp container_id/deployment.yaml deployment.yaml

B.

docker cp container_id:/deployment.yaml deployment.yaml

C.

docker cp deployment.yaml local://deployment.yaml

D.

docker cp container_id/deployment.yaml local://deployment.yaml

Buy Now
Questions 81

A user reported issues when trying to log in to a Linux server. The following outputs were received:

Given the outputs above. which of the following is the reason the user is una-ble to log in to the server?

Options:

A.

User1 needs to set a long password.

B.

User1 is in the incorrect group.

C.

The user1 shell assignment incorrect.

D.

The user1 password is expired.

Buy Now
Questions 82

A newly created container has been unable to start properly, and a Linux administrator is analyzing the cause of the failure. Which of the following will allow the administrator to determine the FIRST command that is executed inside the container right after it starts?

Options:

A.

docker export

B.

docker info

C.

docker start

D.

docker inspect

Buy Now
Questions 83

A systems administrator made some changes in the ~/.bashrc file and added an alias command. When the administrator tried to use the alias command, it did not work. Which of the following should be executed FIRST?

Options:

A.

source ~/.bashrc

B.

read ~/.bashrc

C.

touch ~/.bashrc

D.

echo ~/.bashrc

Buy Now
Questions 84

An administrator is trying to diagnose a performance issue and is reviewing the following output:

System Properties:

CPU: 4 vCPU

Memory: 40GB

Disk maximum IOPS: 690

Disk maximum throughput: 44Mbps | 44000Kbps

Based on the above output, which of the following BEST describes the root cause?

Options:

A.

The system has reached its maximum IOPS, causing the system to be slow.

B.

The system has reached its maximum permitted throughput, therefore iowait is increasing.

C.

The system is mostly idle, therefore the iowait is high.

D.

The system has a partitioned disk, which causes the IOPS to be doubled.

Buy Now
Questions 85

The group named support is unable to make changes to the config file. An administrator is reviewing the permissions and sees the following:

S Is -1 config

-rw-rw----. 1 root app 4682 02-15 11:25 config

Which of the following should the administrator execute in order to give the support group access to modify the file while preserving the current ownership?

Options:

A.

chown :support config

B.

setfacl -m g:support:rw- config

C.

chmod 664 config

D.

chmod g+s config

Buy Now
Questions 86

A systems administrator received a request to change a user's credentials. Which of the following commands will grant the request?

Options:

A.

sudo passwd

B.

sudo userde 1

C.

sudo chage

D.

sudo usermod

Buy Now
Questions 87

A systems administrator is gathering information about a file type and the contents of a file. Which of the following commands should the administrator use to accomplish this task?

Options:

A.

file filename

B.

touch filename

C.

grep filename

D.

lsof filename

Buy Now
Exam Code: XK0-005
Exam Name: CompTIA Linux+ Exam
Last Update: May 9, 2024
Questions: 292

PDF + Testing Engine

$140

Testing Engine

$105

PDF (Q&A)

$90