Courseiva
Knowledge + Practice
CertificationsVendorsCareer RoadmapsLabs & ToolsStudy GuidesGlossaryPractice Questions
C
Courseiva

Free IT certification practice questions with explained answers for CCNA, CompTIA, AWS, Azure, Google Cloud, and more.

Certification Practice Questions

CCNA practice questionsSecurity+ SY0-701 practice questionsAWS SAA-C03 practice questionsAZ-104 practice questionsAZ-900 practice questionsCLF-C02 practice questionsA+ Core 1 practice questionsGoogle Cloud ACE practice questionsCySA+ CS0-003 practice questionsNetwork+ N10-009 practice questions
View all certifications →

Product

CertificationsCertification PathsExam TopicsPractice TestsExam Dumps vs Practice TestsStudy HubComparisons

Company

AboutContactEditorial PolicyQuestion Writing PolicyTrust Center

Legal

Privacy PolicyTerms of Service

Courseiva is a free IT certification practice platform offering original exam-style practice questions, detailed explanations, topic-based practice, mock exams, readiness tracking, and study analytics for Cisco, CompTIA, Microsoft, AWS, and other technology certifications.

© 2026 Courseiva. Courseiva is operated by JTNetSolutions Ltd. All rights reserved.

Courseiva is an independent certification practice platform and is not affiliated with, endorsed by, or sponsored by Cisco, Microsoft, AWS, CompTIA, Google, ISC2, ISACA, or any other certification vendor. Vendor names and certification marks are used only to identify the exams learners are preparing for.

← Essential Commands practice sets

LFCS Essential Commands • Complete Question Bank

LFCS Essential Commands — All Questions With Answers

Complete LFCS Essential Commands question bank — all 0 questions with answers and detailed explanations.

99
Questions
Free
No signup
Certifications/LFCS/Practice Test/Essential Commands/All Questions
Question 1mediummultiple choice
Read the full Essential Commands explanation →

A user reports that a script fails with 'Permission denied' when executed. The script has permissions -rw-r--r-- and is owned by the user. Which command should the user run to make the script executable for the owner only?

Question 2easymultiple choice
Read the full Essential Commands explanation →

A system administrator needs to find all files in /var/log that have been modified in the last 7 days. Which command accomplishes this?

Question 3hardmultiple choice
Read the full Essential Commands explanation →

An administrator wants to ensure that a background process continues running after logout. Which command should be used to start the process?

Question 4mediummultiple choice
Read the full Essential Commands explanation →

A technician needs to display the contents of a compressed file named archive.tar.gz without extracting it. Which command should be used?

Question 5easymultiple choice
Read the full Essential Commands explanation →

A user wants to find the location of the 'grep' binary. Which command should they use?

Question 6hardmulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to create a new empty file?

Question 7mediummulti select
Read the full Essential Commands explanation →

Which THREE commands can be used to view the contents of a file?

Question 8mediummultiple choice
Read the full Essential Commands explanation →

What is the purpose of the chmod 755 command in this exhibit?

Network Topology
-rw-rrRefer to the exhibit.$ ls -l file1$ chmod 755 file1
Question 9hardmultiple choice
Read the full Essential Commands explanation →

Based on the exhibit, which process will be affected if the root user runs 'kill 5678'?

Exhibit

Refer to the exhibit.

$ ps aux | grep apache
root      1234  0.0  0.2  12345  6789 ?        Ss   Jan01   0:00 /usr/sbin/apache2 -k start
www-data  5678  0.0  0.1  12345  1234 ?        S    Jan01   0:00 /usr/sbin/apache2 -k start
www-data  5679  0.0  0.1  12345  1234 ?        S    Jan01   0:00 /usr/sbin/apache2 -k start
Question 10mediummultiple choice
Read the full Essential Commands explanation →

A developer accidentally deleted a critical file /var/log/app.log. The system administrator knows that the file was recently backed up using a cron job that runs 'tar -czf /backup/logs.tar.gz /var/log/'. Which command should the administrator use to restore the file from the backup without extracting the entire archive?

Question 11hardmultiple choice
Read the full Essential Commands explanation →

A system administrator needs to find all files in /home that are owned by user 'alice' and have been modified in the last 7 days. The administrator then wants to compress those files into a single archive named alice_recent.tar.gz. Which of the following commands accomplishes this?

Question 12easymultiple choice
Read the full Essential Commands explanation →

A junior administrator needs to display the first 10 lines of a file named 'data.csv'. Which command should they use?

Question 13mediummultiple choice
Read the full NAT/PAT explanation →

A system administrator is troubleshooting a user's report that a command 'myapp' is not found. The administrator checks the PATH variable and sees it includes /usr/local/bin. The administrator verifies that the binary 'myapp' exists in /usr/local/bin with permissions 755. However, running 'myapp' still fails with 'command not found'. What is the most likely cause?

Question 14hardmulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to display the current working directory? (Choose exactly two.)

Question 15mediummulti select
Read the full Essential Commands explanation →

Which THREE of the following commands can be used to view the contents of a compressed file named 'file.gz' without permanently decompressing it? (Choose exactly three.)

Question 16mediummultiple choice
Read the full Essential Commands explanation →

A user with uid 1000 tries to read /etc/shadow and gets 'Permission denied'. The user is not in the shadow group. Which of the following actions would allow the user to read the file without changing the file's group or permissions?

Exhibit

Refer to the exhibit.

$ ls -l /etc/shadow
-rw-r----- 1 root shadow 1234 Jan 15 10:00 /etc/shadow
$ id
uid=1000(user1) gid=1000(user1) groups=1000(user1)
$ cat /etc/shadow
cat: /etc/shadow: Permission denied
Question 17hardmultiple choice
Read the full Essential Commands explanation →

You are a system administrator for a company that runs a web server on a Linux system. The web server logs are stored in /var/log/nginx/access.log. The log file grows rapidly and rotates weekly via logrotate. The system has been running for several months. Recently, the development team reported that the web server is responding slowly. You suspect that the disk I/O might be high due to log file activity. You check the disk usage and find that /var/log/nginx/access.log is 4 GB, and the rotated logs (access.log.1.gz, access.log.2.gz, etc.) total another 10 GB. The /var partition has 20 GB total, so it's 70% full. You decide to reduce the disk usage by compressing the current log file and truncating it without stopping the nginx service. Which command sequence should you use to safely achieve this?

Question 18hardmultiple choice
Read the full Essential Commands explanation →

You are managing a Linux server that hosts a critical web application. The server is running low on disk space in the root filesystem, and you need to free up space urgently. You run 'df -h' and see that /dev/sda1 is mounted on / and is 95% full. You also notice that /var/log/messages is over 2 GB in size. The application writes logs to /var/log/app.log, which is also large. The server has a separate /var partition that has plenty of free space. The application must continue running with minimal downtime. You need to compress and rotate logs without losing any data, and ensure that the root filesystem has at least 10% free space. Which of the following actions should you take first to achieve this goal?

Question 19mediummultiple choice
Read the full Essential Commands explanation →

A system administrator needs to list all files in the current directory, including hidden files, in a long listing format sorted by modification time (oldest first). Which command achieves this?

Question 20easymultiple choice
Read the full Essential Commands explanation →

A user wants to find all files in /var/log that have been modified within the last 2 days. Which command should they use?

Question 21hardmultiple choice
Read the full Essential Commands explanation →

A system administrator runs 'grep -r 'error' /var/log' and gets many false positives. They want to search only for the exact word 'error' as a whole word, case-insensitively, and display line numbers. Which command should they use?

Question 22easymultiple choice
Read the full network assurance explanation →

A user needs to view the contents of a compressed log file /var/log/syslog.gz without first decompressing it. Which command should they use?

Question 23mediummultiple choice
Read the full Essential Commands explanation →

A developer wants to change the ownership of a directory and all its contents recursively to user 'appuser' and group 'appgroup'. Which command accomplishes this?

Question 24hardmultiple choice
Read the full Essential Commands explanation →

A systems administrator needs to add a new user 'jdoe' with a home directory in /export/home, a UID of 1500, and an expiry date of 2025-12-31. Which command should they use?

Question 25easymultiple choice
Read the full Essential Commands explanation →

A user wants to set the permissions of a file to 'rwxr-xr--'. Which octal permission value should they use with chmod?

Question 26mediumdrag order
Read the full Essential Commands explanation →

Order the steps to mount an ext4 filesystem from an external USB drive automatically at boot.

Drag steps to the numbered slots on the right, or tap a step then tap a slot.

Steps
Order
1Step 1
2Step 2
3Step 3
4Step 4
5Step 5
Question 27mediummatching
Read the full Essential Commands explanation →

Match each Linux permission type to its symbolic representation.

Drag a concept onto its matching description — or click a concept then click the description.

Concepts
Matches

r

w

x

s (owner execute)

t (other execute)

Question 28easymultiple choice
Read the full Essential Commands explanation →

A user reports that a shell script 'backup.sh' in /home/user/scripts fails to execute. What is the most likely cause?

Question 29mediummultiple choice
Read the full Essential Commands explanation →

A system administrator needs to find all files under /var/log that have been modified within the last 7 days. Which command accomplishes this task?

Question 30hardmultiple choice
Read the full Essential Commands explanation →

A process is consuming 99% CPU and is unresponsive to normal shutdown requests. After running 'top', you see the PID is 1234. What is the most appropriate command to stop the process gracefully first?

Question 31mediummultiple choice
Read the full Essential Commands explanation →

A backup script must create a compressed archive of the /etc directory, preserving file permissions and timestamps. Which command should be used?

Question 32easymultiple choice
Read the full Essential Commands explanation →

A user wants to continuously monitor the last 20 lines of a log file that is being written to by a running service. Which command achieves this?

Question 33hardmultiple choice
Read the full Essential Commands explanation →

A system administrator needs to replace all occurrences of 'oldhost' with 'newhost' in /etc/hosts, but only on lines that contain the string 'domain'. Which sed command accomplishes this?

Question 34mediummultiple choice
Read the full Essential Commands explanation →

To check the disk usage of the /var/log directory in a human-readable format, which command is appropriate?

Question 35easymultiple choice
Read the full Essential Commands explanation →

A user needs to view the contents of a large text file one screen at a time. Which command is best for this?

Question 36hardmultiple choice
Read the full Essential Commands explanation →

A cron job runs a script every hour but sometimes fails because the script cannot find commands like 'tar' and 'gzip'. The script works when run manually from a terminal. What is the best fix?

Question 37mediummulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to list the contents of a tar archive without extracting it?

Question 38hardmulti select
Read the full Essential Commands explanation →

Which THREE commands can change the priority of an already running process?

Question 39easymulti select
Read the full Essential Commands explanation →

Which TWO commands can display the current environment variables?

Question 40mediummultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit. The file script.sh has permissions -rwxr-x--- and is owned by root with group 'developers'. A user named 'alice' is a member of the 'developers' group. Which command allows alice to execute the script without changing the file's group ownership?

Exhibit

-rwxr-x---  1 root developers 1234 Feb 20 10:00 script.sh
Question 41hardmultiple choice
Read the full NAT/PAT explanation →

Refer to the exhibit. The output of 'ps aux' shows a process named 'process_hog' with PID 1234 consuming 99.5% CPU. The process is stuck in an infinite loop and does not respond to SIGTERM. Which signal should be used to forcefully terminate it?

Exhibit

USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root      1234 99.5  0.2  12345  6789 pts/0    R    10:00  45:00 process_hog
Question 42easymultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit. The /var partition is 100% full. Which command can be used to find the largest files in /var/log to free up space?

Exhibit

Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1        20G   20G     0 100% /var
Question 43easymultiple choice
Read the full Essential Commands explanation →

A system administrator needs to find all files in /var/log that have been modified in the last 24 hours. Which command accomplishes this?

Question 44mediummultiple choice
Read the full Essential Commands explanation →

A DevOps engineer wants to measure how long a specific command takes to execute. Which command should be used?

Question 45hardmultiple choice
Read the full Essential Commands explanation →

An administrator runs 'ls -la' and sees the following entry for a file: 'lrwxrwxrwx 1 root root 24 Jan 10 12:00 link -> /etc/passwd'. If the target file /etc/passwd is deleted, what happens to the link file?

Question 46easymultiple choice
Read the full Essential Commands explanation →

To compress a file while preserving the original file, which command should be used?

Question 47mediummultiple choice
Read the full Essential Commands explanation →

A system administrator wants to display a list of all currently running processes with their parent process IDs. Which command is most appropriate?

Question 48hardmultiple choice
Read the full Essential Commands explanation →

An administrator runs 'df -h' and notices that /dev/sda1 is 95% full. The administrator needs to identify the largest files in the filesystem. Which command sequence is most efficient?

Question 49easymultiple choice
Read the full Essential Commands explanation →

To display the first 10 lines of a file named 'log.txt', which command is correct?

Question 50mediummultiple choice
Read the full Essential Commands explanation →

A user is unable to write to a file. The output of 'ls -l file' shows '-r--r--r--'. Which command will grant write permission to the owner?

Question 51hardmultiple choice
Read the full NAT/PAT explanation →

An administrator needs to find the process ID of the cron daemon. Which combination of commands is most effective?

Question 52mediummulti select
Read the full Essential Commands explanation →

A system administrator needs to change the group ownership of a file to 'developers' and set the setgid bit on a directory. Which two commands accomplish these tasks? (Choose two.)

Question 53hardmulti select
Read the full Essential Commands explanation →

An administrator wants to find all files larger than 100MB in the /home directory. Which three commands or command sequences achieve this? (Choose three.)

Question 54easymulti select
Read the full Essential Commands explanation →

A user wants to view the contents of a compressed file file.txt.gz without decompressing it permanently. Which two commands can be used? (Choose two.)

Question 55mediummultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit.

A user attempts to read /etc/passwd and receives "Permission denied". What is the most likely reason?

Network Topology
-rw-rr
Question 56hardmultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit.

A user attempts to create a file in /backup/snapshots/ but receives an error. What is the most likely cause?

Exhibit

/dev/sda1 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sda2 on /var type ext4 (rw,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev)
/dev/sdb1 on /backup type ext4 (ro)
Question 57easymultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit.

The /data directory needs to be resized to 15GB. What is the first step?

Exhibit

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0    20G  0 disk 
├─sda1   8:1    0   512M  0 part /boot
└─sda2   8:2    0   19.5G 0 part /
sdb      8:16   0    10G  0 disk 
└─sdb1   8:17   0    10G  0 part /data
Question 58easymultiple choice
Read the full Essential Commands explanation →

A system administrator needs to find all files in /var/log that have been modified in the last 7 days. Which command accomplishes this?

Question 59mediummultiple choice
Read the full Essential Commands explanation →

A user is unable to execute a script in their home directory. The script has permissions -rw-r--r--. Which command will allow the user to execute the script?

Question 60hardmultiple choice
Read the full Essential Commands explanation →

A DevOps engineer wants to list all running processes sorted by memory usage in descending order. Which command should be used?

Question 61easymultiple choice
Read the full Essential Commands explanation →

An administrator needs to compress a directory named 'project' into a tarball with maximum compression using gzip. Which command is appropriate?

Question 62mediummultiple choice
Read the full Essential Commands explanation →

A junior admin runs 'ls -l' and sees permissions '-rwxrwxr-x' on a file. What is the octal representation?

Question 63hardmultiple choice
Read the full NAT/PAT explanation →

A system administrator wants to kill a process with PID 1234 that is not responding to SIGTERM. Which command will forcefully terminate it?

Question 64easymultiple choice
Read the full Essential Commands explanation →

A user needs to see the contents of a gzip-compressed file 'data.txt.gz' without decompressing it. Which command is appropriate?

Question 65mediummultiple choice
Read the full network assurance explanation →

A script needs to search for lines containing 'ERROR' in /var/log/syslog and count them. Which command pipeline achieves this?

Question 66hardmultiple choice
Read the full Essential Commands explanation →

An administrator wants to print the last field of each line from a CSV file 'data.csv' (comma-separated). Which awk command accomplishes this?

Question 67mediummultiple choice
Read the full Essential Commands explanation →

A user 'dba' tries to login via SSH and fails. Based on the exhibit, what is the most likely cause?

Network Topology
-rw-rrRefer to the exhibit.docker:x:1001:1001::/home/docker:/bin/bashdba:x:1002:1002::/home/dba:/bin/false$ ls -la /home/dba/total 8$ whoamidba
Question 68easymultiple choice
Read the full Essential Commands explanation →

Based on the exhibit, what is the average CPU idle percentage over the last 15 minutes?

Exhibit

Refer to the exhibit.

$ top -bn1 | head -5
top - 14:23:45 up 10 days,  2:15,  1 user,  load average: 1.5, 2.0, 2.5
Tasks: 123 total,   1 running, 122 sleeping,   0 stopped,   0 zombie
%Cpu(s): 25.0 us, 10.0 sy,  0.0 ni, 65.0 id,  0.0 wa,  0.0 hi,  0.0 si
MiB Mem :   1984.4 total,    500.0 free,   1000.0 used,   484.4 buff/cache
MiB Swap:   2048.0 total,   2048.0 free,      0.0 used.   1484.4 avail Mem
Question 69hardmultiple choice
Read the full Essential Commands explanation →

The backup script fails to run as user 'backup' with sudo. What is the issue?

Exhibit

Refer to the exhibit.

$ ls -l /usr/local/bin/backup.sh
-rwx------ 1 root root 1024 Jan  1 12:00 /usr/local/bin/backup.sh

$ sudo -u backup /usr/local/bin/backup.sh
sudo: unable to execute /usr/local/bin/backup.sh: Permission denied

$ id backup
uid=1003(backup) gid=1003(backup) groups=1003(backup)
Question 70mediummulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to display the contents of a text file page by page? (Select two.)

Question 71hardmulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to change the ownership of a file to a specific user and group? (Select two.)

Question 72mediummulti select
Read the full Essential Commands explanation →

Which THREE commands can be used to view the contents of a compressed archive file without extracting it? (Select three.)

Question 73easymultiple choice
Read the full Essential Commands explanation →

A user reports that they cannot run a script because it says 'Permission denied'. The script is owned by root and has permissions -rw-r--r--. Which command would allow the user to execute the script?

Question 74mediummultiple choice
Read the full Essential Commands explanation →

A system administrator is troubleshooting a performance issue. They need to identify which process is consuming the most CPU time over the last 24 hours. Which command should be used?

Question 75hardmultiple choice
Read the full Essential Commands explanation →

A developer needs to extract the third column from a CSV file where columns are separated by commas, but some fields contain commas within double quotes. Which command correctly handles this?

Question 76mediummultiple choice
Read the full Essential Commands explanation →

A system administrator has a cron job that runs a backup script. The script requires the variable BACKUP_DIR to be set, but the administrator cannot modify the script. Which is the most appropriate place to define the variable for cron?

Question 77hardmultiple choice
Read the full Essential Commands explanation →

An administrator needs to replace all occurrences of the string 'foo' with 'bar' in all files under /etc/config, but only in files ending with .conf. The replacement must be done in-place, and backup copies should be created with a .bak extension. Which command accomplishes this?

Question 78easymultiple choice
Read the full network assurance explanation →

A user wants to view the contents of a compressed log file /var/log/syslog.2.gz without decompressing it first. Which command should they use?

Question 79mediummultiple choice
Read the full NAT/PAT explanation →

A security policy requires that all users in the 'webadmin' group should have read and write access to files in /var/www/html. New files created in that directory should automatically be assigned to the 'webadmin' group and have group read/write permissions. Which combination of permissions and group ownership should be set on /var/www/html?

Question 80easymultiple choice
Read the full Essential Commands explanation →

Which command displays the amount of free and used memory in the system?

Question 81mediummultiple choice
Read the full NAT/PAT explanation →

An administrator wants to terminate a process with PID 1234 and all its child processes. Which command should be used?

Question 82mediummulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to view the last 10 lines of a file and also follow new lines as they are written?

Question 83hardmulti select
Read the full Essential Commands explanation →

Which THREE of the following commands can be used to search for a string in multiple files and display the matching lines?

Question 84easymulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to display the current working directory?

Question 85mediummultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit. The nginx service failed to start. What is the most likely immediate next step to diagnose the issue?

Exhibit

$ systemctl status nginx
● nginx.service - A high performance web server and a reverse proxy server
   Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Mon 2023-10-23 09:15:32 UTC; 2min ago
     Docs: man:nginx(8)
  Process: 1234 ExecStart=/usr/sbin/nginx (code=exited, status=1/FAILURE)
 Main PID: 1234 (code=exited, status=1)
Question 86mediummultiple choice
Read the full Essential Commands explanation →

Refer to the exhibit. The administrator receives alerts that the root filesystem is almost full. Which command could free up space by removing old log files?

Exhibit

$ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1        50G   45G   5.4G  90% /
/dev/sdb1       100G   20G   80G   20% /data
Question 87hardmultiple choice
Read the full Essential Commands explanation →

A system administrator is managing a production web server running CentOS 7. The server hosts a critical application that depends on the 'httpd' package. Recently, the administrator attempted to install an updated version of httpd using 'yum update httpd', but the update failed with a dependency error: 'Error: Package: httpd-2.4.6-97.el7.centos.x86_64 requires libapr-1.so.0()(64bit)'. The administrator verifies that the apr package is installed (apr-1.5.2-6.el7.x86_64) and that the required library file exists at /usr/lib64/libapr-1.so.0. Despite this, yum continues to fail with the same error. After checking the yum repository configuration, the administrator notices that the base repository lists 'mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os' and the 'baseurl' is commented out. The system's /etc/yum.conf has 'keepcache=1'. What is the most likely cause of the dependency error, and which command should the administrator run to resolve it?

Question 88easymultiple choice
Read the full network assurance explanation →

A system administrator notices that '/var/log/syslog' has grown very large and is consuming significant disk space. The administrator wants to identify the largest log files in the '/var/log' directory hierarchy. Which command should the administrator use?

Question 89mediummultiple choice
Read the full Essential Commands explanation →

A developer reports that a compiled binary 'app' fails to execute with 'Permission denied' error when run from a mounted directory '/mnt/software'. The binary has execute permissions for all users. What is the most likely cause?

Question 90mediummultiple choice
Read the full Essential Commands explanation →

A system administrator needs to stop a misbehaving process gracefully, allowing it to clean up resources. The process is unresponsive to the standard SIGTERM signal. What should the administrator do next?

Question 91hardmultiple choice
Read the full Essential Commands explanation →

A database administrator wants to compress a large directory of log files for archival. The administrator uses the command: tar -cvf logs.tar.gz logs/. The command completes successfully but the resulting archive is only 10 MB while the original directory is 100 MB. What is the most likely reason?

Question 92easymulti select
Read the full Essential Commands explanation →

Which TWO commands can be used to display the contents of a text file that has been compressed with gzip without decompressing it to disk?

Question 93mediummulti select
Read the full Essential Commands explanation →

Which THREE of the following statements about Linux file permissions are correct?

Question 94easymultiple choice
Read the full Essential Commands explanation →

A user reports that they cannot delete a file named 'important.txt' located in their home directory. The file is owned by the user and the user has write permission on the directory. Running 'rm important.txt' produces the error: 'rm: cannot remove 'important.txt': Operation not permitted'. The user has also tried using 'sudo rm' but gets the same error. Which of the following is the most likely cause and correct solution?

Question 95easymultiple choice
Read the full Essential Commands explanation →

A system administrator notices that the disk space on the root filesystem is at 95% usage. After investigating, they find that a large log file named 'access.log' in /var/log is taking up significant space. The administrator deletes the file using 'rm /var/log/access.log' but the disk usage remains at 95%. Running 'df -h' still shows the same usage. What is the most likely cause and the correct next step?

Question 96mediummultiple choice
Read the full Essential Commands explanation →

A DevOps engineer is writing a continuous integration pipeline that runs a script to deploy an application. The script is stored in a Git repository and is executed on a build server. The script works locally on the engineer's workstation, but when executed on the build server, it fails with '/bin/sh: line 12: somecommand: command not found'. The 'somecommand' is a standard Linux tool that is installed on the build server. The build server uses a minimal Docker container. Which of the following is the most likely cause and solution?

Question 97hardmultiple choice
Read the full Essential Commands explanation →

A system administrator monitors a server that periodically becomes unresponsive for a few seconds. Investigation reveals that the kernel OOM killer is being invoked, but standard memory usage monitoring tools like 'free' and 'top' show less than 50% memory usage. The server runs a web server and a database. Which of the following is the most likely cause and diagnostic step?

Question 98hardmultiple choice
Read the full Essential Commands explanation →

A security audit reveals that a sensitive file '/etc/shadow' has been modified. The file's permissions are set to 600 and owned by root. However, the audit logs show that a service account 'webapp' was able to read the file. The 'webapp' user is not in the root group. Which of the following is the most likely method the 'webapp' user used to read the file?

Question 99hardmultiple choice
Read the full Essential Commands explanation →

A system administrator configures a new server with multiple disks. After partitioning and formatting, they mount a partition to /data. Several days later, they notice that the /data filesystem is full, but 'du -sh /data' reports only 2 GB used, while the partition is 100 GB. 'df -h' shows /data is 98% full. What is the most likely cause and the correct action?

Practice tests

Scored 10-question sessions with instant feedback and explanations.

LFCS Practice Test 1 — 10 Questions→LFCS Practice Test 2 — 10 Questions→LFCS Practice Test 3 — 10 Questions→LFCS Practice Test 4 — 10 Questions→LFCS Practice Test 5 — 10 Questions→LFCS Practice Exam 1 — 20 Questions→LFCS Practice Exam 2 — 20 Questions→LFCS Practice Exam 3 — 20 Questions→LFCS Practice Exam 4 — 20 Questions→Free LFCS Practice Test 1 — 30 Questions→Free LFCS Practice Test 2 — 30 Questions→Free LFCS Practice Test 3 — 30 Questions→LFCS Practice Questions 1 — 50 Questions→LFCS Practice Questions 2 — 50 Questions→LFCS Exam Simulation 1 — 100 Questions→

Practice by domain

Each domain maps to a weighted exam section. Focus on the domain where you are weakest.

User and Group ManagementOperation of Running SystemsEssential CommandsNetworkingService ConfigurationStorage Management

Practice by scenario

Filter questions by type — troubleshooting, exhibit, drag-and-drop, PBQ, ACLs, OSPF, and more.

Browse scenarios→

Continue studying

All Essential Commands setsAll Essential Commands questionsLFCS Practice Hub