XK0-004 Exam Details

  • Exam Code
    :XK0-004
  • Exam Name
    :CompTIA Linux+ Certification
  • Certification
    :CompTIA Certifications
  • Vendor
    :CompTIA
  • Total Questions
    :516 Q&As
  • Last Updated
    :Aug 23, 2023

CompTIA XK0-004 Online Questions & Answers

  • Question 1:

    A junior administrator of a physical server receives log messages indicating the out-of-memory killer has been active. All memory slots are in use on the motherboard, but additional disk space is available. Space has been allocated for a swap file.

    Which of the following should the administrator use to reduce the output of memory messages?

    A. free : swapoff / swapfile ; swapon -a
    B. mkswap /swapfile; swapon -a
    C. fallocate -l 2G /swapfile andand swapon -a
    D. echo "1" > /proc/meninfo ; swapon / swapfile

  • Question 2:

    A systems administrator suspects a process with a PID of 2864 is consuming resources at an alarming rate. The administrator uses the command renice -n -5 -p2864, but it does not solve the issue. Which of the following commands should the administrator execute to correct the issue?

    A. nice -n 5 -p 2864
    B. nice -n -5 -p 2864
    C. renice -n 10 -p 2864
    D. renice -n -10 -p 2864

  • Question 3:

    Using which of the following control mode commands is the correct way to substitute all occurrences of / dev/sdc with /dev/sdd while editing a file in vi?

    A. :s//dev/sdc//dev/sdd
    B. :s/\/dev\/sdc/\/dev\/sdd/g
    C. :s/\/dev\/sdc/\/dev\/sdd
    D. :%s/\/dev\/sdc/\/dev\/sdd

  • Question 4:

    An administrator is troubleshooting to determine why backups are failing on a particular server. The administrator runs the ps command and analyzes the following output.

    The administrator runs kill -9 10112 yet the process remains. Which of the following BEST describes the issue and how to fix it?

    A. The backup process is still running and needs to be killed with kill -9 --force 10112.
    B. The backup process is a zombie process, and the system needs to be rebooted.
    C. The backup process is out of memory, and more memory needs to be added to the system.
    D. The backup process is using 100% of system resources and needs to be rescheduled with renice.

  • Question 5:

    A Linux administrator mounts a directory to a Linux workstation by executing the command mount -t ext4 / dev/sdb /mnt /leg. After rebooting the workstation the mounted device is missing. Which of the following commands should it is mounted after reboot?

    A. echo "/dev/adb /ant/log ext4 defaults 0 0" ?/etc/fstab
    B. fsck /dev/sdb
    C. Ivchange --activate /dev/aab
    D. mkfs.txt4 /dev/sdb

  • Question 6:

    When performing a routine server process inspection the systems administrator notices that about 300 processes similar to the following are running:

    Root 7858 0 21:39 pts/0 00:00:00 [websrv]

    Malfunctioning software is found and removed from the server, but the administrator is now unable to terminate the remaining processes Which of the following is the BEST course of action for the administrator to take NEXT in order to

    remove.

    A. Schedule a server reboot
    B. Raise the process priorities
    C. Reinstall the OS on the server
    D. Lower the process prionties

  • Question 7:

    A systems administrator needs to run the yum update command two hours after employees log off and leave for the day on Friday. Which of the following is the BEST command to complete the task, if the task only needs to be run once?

    A. screen
    B. cron
    C. at
    D. nohup

  • Question 8:

    An administrator is reviewing updates in the master online Git repository and notices a file named .htaccess. The file contains passwords and should only be in the administrator's local repository, not the online one. Which of the following would prevent this file from appearing online in the future?

    A. git commit -m "File Update" -x .htaccess
    B. sed -i 's/#Preserve Hidden=True/Preserve Hidden=True/g' .git/config
    C. chown nobody:nodoby .htaccess
    D. echo ".htaccess" >> .gitignore

  • Question 9:

    An engineer is working on a production application deployment that requires changing a web application property file called server.property that is managed by the Git version control system. A cloned copy of the remote repository in which the server.property file exists is on the local desktop computer. The engineer makes appropriate changes to the files, saves it as server.property, and executes git commit -m "changed the property file" server.property. Which of the following commands did the engineer fail to perform?

    A. git init server.property
    B. git merge server.property
    C. git add server.property
    D. git push server.property

  • Question 10:

    A junior systems administrator created a new filesystem /dev/sda1 with mountpoint /data and added it to the /etc/fstab for auto-mounting. When the systems administrator tries to mount the file system, the system refuses. Given the output below:

    Which of the following steps is necessary?

    A. Change the filesystem from /dev/sda1 to /dev/sda2 and reboot.
    B. Change the options to auto,dev,sync,rw,nosuid and run the mount -a command.
    C. Change the mount point to data and reboot.
    D. Change the dump column to 1 and run the mount -a command.

Tips on How to Prepare for the Exams

Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only CompTIA exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your XK0-004 exam preparations and CompTIA certification application, do not hesitate to visit our Vcedump.com to find your solutions here.