CELE study materials
CELE study resources

CELE practice questions

One question at a time. Build your CELE understanding.

First 50 of 199 questions. Each one lists the choices, the correct answer, and an explanation. The checker at the top of this page saves progress in this browser when it is available.

Continue in the practice tool above to load more questions, 50 at a time.

Question 1Essential Linux concepts and architecture

In the Linux filesystem hierarchy, which directory is defined as the root of the entire hierarchy from which all other paths descend?

  1. /root
  2. / Correct answer.
  3. /home
  4. /boot

Explanation

The single forward slash represents the top of the filesystem tree, and every absolute path begins there. All other directories, including /root and /home, are mounted or created beneath it.

Question 2Essential Linux concepts and architecture

A process running in user space needs to read a file from disk. Which mechanism does it use to request that the kernel perform the operation?

  1. A shell command executed by the login shell
  2. A direct memory access to the disk controller
  3. A signal sent to the init process
  4. A system call that switches execution into kernel mode Correct answer.

Explanation

User-space programs cannot touch hardware directly; they invoke system calls such as read() so the kernel performs the privileged work on their behalf. The call transitions the CPU from user mode to kernel mode.

Question 3Essential Linux concepts and architecture

Which component of a Linux system is responsible for initializing hardware, managing memory, and scheduling processes?

  1. The desktop environment
  2. The GNU C Library
  3. The systemd service manager
  4. The kernel Correct answer.

Explanation

The kernel is the privileged core that owns memory management, CPU scheduling, device drivers, and system-call handling. Other components run as user-space programs on top of it.

Question 4Essential Linux concepts and architecture

What does the term 'distribution' (distro) refer to in the Linux ecosystem?

  1. A bundle of the kernel with user-space tools, a package manager, and libraries Correct answer.
  2. A filesystem type used only on removable media
  3. A licensing model applied to proprietary software
  4. A single compiled kernel binary released by Linus Torvalds

Explanation

A distribution combines the Linux kernel with user-space utilities, libraries, an init system, and a package manager to form a usable operating system. Different distros make different packaging and tooling choices.

Question 5Essential Linux concepts and architecture

Which statement correctly describes the difference between a hard link and a symbolic link to a regular file?

  1. A hard link is a separate directory entry pointing to the same inode, while a symbolic link is a separate file containing a path Correct answer.
  2. A hard link can span filesystems, while a symbolic link cannot
  3. Both types store the target's path but differ only in permissions
  4. A hard link stores the target's path, while a symbolic link shares the target's inode

Explanation

Hard links are additional directory entries that reference the same inode, so they share the file's data and link count. Symbolic links are distinct files whose content is a pathname that the kernel resolves on access.

Question 6Essential Linux concepts and architecture

A file's permissions are shown as -rw-r----- and it is owned by user alice and group devs. Who can read the file?

  1. alice and any member of devs Correct answer.
  2. Only the root user
  3. Any user on the system
  4. Only alice

Explanation

The permission string grants read and write to the owner and read to the group, with no permissions for others. Therefore alice and members of the devs group can read it.

Question 7Essential Linux concepts and architecture

Which numeric mode corresponds to permissions rwxr-x--- ?

  1. 705
  2. 750 Correct answer.
  3. 640
  4. 755

Explanation

rwx is 7 for the owner, r-x is 5 for the group, and --- is 0 for others, giving 750. Each triplet sums read=4, write=2, and execute=1.

Question 8Essential Linux concepts and architecture

Which directory on a typical Linux system conventionally holds system-wide configuration files?

  1. /var
  2. /etc Correct answer.
  3. /tmp
  4. /usr

Explanation

/etc is the standard location for host-specific configuration files such as passwd, fstab, and service configs. Other top-level directories serve different purposes under the FHS.

Question 9Essential Linux concepts and architecture

What is the primary function of the init process (PID 1) on a Linux system?

  1. It is the first user-space process and the ancestor of all other processes Correct answer.
  2. It schedules CPU time for all other processes
  3. It loads the kernel image into memory
  4. It provides the graphical login screen

Explanation

After the kernel finishes early initialization it starts PID 1, which becomes the ancestor of every other user-space process and adopts orphans. Modern systems often use systemd in this role.

Question 10Essential Linux concepts and architecture

Which command displays the manual page for the passwd file format rather than the passwd command?

  1. man 1 passwd
  2. info passwd
  3. man 5 passwd Correct answer.
  4. help passwd

Explanation

Manual pages are organized into numbered sections, and section 5 holds file format descriptions. Specifying section 5 therefore selects the passwd file format page instead of the command page in section 1.

Question 11Essential Linux concepts and architecture

A user runs a program and the shell reports 'Permission denied' when executing a script that has mode -rw-r--r--. What is the most direct cause?

  1. The file is owned by another user
  2. The script lacks a shebang line
  3. The execute permission bit is not set on the file Correct answer.
  4. The file is located in /tmp

Explanation

Executing a file requires the execute bit for the invoking user, and the mode shows only read and write bits. Without execute permission the kernel refuses to run it.

Question 12Essential Linux concepts and architecture

Which statement best describes the role of a shell in a Linux system?

  1. It is a daemon that manages print jobs
  2. It is a kernel module that handles device interrupts
  3. It is a user-space command interpreter that reads commands and launches programs Correct answer.
  4. It is the firmware that performs the initial hardware check

Explanation

A shell such as bash reads input, expands it, and requests the kernel to run programs through system calls. It runs in user space like any other application.

Question 13Essential Linux concepts and architecture

What distinguishes an absolute path from a relative path in Linux?

  1. An absolute path may only reference files owned by root
  2. An absolute path begins at / and is independent of the current directory Correct answer.
  3. A relative path cannot contain directory separators
  4. A relative path always begins with a tilde

Explanation

An absolute path starts with the root slash and resolves identically regardless of the working directory. A relative path is interpreted starting from the current working directory.

Question 14Essential Linux concepts and architecture

Which virtual filesystem under /proc exposes kernel and process information as readable files?

  1. /sys
  2. /proc Correct answer.
  3. /dev
  4. /run

Explanation

The proc filesystem presents kernel parameters and per-process data as files, such as /proc/cpuinfo and /proc/PID/status. It exists in memory and is generated by the kernel on access.

Question 15Essential Linux concepts and architecture

Which statement about the root account in Linux is accurate?

  1. The root account can only log in through a graphical session
  2. The root account is a normal user with extra group memberships
  3. The root account has UID 0 and bypasses ordinary permission checks Correct answer.
  4. The root account is disabled whenever sudo is installed

Explanation

UID 0 is treated specially by the kernel, which grants it broad privileges and bypasses normal file permission checks. Administrative work is often delegated through sudo instead of direct root logins.

Question 16Essential Linux concepts and architecture

A process is described as a 'daemon'. What does this imply about it?

  1. It runs only during system shutdown
  2. It runs in the foreground attached to a terminal
  3. It runs in the background detached from a controlling terminal Correct answer.
  4. It is always owned by an interactive user

Explanation

Daemons detach from the controlling terminal and run in the background to provide ongoing services. Traditional daemons often double-fork and close standard file descriptors to complete detachment.

Question 17Essential Linux concepts and architecture

Which of the following best describes how the Linux kernel handles memory allocation for processes?

  1. Each process receives a fixed physical memory region at creation
  2. Processes share one global address space with no isolation
  3. Memory is allocated only when a process writes to a file
  4. Processes use virtual addresses that the kernel maps to physical frames on demand Correct answer.

Explanation

The kernel gives each process its own virtual address space and maps pages to physical frames, often lazily on first access. This provides isolation and enables features such as swapping and demand paging.

Question 18Essential Linux concepts and architecture

What is the purpose of the shebang line at the top of a shell script?

  1. It sets the file's permission bits
  2. It defines environment variables for the script
  3. It names the interpreter the kernel should use to run the script Correct answer.
  4. It declares the script's license

Explanation

A first line such as #!/bin/bash tells the kernel which interpreter program should receive the script when it is executed directly. Without it, the shell may fall back to a default interpreter.

Question 19Essential Linux concepts and architecture

Which statement correctly compares a process and a thread on Linux?

  1. Processes and threads are identical in every respect
  2. A process can contain only one thread
  3. Threads within a process share the address space, while processes have separate address spaces Correct answer.
  4. Threads always have separate address spaces, while processes share one

Explanation

Threads are execution units that share memory and file descriptors within a process, whereas separate processes normally have isolated address spaces. Linux implements both with tasks that can share resources via clone flags.

Question 20Essential Linux concepts and architecture

What does the sticky bit on a directory such as /tmp accomplish?

  1. It encrypts the directory contents
  2. It prevents any user from deleting files in the directory
  3. It makes all files in the directory executable
  4. It allows only the file owner, directory owner, or root to delete or rename entries Correct answer.

Explanation

When the sticky bit is set on a world-writable directory, users may remove only files they own, plus the directory owner and root retain control. This protects shared temporary directories from interference.

Question 21Essential Linux concepts and architecture

Which component of the boot process runs after the firmware and is responsible for loading the kernel into memory?

  1. The bootloader, such as GRUB Correct answer.
  2. The init process
  3. The package manager
  4. The login manager

Explanation

Firmware hands control to a bootloader such as GRUB, which locates and loads the kernel and initramfs. Only after the kernel starts does it launch the init process.

Question 22Essential Linux concepts and architecture

Which command shows the inode number of a file, which is useful when investigating hard links?

  1. ls -l
  2. du -h
  3. file
  4. ls -i Correct answer.

Explanation

The -i option to ls prints the inode number alongside each name, making it easy to see when two names reference the same inode. Hard links to one file share that number.

Question 23Essential Linux concepts and architecture

What does the load average reported by uptime represent?

  1. The amount of swap space consumed by the system
  2. The number of logged-in users per hour
  3. The percentage of CPU idle time over the last minute
  4. The average number of processes runnable or in uninterruptible sleep over time windows Correct answer.

Explanation

Load average counts tasks that are runnable or blocked in uninterruptible sleep, averaged over one, five, and fifteen minutes. It reflects demand for resources rather than a simple CPU percentage.

Question 24Essential Linux concepts and architecture

Which statement about environment variables in Linux is correct?

  1. They can only contain numeric values
  2. They persist across reboots once set in a shell
  3. They are stored in the kernel and readable by all processes
  4. They are inherited by child processes from their parent's environment Correct answer.

Explanation

Environment variables live in each process's memory and are passed to children at process creation. A variable set in a shell reaches a program launched from that shell but not unrelated processes.

Question 25Essential Linux concepts and architecture

A user reports that a filesystem is full even though deleting a large log file freed no space. Which explanation is most plausible?

  1. The file was deleted but a running process still holds it open Correct answer.
  2. The inode table is corrupt and must be rebuilt
  3. The filesystem uses a journal and cannot free space
  4. The file was owned by root and cannot be deleted

Explanation

On Linux, unlinking a file removes its directory entry, but the data blocks are released only when the last open file descriptor closes. A process still writing to the deleted log keeps the space allocated until it exits or reopens its output.

Question 26Essential Linux concepts and architecture

A Linux system is described as a monolithic kernel. What does this mean about how kernel functionality is organized?

  1. Each kernel service runs as a separate user-space server that the kernel messages on demand.
  2. Core services such as scheduling, memory management, and device drivers run together in a single privileged address space. Correct answer.
  3. The kernel is compiled as a set of independent modules that are always loaded at boot and cannot be unloaded.
  4. Kernel code executes only in user mode, requesting hardware access through a hypervisor interface.

Explanation

A monolithic kernel places the core subsystems (scheduler, memory manager, filesystems, and most drivers) in one kernel address space running in privileged CPU mode. Linux is monolithic but supports loadable kernel modules, so not every driver must be built in. Microkernel designs, by contrast, push services into separate user-space servers.

Question 27Essential Linux concepts and architecture

On a Linux system, a user types `ls` and the shell locates the executable. Which mechanism determines where the shell looks for that command?

  1. The PATH environment variable, which lists directories searched in order for the executable. Correct answer.
  2. The /etc/fstab file, which maps command names to device nodes.
  3. The inode table of the current working directory only.
  4. The LD_PRELOAD variable, which names the default command directory.

Explanation

When a command is given without a slash, the shell searches the colon-separated directories in PATH from left to right and runs the first matching executable. Files such as /etc/fstab describe mounted filesystems and play no role in command lookup. LD_PRELOAD injects shared libraries, it does not define a search path.

Question 28Essential Linux concepts and architecture

An administrator wants an ext4 filesystem to be checked automatically at boot only after a set number of mounts, and also wants the check order relative to other filesystems defined. Which field of /etc/fstab carries the dump and fsck pass values used by boot-time checking?

  1. The fourth field, which holds mount options such as defaults.
  2. The first field, which holds the device or UUID.
  3. The third field, which holds the filesystem type.
  4. The sixth field, which holds dump and fsck pass numbers. Correct answer.

Explanation

Each /etc/fstab line has six fields: device, mount point, filesystem type, options, dump, and fsck pass. The sixth field contains the dump value followed by the pass number that orders fsck checks, with 0 disabling the check. The device, type, and options fields describe what is mounted and how, not the check ordering.

Question 29Essential Linux concepts and architecture

A process running in the background receives SIGHUP when its controlling terminal closes. Which signal disposition lets the process keep running despite that hangup?

  1. Changing the process nice value to a negative number.
  2. Blocking SIGKILL so the kernel cannot deliver any signal to the process.
  3. Sending SIGSTOP to the process so it pauses until the terminal returns.
  4. Ignoring SIGHUP, for example by starting the process with nohup or setting the signal to be ignored. Correct answer.

Explanation

SIGHUP is delivered when the controlling terminal goes away, and a process survives if it ignores or handles that signal, which is what nohup arranges. SIGKILL cannot be caught, blocked, or ignored, so it offers no protection. A stopped process is not running, and nice values affect scheduling priority, not signal delivery.

Question 30Essential Linux concepts and architecture

A service started by systemd keeps restarting in a loop, and journalctl shows it exiting with status 203. What does that exit status indicate about the failure?

  1. The unit file was not found by systemd during startup.
  2. The main process could not be executed, for instance because the binary is missing or not executable. Correct answer.
  3. The process exited because it could not change its working directory.
  4. The service exceeded its configured memory limit and was killed by the OOM killer.

Explanation

systemd reports an exit status in the 200 range when it could not execute the configured ExecStart binary, commonly due to a missing file, wrong path, or missing execute permission. Failures inside the program itself appear as ordinary exit codes or signals, not 203. Memory-limit kills show up as signal-based termination such as SIGKILL rather than 203.

Question 31Installing and configuring Linux

During a scripted installation of a Linux server, which partitioning scheme places /var, /tmp, and /home on separate filesystems to limit the impact of a runaway log or user data filling the root filesystem?

  1. A swap partition sized to twice physical RAM
  2. Separate partitions for /var, /tmp, and /home Correct answer.
  3. An LVM volume group with one logical volume for /
  4. A single root partition with no separate mounts

Explanation

Isolating frequently written directories such as /var, /tmp, and /home onto their own filesystems prevents one directory from exhausting the space available to the root filesystem. A single root partition shares one space pool, so a runaway log in /var can render the whole system unusable. Swap sizing affects memory pressure, not filesystem isolation.

Question 32Installing and configuring Linux

An administrator needs to install a Linux distribution on a machine that must boot via UEFI. Which partition is required in addition to the root filesystem?

  1. An EFI System Partition formatted FAT32 Correct answer.
  2. A BIOS boot partition
  3. A dedicated /boot partition formatted XFS
  4. An extended partition

Explanation

UEFI firmware reads bootloaders from an EFI System Partition formatted with a FAT filesystem, conventionally FAT32, mounted at /boot/efi. A BIOS boot partition is used by GPT disks on legacy BIOS systems running GRUB. An extended partition is a legacy MBR construct.

Question 33Installing and configuring Linux

Which command installs a Debian package file named tool.deb while automatically resolving and installing its dependencies from configured repositories?

  1. apt install ./tool.deb Correct answer.
  2. dpkg-deb --build tool.deb
  3. apt-get remove tool.deb
  4. dpkg -i tool.deb

Explanation

Modern apt accepts a local .deb path and will pull in dependencies from the configured repositories during installation. Plain dpkg -i installs the package but leaves unmet dependencies unresolved. The other commands remove or rebuild packages rather than installing with dependency resolution.

Question 34Installing and configuring Linux

After editing /etc/fstab to add a new data volume, an administrator wants to verify the entry without rebooting. Which command tests the mount entries and mounts anything not already mounted?

  1. blkid
  2. mount -a Correct answer.
  3. lsblk -f
  4. fdisk -l

Explanation

mount -a reads /etc/fstab and mounts every entry not currently mounted, which validates the new entry immediately. lsblk and blkid only report block device and filesystem metadata. fdisk -l lists partition tables and does not act on fstab.

Question 35Installing and configuring Linux

Which systemd target corresponds to the traditional multi-user, non-graphical runlevel used on a server?

  1. rescue.target
  2. multi-user.target Correct answer.
  3. poweroff.target
  4. graphical.target

Explanation

multi-user.target is the systemd equivalent of the classic runlevel 3, providing a full multi-user environment without a display manager. graphical.target adds the GUI, rescue.target is a single-user maintenance mode, and poweroff.target shuts the machine down.

Question 36Installing and configuring Linux

An administrator wants a service to start automatically at boot after enabling it with systemctl enable. Which directory typically holds the symlink that systemd follows to start the unit?

  1. /var/lib/systemd
  2. /etc/init.d
  3. /etc/systemd/system/multi-user.target.wants Correct answer.
  4. /usr/lib/systemd/system

Explanation

systemctl enable creates a symlink in the .wants directory of the target that should pull in the unit, commonly multi-user.target.wants under /etc/systemd/system. The vendor unit files in /usr/lib/systemd/system are not modified by enabling. /etc/init.d belongs to legacy SysV scripts.

Question 37Installing and configuring Linux

A server's clock drifts after reboots. Which service should be configured to keep time synchronized with network time servers?

  1. udev
  2. logrotate
  3. cron
  4. chronyd Correct answer.

Explanation

chronyd (or systemd-timesyncd) implements NTP synchronization to keep the system clock accurate against network time sources. cron schedules jobs, logrotate manages log files, and udev handles device events, none of which synchronize time.

Question 38Installing and configuring Linux

Which file defines the hostname persistently on a system using systemd, in a way that hostnamectl and other tools read?

  1. /etc/resolv.conf
  2. /etc/hosts
  3. /etc/sysconfig/network
  4. /etc/hostname Correct answer.

Explanation

/etc/hostname stores the static hostname that systemd reads and that hostnamectl set-hostname updates. /etc/hosts maps names to addresses for local resolution, /etc/resolv.conf lists DNS servers, and /etc/sysconfig/network is a legacy Red Hat file.

Question 39Installing and configuring Linux

An administrator runs ip addr add 192.0.2.10/24 dev eth0 but the address disappears after a reboot. What is the most appropriate way to make it persistent?

  1. Configure the address in the network manager profile for eth0, such as a NetworkManager connection or ifcfg file Correct answer.
  2. Add a static route in /etc/fstab
  3. Run the ip command from /etc/rc.local only
  4. Add the address to /etc/hosts

Explanation

The ip command changes runtime kernel state only; persistence requires writing the address into the configuration managed by the system's network stack, such as a NetworkManager connection profile or a distribution ifcfg file. /etc/hosts only maps names, /etc/fstab handles filesystems, and relying on rc.local is fragile and often disabled.

Question 40Installing and configuring Linux

Which directive in an sshd_config file disables direct root login over SSH?

  1. PermitRootLogin no Correct answer.
  2. PubkeyAuthentication yes
  3. PasswordAuthentication yes
  4. AllowUsers root

Explanation

PermitRootLogin no blocks direct root logins while still allowing administrative users to escalate privileges after logging in. AllowUsers root would explicitly permit root, and the authentication directives control credential methods rather than which accounts may log in.

Question 41Installing and configuring Linux

An administrator needs to restrict SSH access so that only members of the group sysadmins may log in. Which sshd_config directive accomplishes this?

  1. LoginGraceTime 30
  2. MaxAuthTries 1
  3. AllowGroups sysadmins Correct answer.
  4. DenyGroups sysadmins

Explanation

AllowGroups limits authentication to users who belong to the listed groups, so AllowGroups sysadmins permits only that group. DenyGroups sysadmins would block the intended administrators. MaxAuthTries and LoginGraceTime tune connection behavior but do not restrict group membership.

Question 42Installing and configuring Linux

Which command creates a new ext4 filesystem on the block device /dev/sdb1?

  1. mkfs.ext4 /dev/sdb1 Correct answer.
  2. fdisk /dev/sdb1
  3. mount -t ext4 /dev/sdb1
  4. fsck.ext4 /dev/sdb1

Explanation

mkfs.ext4 writes the ext4 filesystem structures onto the target block device. fdisk edits partition tables, mount attaches an existing filesystem to the directory tree, and fsck checks and repairs an existing filesystem.

Question 43Installing and configuring Linux

A new disk must be mounted at /data on every boot. Which fstab field entry is the most robust way to reference the filesystem in the first column?

  1. The device path /dev/sdb1
  2. The filesystem type ext4
  3. The mount point /data
  4. The filesystem UUID Correct answer.

Explanation

The first fstab column identifies the device to mount; using the filesystem UUID is stable because device names like /dev/sdb1 can change when disks are added or reordered. The mount point belongs in the second column and the filesystem type in the third.

Question 44Installing and configuring Linux

Which tool provides a menu-driven interface for managing users, groups, and some system settings on many Linux distributions?

  1. nmcli
  2. visudo
  3. system-config-users Correct answer.
  4. useradd

Explanation

system-config-users is a graphical or menu-driven administration utility for creating and editing user and group accounts. useradd is a non-interactive command-line tool, visudo edits the sudoers file, and nmcli manages network connections.

Question 45Installing and configuring Linux

An administrator creates a user with useradd -m alice. Which file is updated to record the default values applied when that account was created?

  1. /etc/default/useradd Correct answer.
  2. /etc/shadow
  3. /etc/login.defs
  4. /etc/passwd

Explanation

/etc/default/useradd stores defaults such as the default shell and home directory skeleton used by useradd when no overriding options are given. /etc/passwd and /etc/shadow receive the resulting account and password records, while /etc/login.defs sets broader login and password-aging policy.

Question 46Installing and configuring Linux

Which command changes the default login shell for an existing user without directly editing /etc/passwd?

  1. usermod -L alice
  2. passwd -l alice
  3. chage -M 90 alice
  4. chsh -s /bin/zsh alice Correct answer.

Explanation

chsh -s updates the login shell field for the specified user and validates the shell against /etc/shells. usermod -L locks the account, passwd -l also locks the password, and chage -M sets maximum password age.

Question 47Installing and configuring Linux

Which file controls which users may run commands via sudo and under what conditions?

  1. /etc/pam.d/su
  2. /etc/sudoers Correct answer.
  3. /etc/security/access.conf
  4. /etc/passwd

Explanation

/etc/sudoers defines sudo privileges, specifying which users or groups may run which commands, often as whom, and whether a password is required. It should be edited with visudo to catch syntax errors. The other files handle account data, login access control, and su PAM policy.

Question 48Installing and configuring Linux

An administrator wants a specific user to run only /usr/bin/systemctl restart nginx through sudo. Which approach correctly limits the privilege?

  1. Set the user's shell to /sbin/nologin
  2. Add the user to the wheel group
  3. Add the user to the sudo group without any command specification
  4. Add a sudoers rule granting that user the exact command path with no wildcards Correct answer.

Explanation

A sudoers rule can name the specific command path, restricting the user to exactly that command. Adding the user to wheel or sudo typically grants broad privileges defined by the group's rule, and changing the shell does not affect sudo authorization.

Question 49Installing and configuring Linux

Which command displays the current runlevel target and confirms whether the system booted into graphical or multi-user mode on a systemd host?

  1. systemctl get-default Correct answer.
  2. telinit q
  3. runlevel --set 3
  4. init 0

Explanation

systemctl get-default reports the target the system boots into by default, such as graphical.target or multi-user.target. The other options attempt to change runlevels or reload configuration rather than report the default target.

Question 50Installing and configuring Linux

A service unit fails immediately at boot. Which command shows the unit's status along with the most recent log lines explaining the failure?

  1. systemctl status myservice.service Correct answer.
  2. systemctl mask myservice.service
  3. systemctl daemon-reload
  4. systemctl list-unit-files

Explanation

systemctl status shows whether the unit is active, its exit code, and recent journal lines that usually reveal the failure cause. mask prevents a unit from starting, daemon-reload reloads unit files after edits, and list-unit-files only lists enablement states.