Kernel Parameter Modification Flashcards
6 cards from real LFCS Certification practice questions. Tap to flip, then mark Knew It or Still Learning — missed cards come back until you master them.
Read the first 6 Kernel Parameter Modification flashcards as text
A system administrator has just created a new configuration file at `/etc/sysctl.d/99-custom.conf` to tune network parameters. Which command should be used to apply these new settings immediately without rebooting the system?
Answer: `sysctl -p`
The `sysctl -p` command loads kernel parameter settings from all standard configuration files, including `/etc/sysctl.conf` and files within `/etc/sysctl.d/`. This is the standard procedure to apply persistent settings to the running kernel without needing to reboot.
To configure a Linux server as a simple network router, a system administrator needs to enable IPv4 forwarding permanently. What is the recommended method to ensure this setting persists across reboots?
Answer: Create a file, such as `/etc/sysctl.d/90-routing.conf`, with the content `net.ipv4.ip_forward = 1`.
Creating a dedicated file in the `/etc/sysctl.d/` directory is the modern and recommended best practice for making persistent changes to kernel parameters. This method is organized, easy to manage, and automatically applied at boot by the `systemd-sysctl.service`. The other methods are either temporary (sysctl -w, echo) or rely on legacy mechanisms (`rc.local`).
Which of the following filesystems provides a direct, real-time interface for viewing and modifying kernel parameters?
Answer: `/proc/sys`
The `/proc/sys/` directory is a virtual filesystem that provides a direct interface to kernel parameters. Each file within this hierarchy corresponds to a specific parameter, and reading from or writing to these files directly manipulates the kernel's live configuration.
A system administrator modifies the kernel's tendency to use swap space by executing the command: `echo 10 > /proc/sys/vm/swappiness`. The server is then rebooted for unrelated maintenance. Assuming no persistent configuration for this parameter exists, what will be the value of `vm.swappiness` after the server boots up?
Answer: It will revert to the system's default value.
Writing directly to files in the `/proc/sys` filesystem modifies the kernel parameters for the current runtime session only. These changes are ephemeral and do not survive a reboot. Upon startup, the kernel loads its default values, which are then overridden by any persistent settings found in `/etc/sysctl.conf` or `/etc/sysctl.d/`.
What is the primary function of the `sysctl -w parameter=value` command?
Answer: To change a single kernel parameter in the running kernel.
The `sysctl -w` command is used to modify (write) a single kernel parameter at runtime. It is functionally equivalent to using `echo` to write a value to the corresponding file in `/proc/sys/`. This change is not persistent and will be lost upon reboot unless also added to a configuration file.
A system administrator adds `vm.swappiness = 20` to the `/etc/sysctl.conf` file. After rebooting, they run `sysctl vm.swappiness` and see the output `vm.swappiness = 60`. Which of the following is the most likely reason the setting was not applied?
Answer: Another configuration file in `/etc/sysctl.d/` with a later name (e.g., `99-performance.conf`) is setting the same parameter to 60.
The system processes files in `/etc/sysctl.d/` in lexicographical (alphabetical) order after processing `/etc/sysctl.conf`. A file with a name that sorts later, such as `99-performance.conf`, will be read after other files, and any settings it contains will override previously defined ones. This is a common source of configuration conflicts.
How this page was made: written with AI tools and published by Nathan Beja, founder of Practice Test Geeks, who is responsible for its content. Exam facts are checked against the official sources listed below. Not reviewed by a subject-matter expert. Editorial policy
Sources & references
Exam facts on this page (fees, format, dates, passing scores) are checked against these official sources; the date is our last check. Editorial policy
- docs.linuxfoundation.org — Renewal, score release, exam format, passing score · verified Oct 2026
- training.linuxfoundation.org — Test delivery, eligibility, fees, registration deadline, time limit, score validity · verified Oct 2026