CompTIA XK0-005 CompTIA Linux+ Exam Online Training
CompTIA XK0-005 Online Training
The questions for XK0-005 were last updated at Nov 23,2024.
- Exam Code: XK0-005
- Exam Name: CompTIA Linux+ Exam
- Certification Provider: CompTIA
- Latest update: Nov 23,2024
A systems administrator requires that all files that are created by the user named web have read-only permissions by the owner.
Which of the following commands will satisfy this requirement?
- A . chown web:web /home/web
- B . chmod -R 400 /home/web
- C . echo "umask 377" >> /home/web/.bashrc
- D . setfacl read /home/web
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?
- A . pam_login.so
- B . pam_access.so
- C . pam_logindef.so
- D . pam_nologin.so
A systems administrator has been tasked with disabling the nginx service from the environment to prevent it from being automatically and manually started.
Which of the following commands will accomplish this task?
- A . systemct1 cancel nginx
- B . systemct1 disable nginx
- C . systemct1 mask nginx
- D . systemct1 stop nginx
A Linux administrator is troubleshooting an issue in which an application service failed to start on a
Linux server.
The administrator runs a few commands and gets the following outputs:
Based on the above outputs, which of the following is the MOST likely action the administrator should take to resolve this issue?
- A . Enable the logsearch.service and restart the service.
- B . Increase the TimeoutStartUSec configuration for the logsearch.sevice.
- C . Update the OnCalendar configuration to schedule the start of the logsearch.service.
- D . Update the KillSignal configuration for the logsearch.service to use TERM.
A Linux administrator has installed a web server, a database server, and a web application on a server. The web application should be active in order to render the web pages. After the administrator restarts the server, the website displays the following message in the browser: Error establishing a database connection.
The Linux administrator reviews the following relevant output from the systemd init files:
The administrator needs to ensure that the database is available before the web application is started.
Which of the following should the administrator add to the HTTP server .service file to accomplish this task?
- A . TRIGGERS=mariadb.service
- B . ONFAILURE=mariadb.service
- C . WANTEDBY=mariadb.service
- D . REQUIRES=mariadb.service
Several users reported that they were unable to write data to the /oracle1 directory.
The following output has been provided:
Which of the following commands should the administrator use to diagnose the issue?
- A . df -i /oracle1
- B . fdisk -1 /dev/sdb1
- C . lsblk /dev/sdb1
- D . du -sh /oracle1
After installing some RPM packages, a systems administrator discovers the last package that was installed was not needed.
Which of the following commands can be used to remove the package?
- A . dnf remove packagename
- B . apt-get remove packagename
- C . rpm -i packagename
- D . apt remove packagename
A systems administrator is checking the system logs. The administrator wants to look at the last 20 lines of a log.
Which of the following will execute the command?
- A . tail -v 20
- B . tail -n 20
- C . tail -c 20
- D . tail -l 20
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?
- 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.
A systems administrator wants to test the route between IP address 10.0.2.15 and IP address 192.168.1.40.
Which of the following commands will accomplish this task?
- A . route -e get to 192.168.1.40 from 10.0.2.15
- B . ip route get 192.163.1.40 from 10.0.2.15
- C . ip route 192.169.1.40 to 10.0.2.15
- D . route -n 192.168.1.40 from 10.0.2.15