ExamGecko
Home / CompTIA / XK0-005 / List of questions
Ask Question

CompTIA XK0-005 Practice Test - Questions Answers, Page 14

Add to Whishlist

List of questions

Question 131

Report Export Collapse

A Linux administrator needs to expand a volume group using a new disk. Which of the following options presents the correct sequence of commands to accomplish the task?

partprobevgcreatelvextend
partprobevgcreatelvextend
lvcreatefdiskpartprobe
lvcreatefdiskpartprobe
fdiskpartprobemkfs
fdiskpartprobemkfs
fdiskpvcreatevgextend
fdiskpvcreatevgextend
Suggested answer: D
Explanation:

The correct sequence of commands to expand a volume group using a new disk is fdisk, pvcreate, vgextend. The fdisk command can be used to create a partition on the new disk with the type 8e (Linux LVM). The pvcreate command can be used to initialize the partition as a physical volume for LVM. The vgextend command can be used to add the physical volume to an existing volume group.

The partprobe command can be used to inform the kernel about partition table changes, but it is not necessary in this case. The vgcreate command can be used to create a new volume group, not expand an existing one. The lvextend command can be used to extend a logical volume, not a volume group. The lvcreate command can be used to create a new logical volume, not expand a volume group. The mkfs command can be used to create a filesystem on a partition or a logical volume, not expand a volume group. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 14:

Managing Disk Storage, pages 462-463.

asked 02/10/2024
Bassem Louati
36 questions

Question 132

Report Export Collapse

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

/sys/efi
/sys/efi
/boot/efi
/boot/efi
/efi
/efi
/etc/efi
/etc/efi
Suggested answer: B
Explanation:

The /boot/efi directory is the mount point in a UEFI system. This directory contains the EFI System Partition (ESP), which stores boot loaders and other files required by UEFI firmware. The /sys/efi directory does not exist by default in Linux systems. The /efi directory does not exist by default in Linux systems. The /etc/efi directory does not exist by default in Linux systems. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 11: Managing the Linux Boot Process, page 398.

asked 02/10/2024
Roberto Pili
35 questions

Question 133

Report Export Collapse

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?

rebase
rebase
tag
tag
commit
commit
push
push
Suggested answer: D
Explanation:

The push action is used to publish the changes made in a local branch to a remote branch of a Git repository. This action will update the remote branch with the commits made in the local branch and synchronize the two branches. The rebase action is used to reapply commits from one branch onto another branch, creating a linear history of commits. This action does not publish any changes to a remote repository. The tag action is used to create an annotated reference to a specific commit in a Git repository. This action does not publish any changes to a remote repository. The commit action is used to record changes made in the local repository and create a new snapshot of the project state.

This action does not publish any changes to a remote repository. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 20: Writing and Executing Bash Shell Scripts, page 579.

asked 02/10/2024
Shawn Sullivan
44 questions

Question 134

Report Export Collapse

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?

vgs
vgs
lvs
lvs
fdisk -1
fdisk -1
pvs
pvs
Suggested answer: B
Explanation:

The lvs command can be used to obtain a list of all volumes that are part of a volume group. This command will display information such as the name, size, attributes, and volume group of each logical volume in the system. The vgs command can be used to obtain a list of all volume groups in the system, not the volumes. The fdisk -1 command is invalid, as -1 is not a valid option for fdisk. The pvs command can be used to obtain a list of all physical volumes in the system, not the volumes. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 14: Managing Disk Storage, page 461.

asked 02/10/2024
Thuy Nguyen
38 questions

Question 135

Report Export Collapse

A Linux administrator is adding a new configuration file to a Git repository. Which of the following describes the correct order of Git commands to accomplish the task successfully?

pull -> push -> add -> checkout
pull -> push -> add -> checkout
pull -> add -> commit -> push
pull -> add -> commit -> push
checkout -> push -> add -> pull
checkout -> push -> add -> pull
pull -> add -> push -> commit
pull -> add -> push -> commit
Suggested answer: B
Explanation:

The correct order of Git commands to add a new configuration file to a Git repository is pull -> add -> commit -> push. The pull command will fetch and merge the changes from the remote repository to the local repository, ensuring that the local repository is up to date. The add command will stage the new configuration file for the next commit, marking it as a new file to be tracked by Git. The commit command will create a new snapshot of the project state with the new configuration file and a descriptive message. The push command will publish the commit to the remote repository, updating the remote branch with the new configuration file. The pull -> push -> add -> checkout order is incorrect, as it will not create a commit for the new configuration file, and it will switch to a different branch without pushing the changes. The checkout -> push -> add -> pull order is incorrect, as it will switch to a different branch before adding the new configuration file, and it will overwrite the local changes with the remote changes without creating a commit. The pull -> add -> push -> commit order is incorrect, as it will not create a commit before pushing the changes, and it will create a commit that is not synchronized with the remote branch. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 20: Writing and Executing Bash Shell Scripts, page 579.

asked 02/10/2024
Markus Hechtl
39 questions

Question 136

Report Export Collapse

A systems administrator is tasked with mounting a USB drive on a system. The USB drive has a single partition, and it has been mapped by the system to the device /dev/sdb. Which of the following commands will mount the USB to /media/usb?

mount /dev/sdb1 /media/usb
mount /dev/sdb1 /media/usb
mount /dev/sdb0 /media/usb
mount /dev/sdb0 /media/usb
mount /dev/sdb /media/usb
mount /dev/sdb /media/usb
mount -t usb /dev/sdb1 /media/usb
mount -t usb /dev/sdb1 /media/usb
Suggested answer: A
Explanation:

The mount /dev/sdb1 /media/usb command will mount the USB drive to /media/usb. This command will attach the filesystem on the first partition of the USB drive (/dev/sdb1) to the mount point /media/usb, making it accessible to the system. The mount /dev/sdb0 /media/usb command is invalid, as there is no such device as /dev/sdb0. The mount /dev/sdb /media/usb command is incorrect, as it will try to mount the entire USB drive instead of its partition, which may cause errors or data loss. The mount -t usb /dev/sdb1 /media/usb command is incorrect, as usb is not a valid filesystem type for mount. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 14: Managing Disk Storage, page 455.

asked 02/10/2024
Alessandro Cristofori
42 questions

Question 137

Report Export Collapse

A developer reported an incident involving the application configuration file /etc/httpd/conf/httpd.conf that is missing from the server. Which of the following identifies the RPM package that installed the configuration file?

rpm -qf /etc/httpd/conf/httpd.conf
rpm -qf /etc/httpd/conf/httpd.conf
rpm -ql /etc/httpd/conf/httpd.conf
rpm -ql /etc/httpd/conf/httpd.conf
rpm -query /etc/httpd/conf/httpd.conf
rpm -query /etc/httpd/conf/httpd.conf
rpm -q /etc/httpd/conf/httpd.conf
rpm -q /etc/httpd/conf/httpd.conf
Suggested answer: A
Explanation:

The rpm -qf /etc/httpd/conf/httpd.conf command will identify the RPM package that installed the configuration file. This command will query the database of installed packages and display the name of the package that owns the specified file. The rpm -ql /etc/httpd/conf/httpd.conf command is invalid, as -ql is not a valid option for rpm. The rpm --query /etc/httpd/conf/httpd.conf command is incorrect, as --query requires a package name, not a file name. The rpm -q /etc/httpd/conf/httpd.conf command is incorrect, as -q requires a package name, not a file name. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 19: Managing Packages and Software, page 560.

asked 02/10/2024
Juan Gonzalez
43 questions

Question 138

Report Export Collapse

Joe, a user, is unable to log in to the Linux system Given the following output:

CompTIA XK0-005 image Question 138 99779 10022024175436000000

Which of the following command would resolve the issue?

usermod -s /bin/bash joe
usermod -s /bin/bash joe
pam_tally2 -u joe -r
pam_tally2 -u joe -r
passwd -u joe
passwd -u joe
chage -E 90 joe
chage -E 90 joe
Suggested answer: B
Explanation:

Based on the output of the image sent by the user, Joe is unable to log in to the Linux system because his account has been locked due to too many failed login attempts. The pam_tally2 -u joe -r command will resolve this issue by resetting Joe's failed login counter to zero and unlocking his account. This command uses the pam_tally2 module to manage user account locking based on login failures. The usermod -s /bin/bash joe command will change Joe's login shell to /bin/bash, but this will not unlock his account. The passwd -u joe command will unlock Joe's password if it has been locked by passwd -l joe, but this will not reset his failed login counter or unlock his account if it has been locked by pam_tally2. The chage -E 90 joe command will set Joe's account expiration date to 90 days from today, but this will not unlock his account or reset his failed login counter. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 18: Securing Linux Systems, page 537.

asked 02/10/2024
Christopher Castillo
41 questions

Question 139

Report Export Collapse

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

docker builder -f -name web-01 httpd
docker builder -f -name web-01 httpd
docker load --name web-01 httpd
docker load --name web-01 httpd
docker ps -a --name web-01 httpd
docker ps -a --name web-01 httpd
docker run -d --name web-01 httpd
docker run -d --name web-01 httpd
Suggested answer: D
Explanation:

The docker run -d --name web-01 httpd command will launch a container named web-01 in background mode. This command will create and start a new container from the httpd image, assign it the name web-01, and run it in detached mode (-d), which means the container will run in the background without attaching to the current terminal. The docker builder -f --name web-01 httpd command is invalid, as builder is not a valid docker command, and -f and --name are not valid options for docker build. The docker load --name web-01 httpd command is invalid, as load does not accept a --name option, and httpd is not a valid file name for load. The docker ps -a --name web-01 httpd command is invalid, as ps does not accept a --name option, and httpd is not a valid filter for ps. Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 16: Virtualization and Cloud Technologies, page 499.

asked 02/10/2024
Ruben Campoy
46 questions

Question 140

Report Export Collapse

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

Kubernetes
Kubernetes
Ansible
Ansible
Podman
Podman
Terraform
Terraform
Suggested answer: A
Explanation:

The tool that is best suited to orchestrate a large number of containers across many different servers is Kubernetes. Kubernetes is an open-source platform for managing containerized applications and services. Kubernetes allows the administrator to deploy, scale, and update containers across a cluster of servers, as well as to automate the configuration and coordination of the containers. Kubernetes also provides features such as service discovery, load balancing, storage management, security, monitoring, and logging. Kubernetes can handle complex and dynamic workloads and ensure high availability and performance of the containers. Kubernetes is the tool that is best suited to orchestrate a large number of containers across many different servers. This is the correct answer to the question. The other options are incorrect because they either do not orchestrate containers (Ansible or Terraform) or do not operate across many different servers (Podman). Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 19: Managing Cloud and Virtualization Technologies, page 573.

asked 02/10/2024
Shangar Sundaralingam
44 questions
Total 407 questions
Go to page: of 41
Search

Related questions